• 0 Posts
  • 1 Comment
Joined 2 years ago
cake
Cake day: June 9th, 2023

help-circle
  • For whatever it’s worth - I have a laptop with 4GB of RAM and a 4GB ZRAM device, and it can’t use all the ZRAM before everything grinds to a halt. I think the way ZRAM works best is if it can “swap out” (compress) anonymous pages that aren’t actually needed again right away, freeing up the fast memory for disk caching and other memory needs.

    In my case, I think I can reach a point where the amount of memory Linux needs simultaneously active goes beyond the 4GB of RAM, so it’s just compressing/uncompressing forever and getting nowhere.

    So, I think I’d argue that maybe you can’t go too big? I think only anonymous pages can get compressed, and there’s probably only so many gigabytes of those in memory at any given time.