Re: [PATCH v3] oom-kill: add lowmem usage aware oom kill handling

From: Vedran FuraÄ
Date: Thu Jan 28 2010 - 19:57:44 EST


Alan Cox wrote:

> On Fri, 29 Jan 2010 01:25:18 +0100
> Vedran FuraÄ <vedran.furac@xxxxxxxxx> wrote:
>
>> Alan Cox wrote:
>>
>>> Am I missing something fundamental here ?
>> Yes, the fact linux mm currently sucks. How else would you explain
>> possibility of killing random (often root owned) processes using a 5
>> lines program started by an ordinary user?
>
> If you don't want to run with overcommit you turn it off. At that point
> processes get memory allocations refused if they can overrun the

I've started this discussion with question why overcommit isn't turned
off by default. Problem is that it breaks java and some other stuff that
allocates much more memory than it needs. Very quickly Committed_AS hits
CommitLimit and one cannot allocate any more while there is plenty of
memory still unused.

> theoretical limit, but you generally need more swap (it's one of the
> reasons why things like BSD historically have a '3 * memory' rule).

Say I have 8GB of memory and there's always some free, why would I need
swap?

> So sounds to me like a problem between the keyboard and screen (coupled

Unfortunately it is not. Give me ssh access to your computer (leave
overcommit on) and I'll kill your X with anything running on it.


--
http://vedranf.net | a8e7a7783ca0d460fee090cc584adc12
begin:vcard
fn;quoted-printable:Vedran Fura=C4=8D
n;quoted-printable:Fura=C4=8D;Vedran
adr:;;;;;;Croatia
email;internet:vedran.furac@xxxxxxxxx
x-mozilla-html:FALSE
url:http://vedranf.net
version:2.1
end:vcard