From: Richard Purdie <rpurdie@rpsys.net>
To: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: LKML <linux-kernel@vger.kernel.org>
Subject: Re: Linux machines dieing in swap storms
Date: Thu, 25 Oct 2007 19:28:20 +0100 [thread overview]
Message-ID: <1193336900.5697.14.camel@localhost.localdomain> (raw)
In-Reply-To: <20071025171311.42844d17@the-village.bc.nu>
On Thu, 2007-10-25 at 17:13 +0100, Alan Cox wrote:
> > I'm seriously tempted to add a "kill the process using the most memory"
> > key combination into SysRq which might let me save the desktop but won't
> > help with my remote server. I could also just disable swap I guess.
>
> For specific applications you can set resource limits, you can also set
> OOM priorities in current kernels to pick who dies.
I couldn't seem to find much documentation on this. For the archive and
to confirm we're talking about the same thing, you mean:
echo 10 > /proc/PID/oom_adj
(and ulimit/setrlimit for the resource limits) ?
This assumes I know in advance which processes are likely to go mad
which isn't ideal although it could solve my immediate problem.
> Finally you can disable overcommit and go for a rigid "no overcommit"
> policy where the system will fail any memory allocation which might lead
> to out of memory situations later.
Its certainly another option but other processes then suffer because
certain applications have bugs in them?
Thanks,
Richard
next prev parent reply other threads:[~2007-10-25 18:28 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-25 15:20 Linux machines dieing in swap storms Richard Purdie
2007-10-25 16:13 ` Alan Cox
2007-10-25 18:28 ` Richard Purdie [this message]
2007-10-25 18:34 ` Rik van Riel
2007-10-25 19:55 ` Simon Arlott
2007-10-26 2:08 ` David Newall
2007-10-26 15:14 ` Lenar Lõhmus
[not found] <9icP2-2hb-17@gated-at.bofh.it>
[not found] ` <9ifML-6Xs-25@gated-at.bofh.it>
2007-10-26 3:56 ` Bodo Eggert
2007-10-26 4:03 ` Rik van Riel
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=1193336900.5697.14.camel@localhost.localdomain \
--to=rpurdie@rpsys.net \
--cc=alan@lxorguk.ukuu.org.uk \
--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