#zswap — Public Fediverse posts
Live and recent posts from across the Fediverse tagged #zswap, aggregated by home.social.
-
Estoy muy #pollavieja y no veo ventaja o sentido de usar #swap a pesar de #zswap o #zram. Además no entiendo las diferencias entre unas y otras. Hablo en el contexto de PC de usuario. No servidores ni pollas en vinagre.
De momento sigo sin swap y me va genial.
-
Se viene un #debian virtualizado para seguir jugando con cositas del núcleo, memoria, #zram, #zswap, #hardening y #optimización 🙂
-
I've been trying to figure out how to address/work around #Linux 's hunger for RAM and non-ideal/insufficient controls around this. I remembered seeing an article by #KDE about them trying to address this themselves on their new distro and stumbled upon this issue they created - pertaining to topics like #Zram, #Zswap, etc.
It's great to see that this issue is acknowledged for once instead of the constant stream of Linux extremists swearing that it's not an issue, or somehow it being an issue is an attack to them and their beloved OS/distro/DE. Also it's always a suspicion I have but even in this short issue thread, it's clear that Linux people (hence, devs) are often only familiar with #Windows (and #Android), so the benchmark is always them - which isn't a problem 'cept they both suck ass (in a lot of aspects but esp this topic on RAM usage/OOM handling).
I'm glad to see at least one comment mentioning how #Apple does it on #macOS (maybe also #iOS) - which offers a far superior experience and is exactly why 8 freaking GB RAM on a #Mac or 4GB RAM on an #iPhone is no big deal at all (plenty, even), unlike on other systems/platforms. It's high time for Windows to die so our beloved Linux devs look at Apple instead for benchmark/inspirations. It doesn't help ofc that macOS can easily be insufferable to use when ure already on Linux land, but I promise it won't even be close to half as shitty as Windows, and there def are alot of things we could learn/benefit from and replicate.
🔗 https://invent.kde.org/kde-linux/kde-linux/-/issues/552
🔗 https://mastodon.social/@verdre/116182376380456569 -
I've been slowly moving to #zswap. Though now, quite quickly thanks to this article. 😅 Especially when using #NVMe, the advantage is quite apparent. 😉
https://chrisdown.name/2026/03/24/zswap-vs-zram-when-to-use-what.html
-
Ah, the classic "Let me explain why you're wrong about #zswap and zram" rant, complete with obligatory self-promotion links. 🙄 Who knew compressing RAM could be so controversial? But hey, if you need more jargon in your life, this blog's got you covered. 💻🎉
https://chrisdown.name/2026/03/24/zswap-vs-zram-when-to-use-what.html #zram #RAMcompression #techrants #selfpromotion #HackerNews #ngated -
@geheimorga gibt #zram und #zswap https://wiki.archlinux.org/title/Zswap für moderne Systeme 😉
-
TIL about #zswap "a compressed write-back cache for swapped pages, as a form of virtual memory compression". this will hopefully came in handy soon for performance :)
also there are zram and zcache (https://askubuntu.com/a/472227 has a comparison) -
interesting discussion on the odd fact that in Linux we have #zram aka #zramswap (compressed swap in memory) and #zswap (compressed swap buffer in memory which decompresses the data before evicting it to a disk-based backing store if memory is getting low enough), without having simple compressed swap on disk:
https://unix.stackexchange.com/questions/740334/how-to-compress-disk-swap
-
Some various performance improvements for Debian 12 Bookworm
Here some various improvements I implemented on some of my Debian 12 Bookworm servers in order to improve performance.
zswap: use zsmalloc allocator with newer kernel
If your system has little memory, you might be using zswap already. When memory is getting full, the system will try to swap out less used data from memory to a compressed swap in memory instead of writing it immediately to a […]
https://blog.frehi.be/2024/11/29/some-various-performance-improvements-for-debian-12-bookworm/
-
Zswap - I'm slightly saddened by the reality, that #zswap compresses data only in the memory page pool and when it writes data out to #disk, the data is decompressed. Oh why?! Why it doesn't write the compressed data to disk, and then only when needed, read it back and decompress it. At least in most of my use cases, the fact is that the stale data written to #swap, won't most likely be ever needed, and will get discarded without being ever read back to #RAM. #Linux -
Комфортная работа в Linux. ZRAM и гибернация — особенности взаимодействия
Далеко не все работающие на сегодняшний день компьютеры и ноутбуки имеют объём оперативной памяти, гарантированно перекрывающий потребности возложенных на них задач. Для ноутбуков среднего и нижнего ценовых сегментов типовой задачей может быть работа с большим количеством открытых вкладок браузера, для более дорогих ноутбуков или системных блоков — ресурсоёмкие игры, рендеринг, видеомонтаж, для серверов — базы данных и прочие требовательные к RAM задачи. Когда RAM близка к заполнению, данные неактивных в данный момент приложений начинают выгружаться из неё на диск, в файл или раздел подкачки. Когда при запуске ещё одного приложения, открытии файла или вкладки браузера, потребуется срочно освободить нужный для этого действия объём оперативной памяти, пауза в работе компьютера может быть заметна, даже когда в системе стоит SSD. На HDD же, в случае запуска ресурсоёмкого приложения, подкачка может приостановить работу и на несколько десятков секунд. Кроме того, постоянная подкачка на SSD приводит к его ускоренному износу, что с учётом цены SSD, также не лучшее решение. Если типовые задачи вашего компьютера требуют в 2-3 раза больше оперативной памяти, чем стоит в системе, наилучшим решением будет её увеличение. Если установить больше памяти невозможно технически (самый, пожалуй, острый пример — нетбуки на процессоре Atom с максимально возможным объёмом RAM 2 Гб) — ресурсоёмкие задачи лучше перенести на более мощный аппарат, а этот использовать только для офисно-браузерных задач (отдать детям или родителям). В случае же менее значительной нехватки (в пределах половины имеющегося объёма RAM), есть возможность улучшить ситуацию.
-
This is the power of zswap!
A before and after screenshot of the same operation running with high swap usage on one of our hypervisors with RAM constraints.
-
@yayroos Might depend on what are your RAM and swap specs. In my experience there's stuff that Linux will never, *ever* release once it lands on swap, in particular if your uptime is long enough to include eg.: system libraries getting updated.
The one change people tend to recommend is lowering vm.swappiness to *prevent* too much stuff from landing into swap in the first place, and from what I recall Ubuntu's swappiness default is unusually high. Can't recall the file where the setting is but I'm gonna bet it's /etc/sysctl.conf .
Another advice depending on the RAM and swap is to enable #zswap (compressed swap) but IIRC that doesn't help much unless you are filling already about half of your swap during your normal workflow anyway. Debian and Arch have decent instructions to enable it, but I don't know if Ubuntu benefits from adjusting them.
-
To be clear I had working #zswap setups before, they just stopped working.
6.4 changed several things (remove frontswap, cgroups support, inclusion in /proc/meminfo), but I saw no changes in the patches in documentation about how to activate it. Maybe I'm just missing some memcg wizardry.
And all info I found about zswap predates 6.4 so I don't know if it's unchanged on purpose, or just "not updated yet". -
https://www.reddit.com/r/linux/comments/11dkhz7/zswap_vs_zram_in_2023_whats_the_actual_practical/
>#zswap vs #zram in 2023, what's the actual practical difference?
Interesting discussion on this eternal debate.
It's done my head in for years, but typically i lean to no swap partition/file, then use `systemd-swap`.
$> sudo blkid | grep z
/dev/zram5: ... TYPE="swap"
/dev/zram3: ... TYPE="swap"
/dev/zram1: ... TYPE="swap"
/dev/zram6: ... TYPE="swap"
/dev/zram4: ...TYPE="swap"
/dev/zram2: ... TYPE="swap"
/dev/zram0: ... TYPE="swap"
/dev/zram7: ... TYPE="swap":arch: