The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
Google UNIX.COM


UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !!

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
script to locate servers ibroxy Shell Programming and Scripting 5 05-30-2008 12:54 AM
Equivalent to locate Russell SUN Solaris 5 10-05-2006 02:10 PM
not able to locate SSH bishweshwar UNIX for Dummies Questions & Answers 5 09-11-2006 10:14 AM
Cant locate CGI/Cookie.pm naik_mit Linux 1 05-26-2005 09:51 PM
Difference between locate and find camerja1 UNIX for Dummies Questions & Answers 1 06-25-2002 10:55 AM

Reply
 
Submit Tools LinkBack Thread Tools Search this Thread Display Modes
  #1  
Old 08-26-2008
Registered User
 

Join Date: Aug 2007
Posts: 49
Question command locate.

Hi,

I am aware of the command locate/slocate. But when I try to search the file which is located in /tmp. Its not able to get it. I tried by updating the database also with the command updatedb.

Is there any consern that the command 'locate' dont check /tmp???

And I knew that locate is the short name for slocate.But in my box (RHEL5) slocate command is not working.

Please clear my doubts.
Thanks in advance.
Reply With Quote
Forum Sponsor
  #2  
Old 08-26-2008
Registered User
 

Join Date: Aug 2008
Location: Sydney, Australia
Posts: 26
try this

find / -name filename it may take sometime to update the local db.
Reply With Quote
  #3  
Old 08-26-2008
Registered User
 

Join Date: Aug 2007
Posts: 49
Thanks Sydny,
I am aware of searching the file. My doubt is wether the command 'locate' consider /tmp or not?
Reply With Quote
  #4  
Old 08-26-2008
vbe vbe is offline
Moderator
 

Join Date: Sep 2005
Location: Switzerland
Posts: 775
I would say "not" but thats a question of configuration, go through the docs because in my younger life I used it customly to figure out if files ever existed (at such date, in such dir etc...)
Reply With Quote
  #5  
Old 08-26-2008
Registered User
 

Join Date: Aug 2007
Posts: 49
Thanks Vbe,

What you said is correct.
Reply With Quote
  #6  
Old 08-26-2008
Registered User
 

Join Date: Aug 2008
Posts: 58
You can also specify the directory in which you want to look for, cause if you specify only / it look up in the whole system.
Code:
find /tmp -name filename

Last edited by agasamapetilon; 08-26-2008 at 01:02 PM.
Reply With Quote
Google The UNIX and Linux Forums
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes




All times are GMT -7. The time now is 09:58 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008. All Rights Reserved.Ad Management by RedTyger Visit The Complex Event Processing Blog

Content Relevant URLs by vBSEO 3.2.0