disk full but df says there is room

"No space left on device" with free gigabytes: the disk is out of inodes, the slots for files. Find the folder with too many small files.

disksfiles

steps
  1. df -h

    the space left

  2. df -i

    the inodes left: IUse% at 100% is the problem

  3. sudo du --inodes -xd 1 / | sort -n | tail

    the folders with the most files, at the top of the disk (GNU)

  4. sudo find /var -xdev -type f | cut -d/ -f2-4 | sort | uniq -c | sort -n | tail

    where under /var the files are

notes
  • The usual ones: session or cache folders, mail queues, old kernels' headers. Delete what you know is safe.
commands used

dfdufind

Each has a page in lore: lore df opens it.