/var/lib/mlocate does not respect Unix FHS

Bug #224185 reported by Jörg Höhle
4
Affects Status Importance Assigned to Milestone
mlocate (Ubuntu)
Confirmed
Undecided
Unassigned

Bug Description

Binary package hint: mlocate

The package findutils once moved /var/lib/locate to /var/cache/locate, witness the following comment in /var/lib/dpkg/info/findutils.postinst:

if [ "$1" = "configure" ]; then
  # up to 4.1.7-2 locatedb was in non-FHS-dir /var/lib/locate
  if dpkg --compare-versions "$2" le-nl "4.1.7-2" ; then
    if [ -f /var/lib/locate/locatedb ]; then
      mv /var/lib/locate/locatedb /var/cache/locate/
      rmdir /var/lib/locate 2>/dev/null || true

The same should apply to mlocate.
I'm using 0.18-2ubuntu1 on a system upgraded from Gutsy to Hardy (release).

Revision history for this message
Colin Watson (cjwatson) wrote :

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=494966 (which I can't link properly right now due to bug 290802) asserts that moving the mlocate database to /var/cache would be wrong at present because it is not properly regenerated if deleted - at least, not until the updatedb cron job is next run, and before that locate will not work. (I'm not actually entirely sure that this is a good reason, but it's worth mentioning because any move should be coordinated with Debian.)

Changed in mlocate (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.