Page MenuHomeFreeBSD

Don't package /var/db/locate.database
ClosedPublic

Authored by matthew on May 27 2024, 5:06 PM.
Referenced Files
Unknown Object (File)
Mon, Aug 18, 12:12 PM
Unknown Object (File)
Sun, Aug 17, 2:15 PM
Unknown Object (File)
Wed, Aug 13, 10:59 PM
Unknown Object (File)
Jul 20 2025, 6:43 PM
Unknown Object (File)
Jul 20 2025, 10:53 AM
Unknown Object (File)
Jul 20 2025, 9:36 AM
Unknown Object (File)
Jul 20 2025, 9:16 AM
Unknown Object (File)
Jul 19 2025, 11:02 PM
Subscribers

Details

Summary

... or install an empty file.

The locate database is a mutable working file, and unsuitable to be
managed by pkg(8). locate(1) copes gracefully with the absence of
this file. Running /etc/periodic/weekly/310.locate will create the
locate database with the correct ownership and permissions.

Having the locate.database file as part of the FreeBSD-runtime package
means it gets zeroed if ever that package gets updated, which is
excessive, given that updating packages will typically only change a
relatively small number of the _filenames_ on the system -- unlike the
file contents. Plus it always causes it to flag as modified when
verifying checksums, but /var/db/locate.database is expected to be
modified by the user.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 57937
Build 54825: arc lint + arc unit