Remove zram size limit and disable zswap when using zram
Two fixes that I tested and deployed to build.archlinux.org:
zram-generator: Uncap max size of the zram device
Set "max-zram-size = none" to disable this unwanted limitation which
defaulted to creating zram-based swap with a maximum size of 4096MiB.
Fixes: dc8fa2bdfc86 ("common: Replace deprecated systemd-swap[1] with zram-generator")
zram-generator: use systemd-zram-setup@zram0 handler
Restarting swap.target doesn't apply configuration changes; instead we
can restart systemd-zram-setup@zram0 which seems to do what we wanted.
Bonus commit so that zramctl will display useful statistics:
zram: Disable zswap to prevent conflict with zram
When both zswap and zram are active, zswap sits in front of zram and
treats it as a backing store. We just want to use zram and not zswap
disguising itself as such; disable the latter so we can enjoy useful
zramctl statistics.
Implemented as tmpfiles.d/zram.conf which disables zswap at runtime.
Merge request reports
Activity
requested review from @klausenbusk and @jelle
added 1 commit
- abb23700 - zram: Disable zswap to prevent conflict with zram
Added one more change that disables zswap which was interfering with zram. Deployed it to lists.archlinux.org which complains about swap exhaustion daily, though I don't expect zram to behave much differently than zswap.
Edited by Evangelos FoutrasGot rid of all systemd-swap traces that were left on some servers, then deployed the zram config from the MR and verified that each server has 50% of its RAM as zram-based swap.
repro1 has a spacious 447.1G swap partition, so I'll see if we can disable zram on it and rely on zswap instead.
added 6 commits
-
abb23700...331314c8 - 3 commits from branch
master
- 6fe57bc7 - zram-generator: Uncap max size of the zram device
- 61bdf768 - zram-generator: use systemd-zram-setup@zram0 handler
- bbaa79c6 - zram: Disable zswap to prevent conflict with zram
Toggle commit list-
abb23700...331314c8 - 3 commits from branch
enabled an automatic merge when the pipeline for bbaa79c6 succeeds
mentioned in commit 94334302