httpd-modules-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe Lewis <>
Subject Re: PHP Extension Deinitializing on Startup
Date Fri, 20 Apr 2007 17:08:15 GMT
Michael B Allen wrote:
> Hi Saju,
> Actually I'm not sure this is my problem. I have tested my PHP extension
> on numerous platforms and I have only ever seen the PHP extension
> initialization / deinitialization routines run once for each restart.
> Is the "load -> unload -> load" behavior you describe something new that
> Apache just started doing?

Apache has been doing that for eons. But apache does it to the apache 
extensions, while PHP would do it to the PHP extensions. I really expect 
that you should be working with the PHP lists rather than here from the 
original posting. (See for one that 
might fit your needs).

Saju is absolutely correct - when a module is loaded by apache, a hook 
called post_config() is called twice (for checking the config file first 
that the syntax is okay, and then for the actual configuration), but I'm 
not sure if the .so is free()d from memory during that process. I always 
thought that it did not actually reload the .so (correct me if I am wrong).

Forcing an extension to "deinitialize" in PHP because of an issue in 
Apache would cause every extension in PHP to "deinitialize", not just 
one of them. I expect the issue to be in the php extension itself (or 
php, but that is unlikely).

Joseph Lewis <>
"Divide the fire, and you will sooner put it out." - Publius Syrus

View raw message