lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 17 Feb 2010 10:03:22 +0900
From:	KAMEZAWA Hiroyuki <kamezawa.hiroyu@...fujitsu.com>
To:	David Rientjes <rientjes@...gle.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	Rik van Riel <riel@...hat.com>,
	Nick Piggin <npiggin@...e.de>,
	Andrea Arcangeli <aarcange@...hat.com>,
	Balbir Singh <balbir@...ux.vnet.ibm.com>,
	Lubos Lunak <l.lunak@...e.cz>,
	KOSAKI Motohiro <kosaki.motohiro@...fujitsu.com>,
	linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: Re: [patch -mm 4/9 v2] oom: remove compulsory panic_on_oom mode

On Tue, 16 Feb 2010 16:54:31 -0800 (PST)
David Rientjes <rientjes@...gle.com> wrote:

> On Wed, 17 Feb 2010, KAMEZAWA Hiroyuki wrote:

> > > >  2. Second, I'll add OOM-notifier and freeze_at_oom to memcg.
> > > >     and don't call memcg_out_of_memory in oom_kill.c in this case. Because
> > > >     we don't kill anything. Taking coredumps of all procs in memcg is not
> > > >     very difficult.
> > > > 
> > > 
> > > The oom notifier would be at a higher level than the oom killer, the oom 
> > > killer's job is simply to kill a task when it is called. 
> > > So for these particular cases, you would never even call into out_of_memory() to panic 
> > > the machine in the first place. 
> > 
> > That's my point. 
> > 
> 
> Great, are you planning on implementing a cgroup that is based on roughly 
> on the /dev/mem_notify patchset so userspace can poll() a file and be 
> notified of oom events?  It would help beyond just memcg, it has an 
> application to cpusets (adding more mems on large systems) as well.  It 
> can also be used purely to preempt the kernel oom killer and move all the 
> policy to userspace even though it would be sacrificing TIF_MEMDIE.
> 

I start from memcg because that gives us simple and clean, no heulistics
operation and we will not have ugly corner cases. And we can _expect_
that memcg has management daemon of OOM in other cgroup. Because memcg's memory
shortage never means "memory is exhausted", we can expect that daemon can work well.
Now, memcg has memory-usage-notifier file. oom-notifier will not be far differnet
from that.

cpuset should have its own if necessary. cpuset's difficulty is that
the memory on its nodes are _really_ exhausted and we're not sure
it can affecet management daemon at el...hang up.

BTW, concept of /dev/mem_notify is notify before OOM, not notify when OOM.
Now, memcg has memory-usage-notifier and that's implemented in some meaning.

Thanks,
-Kame

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ