This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH 4/4] Mark nscd service as forking in systemd service file (#16639)


On Thu, Feb 27, 2014 at 12:25:09AM +0530, Siddhesh Poyarekar wrote:
> On Wed, Feb 26, 2014 at 01:39:50PM -0500, Rich Felker wrote:
> > On Wed, Feb 26, 2014 at 10:52:42PM +0530, Siddhesh Poyarekar wrote:
> > > Hi,
> > > 
> > > Currently the nscd service is installed in systemd as a simple
> > > service, which means that it is able to handle its own errors and does
> > > not quit.  Since nscd does not fit that description, i.e. it can exit
> > > on errors like, say, failing to parse nscd.conf, it should be declared
> > > as forking instead.  Tested on Fedora.
> > 
> > I don't think this is the right meaning of "forking". Forking just
> > means the daemon backgrounds itself so that its parent cannot manage
> > its lifetime with a pid. If this behavior cannot currently be fixed in
> > nscd via a command line option, it should be fixed at the source
> > level. Forking is always wrong for daemons.
> 
> That's the meaning I got from a systemd maintainer, see:
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=1048123#c2
> 
> Fixing nscd to be a well-behaved daemon that recovers from its errors
> is a fairly complicated task, given the number of errors it would need
> to recover from.  I think it is a good compromise to start with and
> maybe keep a bug open to track nscd's error recovery.

OK, I think systemd is just even more broken than I gave it credit
for. My understanding of "simple" was that systemd would properly
manage the lifetime of the process using its pid, including restarting
it on exit if desired. The way it's behaving is contrary to any proper
service supervision system (like runit, etc.) which would want to be
the immediate parent.

Rich


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]