In this article I want to show you a neat little tool: ncdu. Ncdu stands for NCurses Disk Usage and helps you get an fast overview of the disk usage.
Normal way
Normally I would check the disk using df (disk free) with the parameter -h for human readable.
df -h
Then take a look at the filesystems either having the highest usage (Use%) or that store the most data (Used). This way you can start digging deep layer by layer _du_
(wiki) to find the cause of unusual disk usage.
ncdu
The genious thing with ncdu is, that it searches directories and subdirectories to give you a neat overview, sorted by size. This way you can crack down on issues way faster.
First you should be updating your sources, apply pending upgrades and then install ncdu.
apt update -y && apt upgrade -y && apt install ncdu
Once this is done, the program can be run from the shell.
ncdu
[video width=“1920” height=“1080” mp4=“https://blog.hackzenwerk.org/wp-content/uploads/2018/07/ncdu.mp4”][/video]
Cheers,
Ori