[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: ls -alR with wd?



On Thu, Jun 10, 2010 at 5:06 PM, Merciadri Luca
<Luca.Merciadri@student.ulg.ac.be> wrote:
> `locate' is really, really, really, really faster. I had no knowledge
> about it. Thanks a lot.

Just remember, locate is much faster because it's reading a database.
Results from "find" reflect the state of your system NOW, and results
from "locate" reflect what your system was whenever the last database
update was run.

So locate will fail to find files that you just installed (after the
db update), and it can report files that are in fact no longer there
(deleted, or moved)!

I think people are recommending to use mlocate now, which is a dropin
replacement for locate.  One big (HUGE) advantage is on db updates,
where mlocate looks at a directory to see if anything has changed,
whereas older locate recursively examined the contents of directories.

In any case, I agree with you, locate (which is still the command to
invoke even for mlocate) works great.

John


Reply to: