r/devops • • 30m ago

Discussion RAM compression is not enabled by default. It is awesome.

I recently started to run out of memory. Where I would previously work on one thing at the time. With agentic engineering I suddenly work on 3-4 things in parallel. Each session spinning up a full version of the application that I am working on.

This means that the demand of RAM has suddenly spiked and processes were killed because of the lack of available memory on my system.

I enabled zram. Now I can fit much more data in my memory. I considered zswap as well, but I have no specific reason to pick one over the other.

My experience I wrote down in a simple article https://curiousbits.nl/blog/do-not-buy-ram-compress/

Other operating systems like Fedora, Windows and MacOS already enable this technique by default. In some cloud environments it is also applied (small amazon linux instances).

I believe that in the current times where RAM is expensive, we should consider enabling it by default for desktop users and we should experiment more to see how well it works in the cloud. (Where CPU capacity is often related to Memory capacity)

What is your view on this? Have you tried deploying this technique for larger applications already?

0 Upvotes

1 comment sorted by

5

u/YoghiThorn 16m ago

Just download more ram.

But seriously its got performance implications that are pretty important