Why do “df” and “du” display different used space values on an LVM volume? [closed]

StackOverflow https://stackoverflow.com/questions/13081888

  •  14-07-2021
  •  | 
  •  

Вопрос

[root@local ~]# df -h
Filesystem            Size  Used Avail Use% Mounted on
/dev/mapper/VolGroup00-LogVol00
                      524G  465G   32G  94% /
/dev/sda1              99M   13M   82M  14% /boot
tmpfs                  18G     0   18G   0% /dev/shm
[root@local ~]# du -hs /
57G /

Why the show is not the same, but I did not use so much space.

Это было полезно?

Решение

Chances are that you deleted a file that was still being written to. While it won't be picked up by du (it only looks at files that still 'exist"), df will notice the missing free space. Try a lsof | grep deleted

Лицензировано под: CC-BY-SA с атрибуция
Не связан с StackOverflow
scroll top