Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm out of space on /var

  25G   25G     0 100% /var

It looks like mlocate.db is the problem:

# find /var -printf '%s %p\n' | sort -nr | head
13140140032 ./lib/mlocate/mlocate.db.cgLMAM
12409839616 ./lib/mlocate/mlocate.db.MqGeqe

# cat /etc/updatedb.conf
PRUNE_BIND_MOUNTS="yes"
PRUNENAMES=".git .bzr .hg .svn"
PRUNEPATHS="/tmp /var/spool /media"
PRUNEFS="NFS nfs nfs4 rpc_pipefs afs binfmt_misc proc smbfs autofs iso9660 ncpfs coda devpts ftpfs devfs mfs shfs sysfs cifs lustre_lite tmpfs usbfs udf"

I don't see anything else to prune. So how can I fix this? Thanks

share|improve this question
    
WOW! that is more than 10GB each! –  rubo77 May 4 at 12:49

1 Answer 1

up vote 6 down vote accepted

The /var/lib/mlocate/mlocate.db.?????? files are leftover temporary files from a (probably) interrupted updatedb run. They don't appear on either of my Ubuntu 11.10 systems, except when updatedb is running. Delete them:

sudo rm -f /var/lib/mlocate/mlocate.db.??????

then, to be sure, run

sudo /etc/cron.daily/mlocate
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.