]> git.sesse.net Git - plocate/blob - updatedb.conf.5.in
Remove dependency on non-POSIX header error.h.
[plocate] / updatedb.conf.5.in
1 .\" A man page for updatedb.conf. -*- nroff -*-
2 .\"
3 .\" Copyright (C) 2005, 2007, 2008 Red Hat, Inc. All rights reserved.
4 .\"
5 .\" This copyrighted material is made available to anyone wishing to use,
6 .\" modify, copy, or redistribute it subject to the terms and conditions of the
7 .\" GNU General Public License v.2.
8 .\"
9 .\" This program is distributed in the hope that it will be useful, but WITHOUT
10 .\" ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 
11 .\" FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 
12 .\" more details.
13 .\"
14 .\" You should have received a copy of the GNU General Public License along
15 .\" with this program; if not, write to the Free Software Foundation, Inc.,
16 .\" 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
17 .\"
18 .\" Author: Miloslav Trmac <mitr@redhat.com>
19 .TH updatedb.conf 5 "Oct 2020" plocate
20
21 .SH NAME
22 @updatedb_conf@ \- a configuration file for updatedb(8)
23
24 .SH DESCRIPTION
25 .B @updatedb_conf@
26 is a text file.
27 Blank lines are ignored.
28 A
29 .B #
30 character outside of a quoted string starts a comment
31 extending until end of line.
32
33 Other lines must be of the following form:
34 .RS
35 .I VARIABLE
36 .B =
37 \fB"\fIVALUE\fB"\fR
38 .RE
39
40 White space between tokens is ignored.
41 .I VARIABLE
42 is an alphanumeric string which does not start with a digit.
43 .I VALUE
44 can contain any character except for \fB\(dq\fR.
45 No escape mechanism is supported within
46 .I VALUE
47 and there is no way to write
48 .I VALUE
49 spanning more than one line.
50
51 Unknown
52 .I VARIABLE
53 values are considered an error.
54 The defined variables are:
55
56 .TP
57 \fBPRUNEFS\fR
58 A whitespace-separated list of file system types (as used in \fB/etc/mtab\fR)
59 which should not be scanned by
60 .BR updatedb (8).
61 The file system type matching is case-insensitive.  By default, no file system
62 types are skipped.
63
64 When scanning a file system is skipped,
65 all file systems mounted in the subtree are skipped too,
66 even if their type does not match any entry in \fBPRUNEFS\fR.
67
68 .TP
69 \fBPRUNENAMES\fR
70 A whitespace-separated list of directory names (without paths) which should not
71 be scanned by
72 .BR updatedb (8).
73 By default, no directory names are skipped.
74
75 Note that only directories can be specified, and no pattern mechanism (e.g.
76 globbing) is used.
77
78 .TP
79 \fBPRUNEPATHS\fR
80 A whitespace-separated list of path names of directories which should not be
81 scanned by
82 .BR updatedb (8).
83 Each path name must be exactly in the form
84 in which the directory would be reported by
85 .BR locate (1).
86
87 By default, no paths are skipped.
88
89 .TP
90 \fBPRUNE_BIND_MOUNTS\fR
91 One of the strings \fB0\fR, \fBno\fR, \fB1\fR or \fByes\fR.
92 If
93 .B PRUNE_BIND_MOUNTS
94 is \fB1\fR or \fByes\fR,
95 bind mounts are not scanned by
96 .BR updatedb (8).
97 All file systems mounted in the subtree of a bind mount are skipped as well,
98 even if they are not bind mounts.
99 As an exception, bind mounts of a directory on itself are not skipped.
100 Note that Btrfs subvolume mounts are handled internally in the kernel
101 as bind mounts (see
102 .BR btrfs-subvolume (8)),
103 and thus, may get skipped if you have also mounted the filesystem root itself.
104 To counteract this, make your root directory a Btrfs subvolume, too.
105
106 By default, bind mounts are not skipped.
107
108 .SH NOTES
109 When a directory is matched by \fBPRUNEFS\fR, \fBPRUNENAMES\fR or
110 \fBPRUNEPATHS\fR,
111 .BR updatedb (8)
112 does not scan the contents of the directory.
113 The path of the directory itself is, however, entered in the created database.
114 For example, if
115 .I /tmp
116 is in \fBPRUNEPATHS\fR,
117 .BR locate (1)
118 will not show any files stored in \fI/tmp\fR,
119 but it can show the
120 .I /tmp
121 directory.
122 This behavior differs from traditional
123 .B locate
124 implementations.
125
126 In some
127 .BR updatedb (8)
128 implementations \fBPRUNEPATHS\fR can be used to exclude non-directory files.
129 This is not the case in this implementation.
130
131 .B @updatedb_conf@
132 is a shell script in some implementations,
133 which allows much more flexibility in defining the variables.
134 Equivalent functionality can be achieved by using the command-line options
135 to
136 .BR updatedb (8).
137
138 .SH AUTHOR
139 Miloslav Trmac <mitr@redhat.com>
140
141 .SH SEE ALSO
142 .BR locate (1),
143 .BR updatedb (8)