Apache seg faults with pfpro and PHP 4.0.2
| From: | Chris Monson | Date: | Mon, 18 Sep 2000 23:52:47 +0000 |
| Subject: | Apache seg faults with pfpro and PHP 4.0.2 | ||
| Groups: | php.install | ||
| Request: | Send a blank email to php-install+get-2456@lists.php.net to get a copy of this message | ||
The subject basically says it all. I got down the SDK from Verisign and have installed it as indicated in the manual, namely:
cp libpfpro.so /usr/local/lib
cp pfpro.h /usr/local/include
# /usr/local/lib is in ld.so.conf already
ldconfig
Then I ran this configuration script for PHP 4.0.2:
#!/bin/bash
./configure \
--enable-safe-mode \
--enable-ftp \
--with-mysql=/usr/local/mysql \
--with-pfpro \
--enable-memory-limit \
--with-apxs=/usr/local/apache/sbin/apxs
The configure script runs as expected, and PHP compiles and installs without errors.
Now I try to restart apache...
/usr/local/apache/sbin/apachectl restart
...and it dies silently, leaving no entry in its log files (the server logs OR the virtual server logs) and it dumps core in /.
If I try to do a startssl, I get the same thing.
I saw some seemingly unrelated postings here that showed setting LD_PRELOAD to fix a problem with Oracle, and I tried that since my debug session with Apache seemed to indicate that there was a problem with pthreads:
LD_PRELOAD=/usr/lib/libpthread.so /usr/local/apache/sbin/apachectl startssl
That works. Sort of. In fact, on two machines with EXACTLY the same configuration, it works differently, and on the SAME machine, it works about half of the time.
On one machine, for example, startssl fails outright, giving no reasons in any log files, but saying that "httpd could not be started". A regular start command, however, works just fine with no errors or warnings.
Strangely enough, the CGI binary compiled with exactly the same options works just fine. It runs without errors and gives me access to all of the Verisign Payflow Pro functionality. It works, in short, like a dream.
However, if I leave --with-pfpro out of the configuration for mod_php (the apxs setup) then mod_php works fine, but (of course) without the needed Verisign functionality.
Since I have seen various scattered posts here about Apache seg faulting with PHP 4.0.2 for sundry reasons, I am guessing that there is a bug in PHP 4.0.2 that keeps it from working correctly. Someone, for example, mentioned that --enable-trans-sid was causing the same problem, and that when it was turned off, Apache stopped seg faulting. I have opened up the httpd process in a debugger and it fails in the same place every time. If anyone wants a stack trace, I can probably oblige you.
Anyway, if anyone has seen similar behavior, please let me know. If something like this has been fixed in the CVS version, also let me know. This is intensely frustrating.
Chris