Hey everyone, I have an issue I am trying to resolve. I am getting Segmentation fault (11) in my httpd-error.log at random times throughout the day. I have tried several things including commenting out some extensions and reinstalling all extensions, and now I have recompiled php with debug enabled - still getting the faults.
I *think* it could be a problem with how I installed PHP. I initially installed the /php52/ port, then deinstalled it and installed /php5/. I ran into problems, as the new PHP install seemed to still see some of the old extensions from the php52 install. So I did a deinstall of all php52 ports then:
Not sure if that did anything - as that is when I started noticing the Segmentation faults in my logs. Not knowing what to do, I hired a server management company to help. They reinstalled php. This seemed to stop the segfault.
Now later that week I was doing a:
and it upgraded php from ports. I did a:
Which reported 5.2.17 (not 5.3.4 that was installed in ports). A phpinfo() reported 5.3.4. And my segfault had returned! This is when I realized the server management company installed PHP from source and I had 2 installations of php - one in each of the following directories:
5.2:
/usr/bin/php
and 5.3:
/usr/local/bin/php
I asked them to fix it so only the ports versions is installed. They said they did, and I was still getting segmentation faults, so I recompiled php and extensions from ports with debug enabled. This is now what I get:
I am thinking my segfaults could be resulting from cross-mixed dependencies from the installations, but I am not smart enough to try and fix the problem. I was thinking a deinstall and reinstall of apache might be the next step, but is there a way to get all of my PHP to be running from the /usr/local/bin/php directory before I deinstall and reinstall apache?
Any ideas would be of great help at this point.
Code:
[Wed Jan 12 09:00:05 2011] [notice] child pid 97106 exit signal Segmentation fault (11)
# pkg_delete php52*
Not sure if that did anything - as that is when I started noticing the Segmentation faults in my logs. Not knowing what to do, I hired a server management company to help. They reinstalled php. This seemed to stop the segfault.
Now later that week I was doing a:
# portupgrade -a
and it upgraded php from ports. I did a:
# php -v
Which reported 5.2.17 (not 5.3.4 that was installed in ports). A phpinfo() reported 5.3.4. And my segfault had returned! This is when I realized the server management company installed PHP from source and I had 2 installations of php - one in each of the following directories:
5.2:
/usr/bin/php
and 5.3:
/usr/local/bin/php
I asked them to fix it so only the ports versions is installed. They said they did, and I was still getting segmentation faults, so I recompiled php and extensions from ports with debug enabled. This is now what I get:
Code:
control# php -v
PHP 5.3.4 (cli) (built: Dec 31 2010 03:40:10)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
control# which php
/usr/bin/php
control# /usr/local/bin/php -v
PHP 5.3.4 (cli) (built: Jan 8 2011 06:51:54) (DEBUG)
Copyright (c) 1997-2010 The PHP Group
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
I am thinking my segfaults could be resulting from cross-mixed dependencies from the installations, but I am not smart enough to try and fix the problem. I was thinking a deinstall and reinstall of apache might be the next step, but is there a way to get all of my PHP to be running from the /usr/local/bin/php directory before I deinstall and reinstall apache?
Any ideas would be of great help at this point.