Re: Help! Apache 2.2 gives segmentation fault errors with PHP.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

Yesterday I had trouble when configuring Apache 2.2 with PHP 4.4.2, which caused Apache to crash (segmentation fault) when calling various PHP functions. Just before heading home I encountered the source of the issue, as well as the solution.

The hint to the answer resided in the /var/log/httpd-error.log file:

> And the /var/log/httpd-error.log file mentions the following (at the end):
> [...]
> PHP Warning:  Function registration failed - duplicate name - bzopen in
> Unknown on line 0
> PHP Warning:  Function registration failed - duplicate name - bzread in
> Unknown on line 0
> [...]
> ..............many more similar messages...............

This obviously hinted at these functions (i.e php4-extensions) somehow being doubly present and called.

Issuing a 'pkg_info | grep php' command was most illustrative, and showed over a screen full of output like this:

mod_php4-4.4.2_1,1  PHP Apache Module
php4-bcmath-4.4.2_1 The bcmath shared extension for php
php4-bz2-4.3.10     The bz2 shared extension for php
php4-bz2-4.4.2_1    The bz2 shared extension for php
php4-calendar-4.4.2_1 The calendar shared extension for php
php4-crack-4.4.2_1  The crack shared extension for php
php4-ctype-4.4.2_1  The ctype shared extension for php
php4-dio-4.4.2_1    The dio shared extension for php
php4-domxml-4.4.2_1 The domxml shared extension for php
php4-exif-4.4.2_1   The exif shared extension for php
php4-extensions-1.0 A "meta-port" to install PHP extensions
php4-gd-4.3.10      The gd shared extension for php
php4-gd-4.4.2_1     The gd shared extension for php
[...more lines where those came from...]

Tadaaaah!! there we go: indeed several extensions were somehow not removed properly when a previous upgrade to PHP 4.4.2 (from v4.3.10) was performed!

As to the reason for this, go figure, I always install from the ports by doing a 'make' 'make deinstall' 'make reinstall' sequence when upgrading...

Anyway, manually removing all PHP extensions using the various individual 'make deinstall' sequences (and bluntly pkg_delete for pear). Then, I cleanly redid the process for installing mod_php4 and the extensions, and now all is working fine!

Tnx for thinking along with me, and beware of this potential pitfall! :)

Cheers!
Olafo

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux