I recently checked the disk usage on my Arch Linux system and was surprised to find that the root partition was 99% full!
First, I found that directory /var/log/journal/ was large. I did some research and found that this directory contains log files from systemd. By default, these logs take 10% of the space on the partition, which is not what I want.
My solution was to edit /etc/systemd/journald.conf. By default, all settings in this file are commented; I enabled and modified the SystemMaxUse line as follows:
I could have rebooted to have the change take effect, but instead I entered the following command:
# systemctl restart systemd-journald
Most of the old logs were then cleared, which reduced the root partition usage to 89%. It appears that logs are now mostly limited to the current day.
I found another large directory at /var/cache/pacman/, which is Pacman’s program storage cache. I used pacman to clean it up:
# pacman -Scc
That reduced my root partition usage to 46%. Much better! Clearly I’ll need to purge Pacman’s cache on a regular basis.