linux check largest directories code example
Example 1: ubuntu du sort by dir size
du -Sh /path/to/dir | sort -rh | head -20
Example 2: find large files in ubuntu
sudo du -a /your_dir/ | sort -n -r | head -n 20
du -Sh /path/to/dir | sort -rh | head -20
sudo du -a /your_dir/ | sort -n -r | head -n 20