Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 2 Jun 2001 02:17:54 -0700 (PDT)
From:      opentrax@email.com
To:        freebsd-gnats-submit@freebsd.org
Subject:   docs/27833: No man page for locate.rc
Message-ID:  <200106020917.f529HsH38695@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         27833
>Category:       docs
>Synopsis:       No man page for locate.rc
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-doc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          doc-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jun 02 02:20:01 PDT 2001
>Closed-Date:
>Last-Modified:
>Originator:     Jesse Monroy, Jr.
>Release:        3.5.1
>Organization:
Digital Marshalls
>Environment:
FreeBSD spammie.svbug.com 3.5.1-RELEASE FreeBSD 3.5.1-RELEASE #0: Wed Sep 13 20:07:41 PDT 2000     jessem@spammie.svbug.com:/usr/src/sys/compile/GATEWAY  i386
>Description:
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.
>How-To-Repeat:

>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)

>Release-Note:
>Audit-Trail:
>Unformatted:

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-doc" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200106020917.f529HsH38695>