Re: [PATCH] oom: avoid killing init if it assume the oom killed thread's mm

2013-09-25 Thread Ming Liu
On 09/26/2013 01:56 AM, David Rientjes wrote: On Wed, 25 Sep 2013, Ming Liu wrote: We shouldn't be selecting a process where mm == init_mm in the first place, so this wouldn't fix the issue entirely. But if we add a control point for "mm == init_mm" in the first place(ie. in oom_unkillable_tas

Re: [PATCH] oom: avoid killing init if it assume the oom killed thread's mm

2013-09-25 Thread David Rientjes
On Wed, 25 Sep 2013, Ming Liu wrote: > > We shouldn't be selecting a process where mm == init_mm in the first > > place, so this wouldn't fix the issue entirely. > > But if we add a control point for "mm == init_mm" in the first place(ie. in > oom_unkillable_task), that would forbid the processes

Re: [PATCH] oom: avoid killing init if it assume the oom killed thread's mm

2013-09-24 Thread Ming Liu
On 09/25/2013 10:34 AM, David Rientjes wrote: On Mon, 23 Sep 2013, Ming Liu wrote: After selecting a task to kill, the oom killer iterates all processes and kills all other user threads that share the same mm_struct in different thread groups. But in some extreme cases, the selected task happe

Re: [PATCH] oom: avoid killing init if it assume the oom killed thread's mm

2013-09-24 Thread David Rientjes
On Mon, 23 Sep 2013, Ming Liu wrote: > After selecting a task to kill, the oom killer iterates all processes and > kills all other user threads that share the same mm_struct in different > thread groups. > > But in some extreme cases, the selected task happens to be a vfork child > of init proces

[PATCH] oom: avoid killing init if it assume the oom killed thread's mm

2013-09-23 Thread Ming Liu
After selecting a task to kill, the oom killer iterates all processes and kills all other user threads that share the same mm_struct in different thread groups. But in some extreme cases, the selected task happens to be a vfork child of init process sharing the same mm_struct with it, which causes