,--------------- Forwarded message (begin)
Subject: Re: [PATCH] Prevent OOM from killing init
From: Jonathan Morton <[email protected]>
Date: Fri, 23 Mar 2001 20:45:43 -0500
>Hmm... "if ( freemem < (size_of_mallocing_process / 20) ) fail_to_allocate;"
Not sure this is that reasonable on a 4G box... 800M is a big chunk...
Why not base this on the vm's free goal. If I remember correctly it tries to keep one
second of pages ready for allocating. If memory is so tight that a second's worth of
memory does not exist. Note that I mean memory free in main memory and swap.
Think your malloc patch along with UID weighting (1-99 protected, 100-999 endangered,
1000+ open season - with poaching expected if there is no choise) will make help oom
processing.
Ed Tomlinson