You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Maxim Nechaev <ne...@technodesign.ru> on 2005/03/14 00:48:17 UTC
Restarting apache from child?
I need to restart or graceful restart apache server from one of his
child. It is possible? If yes, how to do this more correctly?
Thanks
Maxim Nechaev
Re: Restarting apache from child
Posted by Scott Gifford <sg...@suspectclass.com>.
Maxim Nechaev <ne...@technodesign.ru> writes:
> Scott, thanks for response!
>
> SG> The main Apache process runs as root, and each Apache child process
> SG> runs as a less-privileged user, and so would not have permission to
> SG> signal the main process to tell it to reload.
>
> Ok i understand difficulty.
>
> Maybe exists a way to force apache reread or change it's current
> configuration with effecting on all other child's?
Not as far as I know.
----ScottG.
Re[2]: Restarting apache from child
Posted by Maxim Nechaev <ne...@technodesign.ru>.
Scott, thanks for response!
SG> The main Apache process runs as root, and each Apache child process
SG> runs as a less-privileged user, and so would not have permission to
SG> signal the main process to tell it to reload.
Ok i understand difficulty.
Maybe exists a way to force apache reread or change it's current
configuration with effecting on all other child's?
Maxim Nechaev
Re: Restarting apache from child?
Posted by Scott Gifford <sg...@suspectclass.com>.
Maxim Nechaev <ne...@technodesign.ru> writes:
> I need to restart or graceful restart apache server from one of his
> child. It is possible? If yes, how to do this more correctly?
The main Apache process runs as root, and each Apache child process
runs as a less-privileged user, and so would not have permission to
signal the main process to tell it to reload.
You could use a conventional perl script (ie not mod_perl) which is
setuid root (though you'd need to be extraordinarily careful), or have
an external daemon running as root which accepted restart requests on
a UNIX socket, then have your script send these requests.
----ScottG.