| Summary: | No man page for locate.rc | ||
|---|---|---|---|
| Product: | Documentation | Reporter: | opentrax <opentrax> |
| Component: | Books & Articles | Assignee: | Mark Linimon <linimon> |
| Status: | Closed FIXED | ||
| Severity: | Affects Only Me | ||
| Priority: | Normal | ||
| Version: | Latest | ||
| Hardware: | Any | ||
| OS: | Any | ||
++ 02/06/01 02:17 -0700 - opentrax@email.com: | /etc/locate.rc. There is no example rc file, nor is locate.rc | documented in a man page. I have an /etc/locate.rc on 4-STABLE. As well as /usr/share/examples/etc/locate.rc. -pete -- Pete Fritchman <petef@databits.net> Databits Network Services, Inc. <http://databits.net> finger petef@databits.net for PGP key State Changed From-To: open->analyzed Either make a new locate.rc(5) or link it to the locate.updatedb(8) page and add some info there. But yes, locate.rc should be better documented. Responsible Changed From-To: freebsd-doc->cjc I am doing some work on the locate(8)-system. State Changed From-To: analyzed->feedback Is this still applicable to modern versions of FreeBSD? Responsible Changed From-To: cjc->linimon Reset PR assigned to inactive committer who has not responded to email. State Changed From-To: feedback->closed Submitter's email address bounces. |
locate.updatedb(8) says the locate db can be controlled by /etc/locate.rc. There is no example rc file, nor is locate.rc documented in a man page. Fix: Since locate.updatedb is a shell script, here are some notes to get a man page started. Documenter please note you may verify these notes by reading /usr/libexec/locate.updatedb --------------------- /etc/locate.rc can be used to change the default behaviour of locate.updatedb(8). Since, /usr/libexec/locate.updatedb is a shell script, there are several parameters which can be overwritten. The following issues effect the out come, or may give cause to use locate.rc: o...Your system mounts more that ufs (Unix File System). o...locate.updatedb support programs are not stored in /usr/libexec:/bin:/usr/bin, or ${PATH} of user running locate.updatedb o...The database is not stored in the usual location (/var/db) o...You want to setup locate(1) for a diskless system, systems that are chroot(2|8)'d, or systems that the default root directory is not '/'. o...You want to exclude world readable directories, other than the usual temporary directories. (/tmp /usr/tmp /var/tmp) o...You want to create a locate(1) database for a mountable file system, like nfs or cdrom. Again, with the following parameters for locate.rc, write them as sh(1) variables. LIBEXECDIR Directory the subprograms are stored. TMPDIR Temporary directory to use. FCODES Final datbase name. SEARCHPATHS The directories to put in the database. PRUNEPATHS Paths you want to exclude from the database. FILESYSTEMS The types of file systems you want to include. (As a 'find' parameter) The following parameter should not be changed, but are included for completeness. mklocatedb The program run to create the datebase. find The program run to create the list of files for the 'mklocatedb' program. The following example script stores the database in the file '/var/db/locate.cdrom'. It only searches the directories below '/cdrom'. And it sets the file system type to 'rdonly' (read only). # # Here is an example for a iso-9660 cdrom # FCODES=/var/db/locate.cdrom SEARCHPATHS=/cdrom FILESYSTEMS=rdonly See Also sh(1), locate.db(8), find(1), chroot(2), chroot(8)