All of lore.kernel.org
 help / color / mirror / Atom feed
From: Izik Eidus <ieidus@redhat.com>
To: Hugh Dickins <hugh.dickins@tiscali.co.uk>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Andrea Arcangeli <aarcange@redhat.com>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH 2/3] ksm: unmerge is an origin of OOMs
Date: Mon, 07 Sep 2009 19:42:17 +0300	[thread overview]
Message-ID: <4AA537E9.8030800@redhat.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0909052222430.7387@sister.anvils>

Hugh Dickins wrote:
> Just as the swapoff system call allocates many pages of RAM to various
> processes, perhaps triggering OOM, so "echo 2 >/sys/kernel/mm/ksm/run"
> (unmerge) is liable to allocate many pages of RAM to various processes,
> perhaps triggering OOM; and each is normally run from a modest admin
> process (swapoff or shell), easily repeated until it succeeds.
>
> So treat unmerge_and_remove_all_rmap_items() in the same way that we
> treat try_to_unuse(): generalize PF_SWAPOFF to PF_OOM_ORIGIN, and
> bracket both with that, to ask the OOM killer to kill them first,
> to prevent them from spawning more and more OOM kills.
>
> Signed-off-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
> ---
>   

Acked-by: Izik Eidus <ieidus@redhat.com>

WARNING: multiple messages have this Message-ID (diff)
From: Izik Eidus <ieidus@redhat.com>
To: Hugh Dickins <hugh.dickins@tiscali.co.uk>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	Andrea Arcangeli <aarcange@redhat.com>,
	linux-kernel@vger.kernel.org, linux-mm@kvack.org
Subject: Re: [PATCH 2/3] ksm: unmerge is an origin of OOMs
Date: Mon, 07 Sep 2009 19:42:17 +0300	[thread overview]
Message-ID: <4AA537E9.8030800@redhat.com> (raw)
In-Reply-To: <Pine.LNX.4.64.0909052222430.7387@sister.anvils>

Hugh Dickins wrote:
> Just as the swapoff system call allocates many pages of RAM to various
> processes, perhaps triggering OOM, so "echo 2 >/sys/kernel/mm/ksm/run"
> (unmerge) is liable to allocate many pages of RAM to various processes,
> perhaps triggering OOM; and each is normally run from a modest admin
> process (swapoff or shell), easily repeated until it succeeds.
>
> So treat unmerge_and_remove_all_rmap_items() in the same way that we
> treat try_to_unuse(): generalize PF_SWAPOFF to PF_OOM_ORIGIN, and
> bracket both with that, to ask the OOM killer to kill them first,
> to prevent them from spawning more and more OOM kills.
>
> Signed-off-by: Hugh Dickins <hugh.dickins@tiscali.co.uk>
> ---
>   

Acked-by: Izik Eidus <ieidus@redhat.com>

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

  reply	other threads:[~2009-09-07 16:34 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-05 21:22 [PATCH 1/3] ksm: clean up obsolete references Hugh Dickins
2009-09-05 21:22 ` Hugh Dickins
2009-09-05 21:25 ` [PATCH 2/3] ksm: unmerge is an origin of OOMs Hugh Dickins
2009-09-05 21:25   ` Hugh Dickins
2009-09-07 16:42   ` Izik Eidus [this message]
2009-09-07 16:42     ` Izik Eidus
2009-09-07 16:42   ` Izik Eidus
2009-09-05 21:26 ` [PATCH 3/3] ksm: mremap use err from ksm_madvise Hugh Dickins
2009-09-05 21:26   ` Hugh Dickins
2009-09-07 16:54   ` Izik Eidus
2009-09-07 16:54     ` Izik Eidus
2009-09-07 16:36 ` [PATCH 1/3] ksm: clean up obsolete references Izik Eidus
2009-09-07 16:36   ` Izik Eidus

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=4AA537E9.8030800@redhat.com \
    --to=ieidus@redhat.com \
    --cc=aarcange@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=hugh.dickins@tiscali.co.uk \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.