You are not logged in.
Pages: 1
I recently used the guided Arch Linux installer with a "best-effort default partition layout" for disk configuration. After a couple of updates (Pacman -Syu), I'm seeing warnings that I'm running out of space. Cleaning out the pacman cache works, but even with the schedulers in place, this still happens every two weeks or so. Did I / the script not dedicate enough space? What's the ideal size of cache dedicated for Pacman? Can I dedicate more space now?
Last edited by Rec100 (2024-09-30 16:31:49)
Offline
Did I / the script not dedicate enough space?
From your description, it would appear so, wouldn't it? But you've not actually given us any information to work with. What is the partition layout, and (assuming the pacman cache is on the same filesystem as /, which it almost certainly is) how big is your root partition? And what else is taking up space on that partition?
What's the ideal size of cache dedicated for Pacman?
What is the ideal size for a shirt? If I wanted to buy a shirt, could you tell me the size to get? No, probably not.
For (a nearly meaningless) reference, my current system:
$ du -hd1 /var/cache/pacman/
4.6G /var/cache/pacman/pkg
4.6G /var/cache/pacman/
$ paccache # my own script version of this tool
doas ******** password:
$ du -hd1 /var/cache/pacman/
89.5M /var/cache/pacman/pkg
89.5M /var/cache/pacman/Can I dedicate more space now?
If you change your partitions and shrink / grow filesystems. But again, you've not told us anything about your partitioning or filesystems. Some set ups make this much eaiser (i.e., btrfs and / or LVMs).
Last edited by Trilby (2024-09-30 14:51:54)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Yes, pacman cache is on the same filesystem as /, which has 17.8GB.
$ du -hd1 /var/cache/pacman/
3.2G /var/cache/pacman/pkg
3.2G /var/cache/pacman/$ paccache -r && du -hd1 /var/cache/pacman/
==> no candidate packages found for pruning
3.2G /var/cache/pacman/pkg
3.2G /var/cache/pacman/I'm using paccache.timer defaults.
$ systemctl status paccache.timer
[sudo] password for user:
● paccache.timer - Discard unused packages weekly
Loaded: loaded (/usr/lib/systemd/system/paccache.timer; enabled; preset: disabled)
Active: active (waiting) since Sat 2024-09-28 16:25:40 CEST; 2 days ago
Invocation: 73f99a5cf8254b9297dc736ba18505a1
Trigger: Mon 2024-10-07 00:00:00 CEST; 6 days left
Triggers: ● paccache.service
Sep 28 16:25:40 host systemd[1]: Started Discard unused packages weekly.I just saw that Flatpak is also using some 3.8GB. D'uh. I will look into that. Thanks for your reference anyway. Gives me a better feeling for what other people use.
Offline
You may also want to look into the flags for paccache. It's been a while since I used it, but I'm pretty sure `paccache -r` will only remove what you no longer have installed. Much better benefits come from removing older versions of packages you still have installed. I recall using `paccache -ruk 2` or similar with the 2 being the number of versions of packages to be maintained. I always felt 2 was plenty: you have the current package if it needs to get reinstalled locally, and you have the previous to downgrade to if needed.
My own paccache script is age-based, so anything older than a given number of weeks old is purged (based on the assumption that if there was anything wrong in a package update, I'd have run into it by then).
Is 17.8G the total size of the root filesystem, or is that what is free / available? Either way that'd be plenty for me. My root filesytem is rarely uses over 3-4GB except when I let the pacman cache go as long as I had here. I typically use a 20G root partition and have never come anywhere close to running low on space, but I also run pretty lean systems with no big DEs (and certainly no flatpaks for me). If you want to use flatpaks and / or bigger DEs, then a bit larger root filesystem might be sensible.
Last edited by Trilby (2024-09-30 16:40:05)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
"paccache -r" will keep the last 3 versions of all packages. It seems like you're on a virtual machine though, so maybe you're happy to keep nothing if you're taking snapshots or something.
You can run that and then run "paccache -r -u -k 0" to all versions of packages that are no longer installed.
I have 16GB in the root file system not including the pacman cache, so with that it's currently at 21GB. You'll need more space if you want to use flatpak assuming /home is in your root partition as well. Though I run Plasma and have some larger applications installed like a benchmark program that is 3GB alone, so maybe my usage isn't normal.
Ryzen 7 9850X3D | AMD 7800XT | KDE Plasma
Offline
Pages: 1