Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 31 Jan 2016 15:32:57 +0000
From:      Jonathan de Boyne Pollard <J.deBoynePollard-newsgroups@NTLWorld.com>
To:        FreeBSD Hackers <freebsd-hackers@freebsd.org>
Subject:   Re: syslogd(8) with OOM Killer protection
Message-ID:  <56AE2929.304@NTLWorld.com>
In-Reply-To: <56AA047D.8070807@digiware.nl>
References:  <56AA047D.8070807@digiware.nl>

next in thread | previous in thread | raw e-mail | index | archive | help
Eugene Grosbein:
 > protection of single process is meaningless because it forks to 
become daemon and that ceases protection;

This premise is erroneous, and the conclusion that you've based upon it 
is erroneous too.  Daemons that run under service managers do not need 
to fork "to become [a] daemon".  Indeed, they *already are* daemons 
right from the start.  As Jan Brankamp said elsewhere:

 > I would prefer to implement the a flag keeping cron (and all other 
base system daemons) from double-forking and run it under a process 
supervisor like daemontools.

And as I have pointed out, this is already the case over a wide range of 
daemon softwares nowadays.  Thus the use of "protect" is feasible, since 
proper service-manager-managed daemons end up as the same process as the 
process that ran "protect".  Indeed, chain-loading utilities like 
"protect" are the basics of the daemontools way of doing things.  There 
is a broad range of tools whose purpose is to affect process state in 
one particular aspect and then chain to another program using what's 
left in the argument vector.

Eugene Grosbein:
 > Perhaps, we could have kernel facility [...]

There's no need for new kernel facilities here if one uses a service 
manager and throws away the wrongheaded idea that daemons need to 
*become* daemons under their own steam.  (-:



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