I appear to have lost a couple of GB in an ext4 root filesystem (under llvm on centos 7.1 in a VMWare ESX VM if that matters).
[someone@somewhere ~]$ sudo du -xsm /
4561 /
yet:
[someone@somewhere ~]$ sudo df -m /
Filesystem 1M-blocks Used Available Use% Mounted on
/dev/mapper/vg_sys-lv_root 8944 7562 956 89% /
I thought maybe something was under a mount point, so I tried this:
[someone@somewhere ~]$ sudo mount --bind / /vp
[someone@somewhere ~]$ sudo du -xsm /vp
4561 /vp
Maybe a deleted file still in use by a process:
sudo lsof | grep deleted
Doesn't show anything significant.
Nor does looking for sparse files using the following command as root (command found here):
find / -type f ! -size 0 -exec perl -le 'for(@ARGV){open(A,"<",$_)or next;seek A,0,4;$p=tell A;seek A,0,2;print if$p!=tell A;close A}' {} +
So, where else could my data be, what does df know that du doesn't in this case? I also checked df -i and less than half the inodes are in use.