du -sh /* du -ah /
The first will give a directory summery, the second command will output sizes off all files, - hence a lot of output. You can redirect the output to a file (space permitting), then sort/examine it.
du -sh /* > sizes-summery du -ah / > sizes-full A beautiful command to sort space usage in decrease order: su - cd / du -s * | sort -rn | cut -f2 | xargs -d '\n' du -sh
My first guess is that you have an auto backup running. They are very good at filling up the nooks and crannies.
To find out what files are using the space use du
My favourite way ahead is:
1. su to become root. BE VERY CAREFUL FROM THIS POINT ON
2. cd / to go to the root of the file system
3. du | sort -rn > /tmp/greedy.txt to create a text file for browsing with less, or a text editor
du | sort -rn | less which allows you to scroll through the result immediately.
Why sort -rn ?
n makes the sort numerical, not alpha-numerical, so that 4 is treated as a smaller number than 10.
r reverses the sort order, putting the biggest first. So you will be able to track the really greedy files.
Hope that helps. And DON’T FORGET TO EXIT FROM THE root LOGIN