[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
RE: Seamless restarts
Howard Chu writes:
> So what operations can cause a deadlock on Solaris and OSF?
Not sure, but I think we are safe if close() is safe.
However:
> I'm sure we already agreed on this - it would be safe to unconditionally
> fork() a surrogate parent at slapd startup.
Hold on - we can just as well fork() the "restarted" slapd process early.
It can sit and wait for the parent slapd to die or to decide to do a
seamless restart. If the latter, it starts up and takes over.
If the child is forked before chdir/chroot, we won't have any problems
with the slapd.args file and exec path having a different name either.
For that matter, we might not even need to exec() slapd again, but
personally I'd prefer to do that anyway, in case the restart is done
because the slapd executable has been replaced with a newer version.
> The question then is, will the C library spawn any threads behind our
> back, while we're resolving DNS names and creating listener sockets?
Not before we have started threading, surely?
--
Hallvard