Locate and invisible files
In bash, I have loads of a particular type of file created after simulations.
To analyse those files I use the locate function.
Well locate worked initially, it found the files I needed by using the full path.
Now when I try to locate them it doesn't find the other files anymore even if they are there!!!
They seems invisible to the locate function, but they aren'1!!
So why the locate function works with some files and it doesn't work with another?????
You need to keep the slocate database up to date. Run 'updatedb' as root and when that is done, locate will be able to find the files.
I stopped using 'locate' a while ago. It's quirky - yes you can run updatedb; hopefully cron does this for you already. But learn the 'find' command. It can be slower, but if you know what you're doing you'll like it much better - it is capable of so much more the 'locate'.
|All times are GMT -5. The time now is 09:27 PM.|