Exclude /media and /mnt from the paths updatedb scans when building the locate database.
Use the standard updatedb.conf setting.
Which setting matches this purpose?
PRUNEPATHS lists paths that updatedb should omit while building the database. PRUNEFS handles filesystem types.
Detailed explanation
Incorrect. PATH is a shell executable-search variable.
Incorrect. PATH is a shell executable-search variable.
Correct. PRUNEPATHS defines directory paths omitted from the database scan.
Correct. PRUNEPATHS defines directory paths omitted from the database scan.
Incorrect. MANPATH relates to manual-page lookup.
Incorrect. MANPATH relates to manual-page lookup.
Incorrect. LD_LIBRARY_PATH affects dynamic-library lookup.
Incorrect. LD_LIBRARY_PATH affects dynamic-library lookup.
Try it yourself
An example you can run in a temporary verification environment.
grep -E '^[[:space:]]*PRUNEPATHS=' /etc/updatedb.conf 2>/dev/null || trueExpected result
設定ファイルがある環境ではPRUNEPATHSの行。読み取りのみKey points
- PRUNEPATHS excludes paths
- PRUNEFS excludes filesystem types
- Configuration affects updatedb
Notes
- Environment: Linux / mlocateまたは互換updatedb.conf / 読み取りのみ
- Command output formatting can vary slightly by distribution or tool version.
- Run the example in a temporary directory or process when possible.
Foundation review
Read the scope first
Check whether the command acts on the current shell, a new process, an existing process, or a file.
Verify the observable result
Use the supplied command and compare the output with the expected result.