|
|
Log in / Subscribe / Register

Toward more predictable and reliable out-of-memory handling

Toward more predictable and reliable out-of-memory handling

Posted Dec 23, 2015 1:28 UTC (Wed) by ploxiln (subscriber, #58395)
In reply to: Toward more predictable and reliable out-of-memory handling by rgb
Parent article: Toward more predictable and reliable out-of-memory handling

I can't help but chime in with a "me too", I'd much prefer processes be killed quickly when free-able memory is close to running out. If it's anywhere near close, say less than 5% of memory available for use as fs cache, something is already wrong.

The last few times I ran into what should have been an OOM situation, everything just froze, for longer than I cared to wait (at least a few minutes). I've seen this for the whole system, and also for a couple processes in a memory cgroup. I've seen it with no swap at all, and also with some swap space. Freezing for ~15 seconds is worse than death IMHO.

I "devops" some servers that run some processes that occasionally act up, and I've resorted to writing a script that checks memory conditions every few seconds and if there isn't a nice large buffer of free+cache memory, goes about sending SIGTERM and then SIGKILL to the biggest members of the suspected set of processes (and notifying me).


to post comments


Copyright © 2026, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds