I’ve had EndeavourOS installed for about 2 years now and my install has accumulated a lot of data. I use QDirStat (it shows directory tree statistics, based off of WinDirStat) to see where the big offenders are, and it showed the following:
/var = 25.6 GB
/var/cache = 22.6 GB
/var/log = 2.4 GB
/usr = 11.4 GB
/usr/lib = 6.1 GB
/usr/share = 3.3 GB
Are there any commands to clean this up?
xircon
October 27, 2021, 9:36pm
2
sudo paccache -r
sudo paccache -ruk0
Will purge your pacman cache, 1) leaving 3 latest of each installed package and 2) of programs no longer installed.
4 Likes
sudo paccache -r
==> finished: 2101 packages removed (disk space saved: 15.18 GiB)
sudo paccache -ruk0
==> finished: 163 packages removed (disk space saved: 180.56 MiB)
So, /var decreased in size by 15.32 GB which is great! But /usr stayed the same (still 11.4 GB). Is there any command to lessen space in /usr ?
dalto
October 27, 2021, 9:53pm
4
You would have to dig through it in more detail to pinpoint if there is an issue in one spot. However, most of what is in /usr
is installed software. You may need to remove unused software to clean that up.
xircon
October 27, 2021, 9:53pm
5
Only uninstall stuff. What DE are you running? Der, was going to recommend qdirstat
XFCE
Most of the data in /usr is /usr/lib and they’re just library files (1.9 GB), the other data is /usr/share which is mostly fonts.
So, I guess there’s not much to clean there. Thanks for the help everyone!
xircon
October 27, 2021, 10:10pm
7
1 Like
This is a pretty good article:
1 Like
You need to make sure there’s another sudo in there or it errors out
sudo pacman -Qtdq | sudo pacman -Rns -
It did save another 185 MB though
xircon
October 28, 2021, 7:59am
10
Oops I didn’t test… It was from memory and there ain’t nothing pre about my senility
pebcak
October 28, 2021, 8:07am
11
The first sudo is not actually needed.
2 Likes
system
Closed
October 30, 2021, 8:08am
12
This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.