March 24, 2026

Swap Wars: The Compression Strikes Back

Debunking Zswap and Zram Myths

Linux users brawl: “Use zswap!” vs “Prove it” skeptics

TLDR: Author says most people should use zswap and avoid mixing zram with disk swap, claiming it can slow everything down. Comments split between fans reporting real wins, skeptics demanding benchmarks, and practical users asking for encrypted-hibernation guides—making this a must-watch debate for anyone with a slow, laggy laptop.

Linux’s latest memory hot take just dropped, and the comments lit up. The author says: pick zswap (compress-in-RAM, auto-spill-to-disk) for most people, and only use zram (a compressed RAM drive with a hard limit) if you truly know what you’re doing. His warning shot: mixing zram with disk swap can shove the stuff you need onto slow storage and make everything worse. Cue the Swap Wars. Read the piece here: the article.

Veterans chimed in fast. nephanth reminisced about early SSD days—everyone feared “wearing out” drives, and setting up zram was “tedious.” patrakov brought the surgical strike: agree with zswap—if you actually have a disk for swap—but slammed zram + other swap as “dead weight,” echoing the article’s danger zone. On the flip side, jitl cheered real-world wins: Kubernetes now supports swap, and zswap is “a great boon.”

Meanwhile, the crowd demanded receipts. guenthert’s “show me the numbers” became the rallying cry, with others asking for how-tos on encrypted swap and hibernation from adgjlsfhk1. Jokes flew about “thinking of the SSD’s feelings,” and someone dubbed LRU inversion “a monster from Stranger Things.” Bottom line: the article says zswap by default, but the thread’s split between believers, skeptics, and the “give me a guide, not vibes” crew.

Key Points

  • The article advises most users to prefer zswap over zram for compressed swap on Linux.
  • zswap integrates with kernel memory management, compresses pages in RAM, and tiers cold data to disk.
  • zram is a compressed RAM block device with hard capacity; when full, it offers no eviction and can trigger OOM or LRU inversion.
  • Using zram alongside disk swap is discouraged because it can retain cold pages in RAM and push hot pages to slow disk.
  • If zram is used, pair it with a userspace OOM manager (systemd-oomd or earlyoom); on servers, zram is not cgroup-accounted, breaking isolation.

Hottest takes

"zram + other swap = bad due to LRU inversion" — patrakov
"thank goodness Kubernetes got support for swap; zswap has been a great boon" — jitl
"So much polemic and no numbers? If it is a performance issue, show me the numbers!" — guenthert
Made with <3 by @siedrix and @shesho from CDMX. Powered by Forge&Hive.