From: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
To: Minchan Kim <minchan.kim@gmail.com>
Cc: "linux-mm@kvack.org" <linux-mm@kvack.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
"rientjes@google.com" <rientjes@google.com>,
Andrey Vagin <avagin@openvz.org>,
KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>,
Hugh Dickins <hughd@google.com>,
Johannes Weiner <hannes@cmpxchg.org>,
Rik van Riel <riel@redhat.com>
Subject: Re: [PATCH 0/4] forkbomb killer
Date: Fri, 25 Mar 2011 09:04:11 +0900 [thread overview]
Message-ID: <20110325090411.56c5e5b2.kamezawa.hiroyu@jp.fujitsu.com> (raw)
In-Reply-To: <20110324105222.GA2625@barrios-desktop>
On Thu, 24 Mar 2011 19:52:22 +0900
Minchan Kim <minchan.kim@gmail.com> wrote:
> Hi Kame,
>
Hi.
> On Thu, Mar 24, 2011 at 06:22:40PM +0900, KAMEZAWA Hiroyuki wrote:
> >
> > I tested with several forkbomb cases and this patch seems work fine.
> >
> > Maybe some more 'heuristics' can be added....but I think this simple
> > one works enough. Any comments are welcome.
>
> Sorry for the late review. Recently I dont' have enough time to review patches.
> Even I didn't start to review this series but I want to review this series.
> It's one of my interest features. :)
>
> But before digging in code, I would like to make a consensus to others to
> need this feature. Let's Cc others.
>
> What I think is that about "cost(frequent case) VS effectiveness(very rare case)"
> as you expected. :)
>
> 1. At least, I don't meet any fork-bomb case for a few years. My primary linux usage
> is just desktop and developement enviroment, NOT server. Only thing I have seen is
> just ltp or intentional fork-bomb test like hackbench. AFAIR, ltp case was fixed
> a few years ago. Although it happens suddenly, reboot in desktop isn't critical
> as much as server's one.
>
Personally, I've met forkbombs several times by typing "make -j" .....by mistake.
I met a forkbomb on production system by buggy script, once.
That happens because
1. $PATH includes "."
2. a programmer write a scirpt "date" and call "date" in the script.
Maybe this is a one of typical case of forkbomb. I needed to dig crashdump to find
fragile of page-caches and see what happens...But, I guess, if appearent forkbomb
happens, the issue will not be sent to my team because we're 2nd line support team
and 1st line should block it ;).
So, I'm not sure how many forkbombs happens in server world in a year. But I guess
forkbomb still happens in many development systems because there is no guard
against it.
> 2. I don't know server enviroment but I think applications executing on server
> are selected by admin carefully. So virus program like fork-bomb is unlikely in there.
> (Maybe I am wrong. You know than me).
> If some normal program becomes fork-bomb unexpectedly, it's critical.
> Admin should select application with much testing very carefully. But I don't know
> the reality. :(
>
Yes, admin selects applications carefully. There is no 100% protection by human's hand.
> Of course, although he did such efforts, he could meet OOM hang situation.
> In the case, he can't avoid rebooting. Sad. But for helping him, should we pay cost
> in normal situation?(Again said, I didn't start looking at your code so
> I can't expect the cost but at least it's more than as-is).
> It could help developing many virus program and to make careless admins.
>
> It's just my private opinion.
> I don't have enough experience so I hope listen other's opinions
> about generic fork-bomb killer, not memcg.
>
> I don't intend to ignore your effort but justify your and my effort rightly.
>
To me, the fact "the system _can_ be broken by a normal user program" is the most
terrible thing. With Andrey's case or make -j, a user doesn't need to be an admin.
I believe it's worth to pay costs.
(and I made this function configurable and can be turned off by sysfs.)
And while testing Andrey's case, I used KVM finaly becasue cost of rebooting was small.
My development server is on other building and I need to push server's button
to reboot it when forkbomb happens ;)
In some environement, cost of rebooting is not small even if it's a development system.
Thanks,
-Kame
--
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/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
next prev parent reply other threads:[~2011-03-25 0:10 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-24 9:22 KAMEZAWA Hiroyuki
2011-03-24 9:25 ` [PATCH 1/5] forkbomb killer config and documentation KAMEZAWA Hiroyuki
2011-03-24 9:26 ` [PATCH 2/5] forkbomb: mm tracking subsystem KAMEZAWA Hiroyuki
2011-03-24 9:28 ` [PATCH 3/5] forkbomb : mm histroy scanning and locks KAMEZAWA Hiroyuki
2011-03-24 9:29 ` [PATCH 4/5] forkbomb : periodic flushing mm history information KAMEZAWA Hiroyuki
2011-03-24 9:30 ` [PATCH 5/5] forkbomb killer KAMEZAWA Hiroyuki
2011-03-24 10:52 ` [PATCH 0/4] " Minchan Kim
2011-03-25 0:04 ` KAMEZAWA Hiroyuki [this message]
2011-03-25 2:38 ` Minchan Kim
2011-03-25 2:54 ` KAMEZAWA Hiroyuki
2011-03-25 4:05 ` Minchan Kim
2011-03-25 13:45 ` Colin Walters
2011-03-26 0:04 ` Hiroyuki Kamezawa
2011-03-26 2:34 ` Michel Lespinasse
2011-03-26 8:48 ` Hiroyuki Kamezawa
2011-03-28 16:21 ` Minchan Kim
2011-03-28 23:50 ` KAMEZAWA Hiroyuki
2011-03-29 0:24 ` Minchan Kim
2011-03-29 0:32 ` KAMEZAWA Hiroyuki
2011-03-29 1:12 ` Minchan Kim
2011-03-29 1:12 ` KAMEZAWA Hiroyuki
2011-03-29 1:27 ` Minchan Kim
2011-04-14 0:20 ` KOSAKI Motohiro
2011-04-14 0:35 ` KAMEZAWA Hiroyuki
2011-04-14 0:57 ` Minchan Kim
2011-04-14 18:13 ` David Rientjes
2011-03-28 23:46 ` Michel Lespinasse
2011-03-29 0:25 ` KAMEZAWA Hiroyuki
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=20110325090411.56c5e5b2.kamezawa.hiroyu@jp.fujitsu.com \
--to=kamezawa.hiroyu@jp.fujitsu.com \
--cc=avagin@openvz.org \
--cc=hannes@cmpxchg.org \
--cc=hughd@google.com \
--cc=kosaki.motohiro@jp.fujitsu.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=minchan.kim@gmail.com \
--cc=riel@redhat.com \
--cc=rientjes@google.com \
/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