Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 2 Jun 2018 21:26:39 -0500 (CDT)
From:      "Valeri Galtsev" <galtsev@kicp.uchicago.edu>
To:        "RW" <rwmaillists@googlemail.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Is it normal that a user can take down the whole system by  using too much memory?
Message-ID:  <52781.108.68.163.235.1527992799.squirrel@cosmo.uchicago.edu>
In-Reply-To: <20180603004634.5865434d@gumby.homeunix.com>
References:  <1527977770.2651378.1394286400.0806CC5C@webmail.messagingengine.com> <01EE7EEA-03AC-4D71-BA08-B0CEA97EE720@thehowies.com> <1527981931.2670335.1394316280.09410FC9@webmail.messagingengine.com> <20180603004634.5865434d@gumby.homeunix.com>

next in thread | previous in thread | raw e-mail | index | archive | help

On Sat, June 2, 2018 6:46 pm, RW via freebsd-questions wrote:
> On Sat, 02 Jun 2018 19:25:31 -0400
> Brennan Vincent wrote:
>
>
>> I'm also curious, however, to learn more from an OS design
>> perspective. Why isn't it possible for the kernel to realize it
>> should kill `eatmem` rather than make the system unusable?
>
> I did something similar a few years ago, and the process was reliably
> killed.

Indeed you sound like saying, no, regular user putting the system on the
knees by just grabbing all memory is not normal. And I would second that.
I didn't do such test to FreeBSD (how thoughtless of me), but in the past
when I was mostly Linux guy, I did that to Linux systems routinely. RedHat
(and clones) as well as unpatched by anybody latest Linux kernel built
with all default configuration were always consistently invoking OOM (Out
Of Memory)  killer, which consistently was killing the offender, even in
presence of other processes possessing large junks of memory. Once I tried
SUSE (ver 7), and its stock kernel was crashed by this little memory leak
program I used for tests. I gave up on SUSE once and forever then.

So, killing the offender is a must IMHO. However, on some systems before
the offender gets killed the system may be on its knees for some time, and
for how long mostly will depend on how sysadmin set it up. Say, if there
is very large swap space, then until it is exhausted, the situation is not
considered critical to kill some process. And the machine that is using
swap a lot will effectively be thousands of times slower.

Valeri


>
> _______________________________________________
> freebsd-questions@freebsd.org mailing list
> https://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "freebsd-questions-unsubscribe@freebsd.org"
>


++++++++++++++++++++++++++++++++++++++++
Valeri Galtsev
Sr System Administrator
Department of Astronomy and Astrophysics
Kavli Institute for Cosmological Physics
University of Chicago
Phone: 773-702-4247
++++++++++++++++++++++++++++++++++++++++



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?52781.108.68.163.235.1527992799.squirrel>