0

DUPLICATE of Disk slowly filling up but no visible file size changes

What is method for locating culprit to "full" disk? I have nothing large on the filesystem, but "phantom files" seem to have filled up the / partition.

DU does not show where the issue is:

root@godzilla:/# du -hx --max-depth 1
4.0K    ./snap
15M     ./bin
17M     ./sbin
1.8G    ./usr
8.0K    ./media
6.4G    ./var
56K     ./tmp
167M    ./boot
4.0K    ./stuff
4.0K    ./srv
56K     ./home
118M    ./root
4.0K    ./mnt
8.2M    ./etc
856M    ./lib
4.0K    ./lib64
4.0K    ./opt
16K     ./lost+found
9.3G    .

df shows that the / partition is full!

root@godzilla:/# df -h
Filesystem                         Size  Used Avail Use% Mounted on
udev                               1.9G     0  1.9G   0% /dev
tmpfs                              395M   12M  384M   3% /run
/dev/mapper/Godzilla--PC--vg-root  225G  225G     0 100% /
tmpfs                              2.0G     0  2.0G   0% /dev/shm
tmpfs                              5.0M     0  5.0M   0% /run/lock
tmpfs                              2.0G     0  2.0G   0% /sys/fs/cgroup
tmpfs                              395M     0  395M   0% /run/user/1000
/dev/sdb                           687G  290G  363G  45% /stuff/drive2
/dev/sdc1                          699G  361G  338G  52% /stuff/drive3

1 Answers1

0

To find the folders with the largest files in / run du / 2>/dev/null | sort -n -r | head -n 10. This will allow you to narrow down your search to a specific folder under /.

Be aware this invocation of du will only list folders, but will find a folder full of small files. To reveal the largest file add a * to the du command. eg. du /* 2>/dev/null | sort -n -r | head -n 10. Also using du -h would confuse sort.

J. Starnes
  • 1,969