Is there a way to prevent freezing of the system due to low memory? In KDE i keep running memory widget that lies through its teeth as any good politician does. And I cannot keep checking mem. Also, this never ever happens on MacOS or, and I hate to say that, Windows, they slow down but never totally freeze so that i have to remove power from the box.

Is there any thing that I can setup (or I have setup wrong) to avoid this (and no, watching my memory usage is not the answer, it is 2022, not 1980s). Btw, i tried completely disabling swap but that does not really help because sometimes it is ok to have cache. But he issue is that the low memory killer does not really work (or it works but in a utterly useless way). Why is there not some watcher that just keeps some essential system access (SSH, terminals, keyboard, graphic system)


I am using latest Debian with KDE, 8 GB memory, SSD HDD, i5 Intel. Whenever I open way too many tabs in firefox or have a virtual machine running and then use firefox, the system starts to slow down terribly until it becomes unresponsive. Interestingly, keyboard interrupts seem to have lower priority than mouse, because i can still see mouse moving (terribly slowly though) but say alt + F4 does not do anything. Sometimes I am able to get to a terminal by ctrl + alt + F2 but that is usually as far as I get. The system cannot be accessed by ssh either.

There should be a low memory process killer but it does not work, or to be more precise because the system gets slowed down by overusing HDD (i assume that most time is due to interrupts, guessing from past experience and general terrible performance of linux and usb drives where copying takes ridiculous amounts of CPU in interrupts). Neither can I invoke the process manually (again, i guess if hdd interrupts take over, keyboard has no priority and the command is never received. I tested the sysreq command when the system is operational and it works).

  • You might look into /proc/$PID/oom_score_adj process parameter and help the OOMK make better choices, but I'd be trying to figure out what program is grabbing all the memory, and figure out how to stop it. FF used to do this to me pn macOS, but it hasn't in a while, is yours recent?
    – Hack Saw
    Commented Oct 28, 2022 at 13:57
  • 1
    Does this answer your question? Why doesn't Linux protect memory like Windows? Commented Oct 28, 2022 at 14:01
  • What @HackSaw wrote + if you are not happy with the IRQ's relative priorities, you can boot irqthreaded and then adjust your desired rt priorities to each on of the corresponding threads.
    – MC68020
    Commented Oct 28, 2022 at 14:08

1 Answer 1


If you have 4GB of ram and 4GB of swap, the the out of memory handler will not trigger until we’ll past the point you are thrashing your disk with swap in reads to restore pages and writes to swap out pages.

If you want the OOM handler to trigger closer to your ram size you will need to configure it so.

I’m not knowledgeable on Windows, but I suspect their OOM handler starts triggering at the point you are using close to your ram size.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .