updatedb.conf(5)
π NAME π
/etc/updatedb.conf β bestie, it's the config file for updatedb(8). That's it, that's the whole vibe. β¨
πΈ DESCRIPTION πΈ
Okay so /etc/updatedb.conf is a text file. Simple. Iconic. Low maintenance.
- Blank lines? Ignored. Don't even worry about them. π
- A
#character outside of a quoted string starts a comment, and that comment runs until the end of the line. So you can spill your thoughts, bestie, it's fine.
Every other line has to be shaped like this, no exceptions:
VARIABLE = "VALUE"
White space between tokens is ignored β so go ahead and make it pretty, the parser does not care. π
VARIABLEis an alphanumeric string that does not start with a digit. (so1vibesis out, sorry π)VALUEcan contain any character except". There is no escape mechanism supported insideVALUE, and there is no way to write aVALUEthat spans more than one line. One line only, queen. π
Unknown VARIABLE values are considered an error. Not a warning, not a suggestion. An error. The file does not tolerate mystery variables. π
Here are the variables that actually exist:
PRUNEFSβ a whitespace-separated list of file system types (the kind used in/etc/mtab) that should not be scanned byupdatedb(8). The file system type matching is case-insensitive. By default, no file system types are skipped.
Heads up: when scanning a file system is skipped, all file systems mounted in the subtree are skipped too β even if their type does not match any entry in PRUNEFS. It cascades, bestie. π¦
PRUNENAMESβ a whitespace-separated list of directory names (without paths, just the names) that should not be scanned byupdatedb(8). By default, no directory names are skipped.
Note: only directories can be specified here, and no pattern mechanism (like globbing) is used. No wildcards, no regex, no β¨magicβ¨. Just names.
PRUNEPATHSβ a whitespace-separated list of path names of directories that should not be scanned byupdatedb(8). Each path name must be exactly in the form in which the directory would be reported bylocate(1). Like, exact-exact. π―
By default, no paths are skipped.
PRUNE_BIND_MOUNTSβ one of the strings0,no,1oryes. IfPRUNE_BIND_MOUNTSis1oryes, bind mounts are not scanned byupdatedb(8). All file systems mounted in the subtree of a bind mount are skipped as well, even if they are not bind mounts. π«Ά
Exception alert: bind mounts of a directory on itself are not skipped.
Also important: Btrfs subvolume mounts are handled internally in the kernel as bind mounts (see btrfs-subvolume(8)), and thus may get skipped if you have also mounted the filesystem root itself. To counteract this, make your root directory a Btrfs subvolume, too. Problem solved, you're welcome. π
By default, bind mounts are not skipped.
π NOTES π
Okay this part is the the way that⦠section, because the behavior is a little quirky and you need to know it:
When a directory is matched by PRUNEFS, PRUNENAMES or PRUNEPATHS, updatedb(8) does not scan the contents of the directory. The path of the directory itself is, however, entered in the created database. ποΈ
Example time, bestie: if /tmp is in PRUNEPATHS, then locate(1) will not show any files stored in /tmp, but it can show the /tmp directory. Yes, really. This behavior differs from traditional locate implementations. It's giving main character energy, honestly. π
Also: in some updatedb(8) implementations, PRUNEPATHS can be used to exclude non-directory files. This is not the case in this implementation. Nope. Not here. π«
And finally β in some implementations, /etc/updatedb.conf is a shell script, which allows much more flexibility in defining the variables. If that's the energy you crave, you can get equivalent functionality by using the command-line options to updatedb(8). Go off. π₯
β¨ AUTHOR β¨
Miloslav Trmac <mitr@redhat.com> β the icon, the legend, the moment. π«Ά
π SEE ALSO π
And that's the whole page, bestie β brought to you by plocate, dated Oct 2020. It's giving manual-page royalty, ngl. Stay pruned. π πβ¨
π¦ where this page comes from
- alpine 3.24: plocate-doc 1.1.24-r2 Β· GPL-2.0-or-later
- arch rolling: plocate 1.1.25-1 Β· GPL-2.0-or-later AND GPL-2.0-only
- centos-stream 10: plocate 1.1.22-11.el10 Β· GPL-2.0-or-later AND GPL-2.0-only
- debian bookworm: plocate 1.1.18-1 Β· GPL-2.0-or-later
- debian trixie: plocate 1.1.23-1 Β· GPL-2.0-or-later
- fedora 43: plocate 1.1.23-4.fc43 Β· GPL-2.0-or-later AND GPL-2.0-only
- fedora 43: plocate 1.1.25-2.fc43 Β· GPL-2.0-or-later AND GPL-2.0-only
- fedora 44: plocate 1.1.24-1.fc44 Β· GPL-2.0-or-later AND GPL-2.0-only
- fedora 44: plocate 1.1.25-2.fc44 Β· GPL-2.0-or-later AND GPL-2.0-only
- nixos 26.05: plocate 1.1.24
- nixpkgs unstable: plocate 1.1.25
- opensuse-leap 16.0: plocate 1.1.23-bp160.1.2 Β· GPL-2.0-only
- opensuse-leap 16.0: plocate 1.1.23-bp160.1.2 Β· GPL-2.0-only
- opensuse-leap 16.0: plocate 1.1.23-bp160.1.2 Β· GPL-2.0-only
- opensuse-leap 16.0: plocate 1.1.23-bp160.1.2 Β· GPL-2.0-only
- ubuntu jammy: plocate 1.1.15-1ubuntu2 Β· GPL-2.0-or-later
- ubuntu noble: plocate 1.1.19-2ubuntu2 Β· GPL-2.0-or-later
- ubuntu questing: plocate 1.1.23-1ubuntu1
- ubuntu resolute: plocate 1.1.23-1ubuntu3 Β· GPL-2.0-or-later
- ubuntu stonking: plocate 1.1.24-1ubuntu1 Β· GPL-2.0-or-later
- Copyright (C) 2005, 2007, 2008 Red Hat, Inc. All rights reserved
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms