Cheat Sheets Cpanel and WHM Linux Commands Linux Security Linux Software / Scripts Linux Tricks

Tracking down the biggest folders

Finding the largest files to clean up a partition is very important.

The command will list the largest folders so you can start your search to remove the files in it and free up some space!

du -ax --max-depth 1 /var/cpanel | sort -n | tail

This is a great command to simply find what folders are the biggest in a directory. You can replace the /var/cpanel with any folder and it will list everything in there and how big they are in order.

Once you find the big folder then search inside of that to find the biggest folder in there and so on.