I got a cheap netbook style laptop for traveling some weeks ago (HP Stream 11" with 4 GB of RAM and a N4120). Didn't expect much more from this hardware than opening a few browser tabs and doing some retro gaming via Steam.
Shared RAM with graphics card means that 3.64 GB of RAM are effectively usable for the OS. This was even too little RAM to open a handful of tabs w/o having tabs being unresponsive for seconds sometimes in a very annoying way. Another thing which made trouble was the Wifi - I guess it went into power saving, was swapped and didn't load fast enough to provide a good experience. (Of course I wasted an hour checking for Wifi drivers/support.)
In short: Even for my low expectations for this laptop it was an underwhelming experience.
First step was to look at my vm.swappiness and set it to 10, which already helped, but still the machine had hiccups and annoying timeouts.
In a last, desperate effort I enabled ZRAM on the laptop... and literally WTF: Saying it is a night and day difference doesn't do the experience justice. Typing this words now on the Stream, which I use exactly the same way as my much more beefy other machines (my next worst computer has 8G of RAM and an Intel Core i3), browsing with 10 open tabs, e-mail client open on another virtual desktop... it is crazy, it makes the Stream fun to use and I use it at home for everything which isn't heavily CPU/IO bound.
What surprised me the most: No hiccups, no timeouts and it even fixed the Wifi issues on this little machine. Didn't expect this would be possible, especially with a N4120 and 3.64 GB of RAM.
In short, my laptop changed from not even reaching my low/realistic expectations to being my favorite technical purchase of the last years, thanks to ZRAM.
Besides making this a ZRAM appreciation post, I really want to spread the word about it. Especially for old hardware and limited RAM situations, IMHO it should be the first thing which comes to mind/is recommended.
Fedora and PopOS use it by default, so it is well tested and should IMHO again, be a default at least for desktop setups.
Give it a try - supposedly it even improved the experience on much more beefy computers for gaming etc.
How does this compare to zswap. For me, if you still want a swap device on a real disk, this might be better? Idk >.<
Edit: arch has zswap enabled by default https://wiki.archlinux.org/title/Zswap - someone below says it is better if you have zswap when you already have a swap device :)
You don't want to combine zram swap and physical swap. When zram swap is full, you'll get LRU inversion because it won't ever evict from zram swap.
Either zram-only or physical+zswap.
Thanks .
I have a very shitty notebook this is likely to be very useful for ;p
Sorry, just a user myself and because ZRAM is default on Fedora and was easy to setup on Debian, I am just using it.
On the Stream, I have a 4G physical swap partition as a backup, though. AFAIK the physical partition will be utilized by ZRAM when needed. (ZRAM simply has higher priority swap).