c

Reload httpd via PHP (sorta)

The problem:
Apache forked processes (PHP, CGI, etc) runs as a different user (usually www or some variant) which doesn't have permission to restart Apache. To further compound the problem, PHP doesn't allow you to sudo to a user that does have the privileges (they call this a "security feature"). Also, if it did have the privileges, it cannot reload httpd directly because that's it's parent process.

Syndicate content