2

I've noticed that the search indexes only those files which have previously been opened with some application.

For example, searching for a presentation returns 0 results initially, but once I navigate to the file in Nautilus, and open it with LO - it becomes, along with the folder hierarchy it is in.

I've tested this primarily with files on another partition (where my home folder is) and on another disk (where most of my documents are).

Why is this so? Is it a bug or an intentionally missing feature? (Windows 7 finds all files whether they've been opened or not.)

2 Answers 2

1

The reason search isn't working in this case is because /media is blacklisted in /etc/updatedb.conf. The solution is to mount the partition on /mnt and ran sudo /etc/cron.daily/mlocate.

Search uses multiple search engines. Zeitgeist indexes the recently used documents, which is why some files from the partition are showing, and some aren't. But other search engines (mlocate) and os-walk (previously 'find') are problematic.

If your drives are NTFS, they aren't blacklisted, but are probably mounted in /media, which is why they aren't being indexed.

5
  • Yes, my home directory is actually a subdirectory of /media, although it is symlinked in home.
    – jcora
    Oct 18, 2014 at 23:13
  • As you can see in the edit, the situation got fixed once I mounted the partition elsewhere and ran mlocate.
    – jcora
    Oct 19, 2014 at 0:44
  • cheers for turning my lazy effort into english! The other way to do it is remove the /mount entry from updatedb.
    – dez93_2000
    Oct 19, 2014 at 2:50
  • Yes, that's what I was thinking about, but then it would also start indexing stuff that wasn't permanently on the system, e.g. my external drive and flash drives.
    – jcora
    Oct 19, 2014 at 9:40
  • well if you have those drives automounting to the same mount point when connected (which is a nice thing to do anyway) then you can specifically block those off by adding (e.g.) /media/ext_drive /media/flash_drive . Furthermore, you can do that for folders you don't wanna index in drives you DO wanna index e.g. /media/ntfs_drive/windows
    – dez93_2000
    Oct 19, 2014 at 13:58
0

As dez93_2000 mentioned, /media path is blacklisted, but you can remove it from /etc/updatedb.conf and set PRUNE_BIND_MOUNTS to "no". If you run updatedb after that you should notice some time will be spent on processing newly found media devices.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .