Taming the OOM killer
Posted Feb 12, 2009 14:32 UTC (Thu) by epa
In reply to: Taming the OOM killer
Parent article: Taming the OOM killer
The OOM killer does not come into play when malloc is called. If malloc is called when there in no memory there is no need to kill any processes, malloc simply fails and return the appropriate error code.
Ah, I didn't realize that. From the way people talk it sounded as though malloc() would always succeed and then the process would just blow up trying to use the memory. If the only memory overcommit is COW due to fork() then it's not so bad (though I still think some kind of vfork() would be a more hygienic practice).
to post comments)