Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 12 Apr 2005 15:06:41 +0100
From:      Nick Barnes <Nick.Barnes@pobox.com>
To:        Vivek Khera <vivek@khera.org>
Cc:        freebsd-stable@freebsd.org
Subject:   Re: kernel killing processes when out of swap 
Message-ID:  <51434.1113314801@thrush.ravenbrook.com>
In-Reply-To: <0c9a92c2eb7461f25aa924322407f950@khera.org>  from Vivek Khera <vivek@khera.org>  of "Tue, 12 Apr 2005 09:52:59 -0400"

next in thread | previous in thread | raw e-mail | index | archive | help
At 2005-04-12 13:52:59+0000, Vivek Khera writes:

> > of swap? Which leads to the question would it not be more sensible to
> > kill off the largest process first as its more than likely that it is 
> > responsible
> > for the problem?
> >
> 
> so when this largest process is your production database server for 
> your e-commerce site, what will you change your recommendation to be?
> 
> basically, there is no "right" choice of process to kill.  a machine 
> that is out of resources is just a bad situation, and the right thing 
> is to try to avoid getting there with careful monitoring and planning.

The right choice is for mmap() to return ENOMEM, and then for malloc()
to return NULL, but almost no operating systems make this choice any
more.

Nick B



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