mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Thomas Gleixner <tglx@linutronix.de>
To: Chris Ross <chris@tebibyte.org>
Cc: Chris Friesen <cfriesen@nortelnetworks.com>,
	Alan Cox <alan@lxorguk.ukuu.org.uk>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: Linux 2.6.9-ac16
Date: Sat, 18 Dec 2004 07:01:15 +0100	[thread overview]
Message-ID: <1103349675.27708.39.camel@tglx.tec.linutronix.de> (raw)
In-Reply-To: <41C2FF09.5020005@tebibyte.org>

On Fri, 2004-12-17 at 16:45 +0100, Chris Ross wrote:
> Hi Chris,
> 
> Chris Friesen escreveu:
> > As it stands, 2.6.10-rc2-mm4 still shows nasty behaviour in OOM
> > conditions, killing off more tasks than strictly required, and
> > locking up the system for 10-15secs while doing it.
> > 
> > I'd be much happier doing a quick and dirty scan and knocking off 
> > something *now* rather than locking up the system.  Surely it can't
> > take 60 billion cycles of cpu time to pick a task to kill.
> 
> Thomas Gleixner has been particularly interested the algorithms for 
> deciding which task to kill (like me he got fed up with it picking the 
> ssh daemon first).
> 
> See for example the thread at 
> http://marc.theaimsgroup.com/?t=110189482200001&r=1&w=2
> 
> Some of the delay is by design: when OOM is reached we kill something 
> off, wait a bit for the memory to be freed and become available to the 
> system again, check whether now have enough memory, if not rinse and 
> repeat. However, as I recall this is compounded by 2.6.9 having some 
> nasty rentrancy problems causing the OOM killer to be called something 
> like 100 times instead of once.
> 
> Perhaps Thomas could enlighten us as to the current state of play here?

Andrea fixed the invocation problem, which also handles the reentrancy
problem in a clean way. It get's us rid of the ugly count, time,
whatever mechanisms in out_of_memory which was designed to cover the
invocation problem but was not able to prevent reentrancy and the
resulting overkill (kill a random amount of processes even if enough
memory is available). 

I added the "Take child processes into account" modification for the
whom to kill selection on top of that and I was not able to make it
missbehave with my different test scenarios.

The patches are available in parts in this thread and the final combined
patch is there:
http://marc.theaimsgroup.com/?l=linux-kernel&m=110269783227867&w=2

2.6.10-rc3 contains a partial fix for the erroneous invocation problem,
but it is not as effective as Andrea's solution and it still runs into
overkill once the oom mechanism is invoked.

Andrea's fix and the selection changes should go into 2.6.10, but I
suspect that the VM gurus havent still reached a point, where they
agree. I also have the feeling that the problem is partially ignored.
Obviously has everybody plenty of memory in his boxes. </rant off>

Andrea's fix revealed some GFP_ flag related problems, which should be
addressed seperately. Detailed explanation is in the mail thread.

tglx



  reply	other threads:[~2004-12-18  6:01 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-12-16 18:43 Alan Cox
2004-12-17 11:23 ` Arjan van de Ven
2004-12-17 18:54   ` Francois Romieu
2004-12-17 13:08 ` Chris Ross
2004-12-17 14:51   ` Chris Friesen
2004-12-17 15:45     ` Chris Ross
2004-12-18  6:01       ` Thomas Gleixner [this message]
2004-12-18 15:11         ` Bill Davidsen
2004-12-18 15:06           ` Jan Engelhardt
2004-12-18 16:01             ` Chris Ross
2004-12-20 14:48             ` Alan Cox
2004-12-20 16:19               ` Chris Ross
2004-12-20 19:54                 ` Alan Cox
2004-12-19 16:22           ` Thomas Gleixner
2004-12-17 23:35 Chuck Ebbert
2004-12-20 17:27 ` Chris Friesen
2004-12-21  9:11 Chuck Ebbert
2004-12-21 23:49 Chuck Ebbert
2004-12-21 23:58 ` Nick Piggin
2004-12-22  2:49 ` Con Kolivas
2004-12-22  6:44 Chuck Ebbert

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1103349675.27708.39.camel@tglx.tec.linutronix.de \
    --to=tglx@linutronix.de \
    --cc=alan@lxorguk.ukuu.org.uk \
    --cc=cfriesen@nortelnetworks.com \
    --cc=chris@tebibyte.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®