Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 29 Apr 1998 13:44:30 -0400 (EDT)
From:      "David E. Cross" <dec@phoenix.its.rpi.edu>
To:        David Wolfskill <dhw@whistle.com>
Cc:        freebsd-hackers@FreeBSD.ORG
Subject:   Re: SIGDANGER
Message-ID:  <Pine.BSF.3.96.980429133853.2950D-100000@phoenix.its.rpi.edu>
In-Reply-To: <199804291637.JAA09220@pau-amma.whistle.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 29 Apr 1998, David Wolfskill wrote:

> >Date: Wed, 29 Apr 1998 09:16:51 -0400 (EDT)
> >From: "David E. Cross" <dec@phoenix.its.rpi.edu>
> 
> >the Kernel would then treat processes as follows:
> >1) Processes that did not have SIGDANGER handled would be the first to be
> >killed (just sent a SIGKILL).
> 
> I'm probably exposing my ignorance here, but it seems to me that SIGKILL
> really ought to be a last resort....  Since it can't be caught, it
> provides absolutely no way for such a process to do any cleanup at all.
When you get that critically low on memory you really don't have the
luxury of warning a process that it is about to die, and waiting for the
process to clean up, the 'warning' of processes should occur at some
threshold of available memory, when you get to the point of *needing* to
kill procs, then you should just kill them and be done with it ;)

> 
> On a related note, I'm wondering if memory allocation is the only
> resource to which this sort of strategy ought to apply:  I don't think
> of any that are as critical, just now, but I'm not entirely convinced
> that the list (of resources) should contain only a single entry....

I think that is why AIX refers to it as SIGDANGER, it could be used for
other cases where resources are critically low... file descriptors
perhaps (just rambling, don't flame me).


Seeing how this has caused quite a stir, why don't I take a crack at
implimenting it (that is a subtle hint for the kernel programs to:
  a: Do it before I do
  b: run screaming into the night, ban me from -hackers and disavow all
     knowledge of FreeBSD
  c: point me at some source.
I would prefer c)

--
David Cross


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.BSF.3.96.980429133853.2950D-100000>