The file /usr/libexec/locate.updatedb defines SEARCHPATHS as "/". The same file defines a way to configure its operations, by reading LOCATE_CONFIG="/etc/locate.rc", from which SEARCHPATHS can be re-refined in locate.rc or specified as --searchpaths.
To avoid indexing large mounted volumes, as well as to focus the locate database, I re-refined SEARCHPATHS in /etc/locate.rc: > SEARCHPATHS="/usr /var" However, /usr/libexec/locate.updatedb ignores the configuration file. This is what I see at runtime, where find is clearly running on the default vaule of SEARCHPATHS: > find / ! ( -fstype ffs -or -fstype ufs ) -prune -or -path /tmp -prune -or > -path /var/tmp -prune -or -print This is the end result: > Rebuilding locate database: > /tmp: write failed, file system is full > sort: No space left on device > locate.mklocatedb: cannot build locate database > locate: database too small: /var/db/locate.database.slJhKwjajQ > Not installing invalid locate database where "sort" is called by /usr/libexec/locate.mklocatedb, which is called by /usr/libexec/locate.updatedb. Is anybody else having this problem?