httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Aaron Bannert <>
Subject Re: Running Apache in the foreground
Date Thu, 03 Jan 2002 16:28:14 GMT
On Wed, Jan 02, 2002 at 05:57:16PM -0500, Michael Handler wrote:
> I'd also like to voice my support for implementing Jos' requested
> functionality. NO_DETACH may have originally been intended just for
> debugging purposes, but many sites are moving to universal process
> managers like djb's daemontools, and it would be extremely useful
> to all of us if Apache's httpd provided the necessary knob to run
> under svscan & supervise out of the box.

I see no reason why this can't be implemented in apache2, and I'll
even test and commit a patch that properly implements it. :) Sorry
I can't offer much more than that. Maybe if I get some more time
later this week I can look into it, but the more surefire way to get
it in would be to provide a patch.

> Correct. The don't-fork-but-still-setsid mode is a specialized
> method meant for process controllers only, and it should be
> administrator brain damage to try and utilize it from an interactive
> shell -- much like invoking a daemon with verbose debug arguments
> and then complaining about the output. :) I think putting a note
> in the documentation to this effect should be sufficient. Also note
> that invoking this mode from shells without job control (Solaris
> /bin/sh) works fine, as they don't try and create unique process
> groups for each invoked job, AFAICT.

I would just expect the -DFOREGROUND patch to check if httpd is the
process groupleader and error out instead of calling setsid() and

> I submitted a patch regarding this issue for 1.3.22 earlier today,
> in which I also noted 2.0's issue with setsid(2) regarding this.
> (Sorry for the bad line-wrap in the PR.)

Sorry, I can't comment on 1.3, that's not my forté. Perhaps one of the
ol' timers on here have something to say about it? ;)


View raw message