On Fri, Dec 28, 2001 at 05:46:58PM -0800, Aaron Bannert wrote:
> This only works because there is another fork happening before the call
> to setsid(), either an explicit fork() or samba is being started as a
> child of another process group member (like a shell script).
This must be the fork that happens in svscan (see my previous e-mail).
> Ok, now that I understand what you're trying to do a little better, I may
> be able to offer some help. The biggest pain in implementing this will
> be the need to update all of the MPMs with the new -D check. Others may
> offer a better way to do this but for now I don't see one.
Unfortunately I don't really know the Apache code that well yet, sorry :-/
Hopefully somebody else will have some good ideas...
> Hmm.. You'll have to ensure by other means that httpd is not a process
> group leader, most likely by ensuring that httpd is started by another
> process and not interactively by the shell.
Indeed. That is what (in the daemontools case - my AIX is rusty)
svscan/supervise do. See my previous e-mail.
> > Could it be that the process supervisor does something special to make
> > this work? That could explain why the Samba daemons seem to run properly
> > under the process monitor with my patch.
>
> Yes.
The svscan.c and supervise.c sources only contain a couple of fork() calls, so
that must be sufficient.
--
Jos Backus _/ _/_/_/ Santa Clara, CA
_/ _/ _/
_/ _/_/_/
_/ _/ _/ _/
[EMAIL PROTECTED] _/_/ _/_/_/ use Std::Disclaimer;