I have a headless server running fedora34 (arm64) with 512M of ram and the same amount of zram but every time I launch a dnf update I get killed by the oom killer :
free -m
total used free shared buff/cache available
Mem: 428 92 283 0 52 325
Swap: 427 39 388
Out of memory: Killed process 13778 (dnf) total-vm:487472kB, anon-rss:27676kB, file-rss:816kB, shmem-rss:0kB, UID:0 pgtables:988kB oom_score_adj:0
Is there any workaround to this ? I have a debian that runs on 256Mb without issue so I wonder if this is a bug on dnf ?
I haven’t run into this in a long time (probably a lot because I am no longer a professional sysadmin!), but when I ran into this in the past, what I did was split the transaction: something like:
for l in {a..z}; do sudo dnf -y upgrade "$l*"; done
Followed by a final sudo dnf -y upgrade to catch anything which starts with a number or something.
Thanks a lot, I love how you learn every day on linux
One neat thing is that zram swap will combine with the fileswap created so I managed to get away with 400M swapfile since I was also a bit short on disk space
I’m running the cloud edition and basically stopped everything (auditd, policykit, resolved …)