Skip navigation

Locate Database - Is it worth generating?

1445 Views 4 Replies Latest reply: Nov 28, 2012 7:29 AM by wortell RSS
bud_jones Calculating status...
Currently Being Moderated
Apr 14, 2012 12:45 PM

I was playing around on the terminal using some Unix commands. When I tried "Locate" the system replied

 

WARNING: The locate database (/var/db/locate.database) does not exist.

To create the database, run the following command:

 

 

  sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

 

 

Please be aware that the database can take some time to generate; once

the database has been created, this message will no longer appear.

 

I have been using OSX for years and have never had occasion to use the Locate. Am I missing something useful?

MacBook, Mac OS X (10.7.3), AirPort Express, IPod, iPad, iPad2
  • Niel Level 10 Level 10 (234,255 points)
    Currently Being Moderated
    Apr 14, 2012 4:33 PM (in response to bud_jones)

    It's not created by default in Mac OS X 10.7. Generally, if all the drives you normally use are indexed by Spotlight, having a locate database won't add anything.

     

    (65625)

  • Barney-15E Level 7 Level 7 (33,240 points)
    Currently Being Moderated
    Apr 15, 2012 5:05 AM (in response to bud_jones)

    The locate database is only useful if you want to search for things in the command line. Locate isn't tied to spotlight or any other search functions on the Mac. It just indexes the programs on the hard drive so it can tell you where they are located if you ask.

  • wortell Level 1 Level 1 (0 points)
    Currently Being Moderated
    Nov 28, 2012 7:29 AM (in response to bud_jones)

    You probably already know this but I just found this very helpful as well - as I TOO was going to install the locate database, but didn't want to overdo it... - located at the bottom of the "http://support.apple.com/kb/HT2531" link - i noticed an advanced options section... (while in terminal you can use the power of command line of spotlight via the "mdfind {file/string}" command.

     

    I was jazzed as it was just as fast (slightly faster obviously due to no UI) as spotlight and gave me what I wanted.

     

    Jus' fyi is all. Hope it helps someone else too.    

Actions

More Like This

  • Retrieving data ...

Bookmarked By (0)

Legend

  • This solved my question - 10 points
  • This helped me - 5 points
This site contains user submitted content, comments and opinions and is for informational purposes only. Apple disclaims any and all liability for the acts, omissions and conduct of any third parties in connection with or related to your use of the site. All postings and use of the content on this site are subject to the Apple Support Communities Terms of Use.