Date: Mon, 27 Nov 2006 21:48:46 -0800 From: James Long <list@museum.rain.com> To: freebsd-questions@freebsd.org Subject: Latest Apache13 with PHP5 crashes when PostgreSQL support is added Message-ID: <20061128054846.GA59193@ns.umpquanet.com>
next in thread | raw e-mail | index | archive | help
I have been running Apache (apache+mod_ssl-1.3.34+2.8.25_1) for some time with php5 and extensions to support PostgreSQL 8.0.9. After upgrading to PostgreSQL 8.1.15 I find that Apache crashes if the php5 PostgreSQL extension is installed. I have updated Apache to apache+mod_ssl-1.3.37+2.8.28 with no improvement. I have pkg_deleted and re-installed the php5 port with no improvement. Starting Apache via the package's rc.d script results in a short- lived httpd process that doesn't live long enough to log anything before it exits. I have to run it as "httpd -DSSL -X" to see any debugging info at all, which is simply "Segmentation fault: 11 (core dumped)" and an httpd.core file. I am compiling php5-extensions with only pgsql support. With this php5-extensions meta-port installed, Apache will not start with PHP support. If I either comment out Apache's PHP support, or de-install the php5-pgsql-5.2.0 package, Apache will start. That suggests to me that I have narrowed down my list of suspects. How can I get the latest Apache 1.3.X and PHP5 to support the latest PostgreSQL? Thank you for your time. Jim ns : 21:05:31 /usr/ports/lang/php5-extensions# make showconfig | grep -vw off ===> The following configuration options are available for php5-extensions-1.0: PGSQL=on "PostgreSQL database support" ===> Use 'make config' to modify these settings If I install php5-pgsql-5.2.0 and run "/usr/local/etc/rc.d/apache start" I get no error message on the console, and a single httpd process lives briefly then exits. Manually running httpd -DSSL -X shows a segmentation fault 11. Below, findps is a shell shortcut that is basically ps -axl | grep "$@" which is a quick and dirty way to see whether a process is running. ns : 21:26:27 /usr/local/etc/apache# findps http ns : 21:26:30 /usr/local/etc/apache# pkg_info | grep php php5-5.2.0 PHP Scripting Language (Apache Module and CLI) php5-extensions-1.0 A "meta-port" to install PHP extensions php5-pgsql-5.2.0 The pgsql shared extension for php ns : 21:26:36 /usr/local/etc/apache# pkg_info | grep ^apache apache+mod_ssl-1.3.37+2.8.28 The Apache 1.3 webserver with SSL/TLS functionality ns : 21:26:44 /usr/local/etc/apache# httpd -DSSL -X Processing config directory: /usr/local/etc/apache/virtual-hosts/*.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example1.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example2.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example3.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example4.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example5.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example6.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example7.conf (... etc.) Processing config file: /usr/local/etc/apache/virtual-hosts/org.exampleN.conf Segmentation fault: 11 (core dumped) ns : 21:26:59 /usr/local/etc/apache# ls -l *core -rw------- 1 root wheel 27332608 Nov 27 21:26 httpd.core ns : 21:27:08 /usr/local/etc/apache# If I de-install the PHP support for Postgres, apache will start: ns : 21:30:07 /usr/local/etc/apache# pkg_delete php5-pgsql-5.2.0 pkg_delete: package 'php5-pgsql-5.2.0' is required by these other packages and may not be deinstalled: php5-extensions-1.0 ns : 21:30:12 /usr/local/etc/apache# pkg_delete php5-extensions-1.0 ns : 21:30:26 /usr/local/etc/apache# pkg_delete php5-pgsql-5.2.0 ns : 21:30:28 /usr/local/etc/apache# /usr/local/etc/rc.d/apache.sh start Starting apache. Processing config directory: /usr/local/etc/apache/virtual-hosts/*.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example1.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example2.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example3.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example4.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example5.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example6.conf Processing config file: /usr/local/etc/apache/virtual-hosts/com.example7.conf (... etc.) Processing config file: /usr/local/etc/apache/virtual-hosts/org.exampleN.conf ns : 21:30:58 /usr/local/etc/apache# findps http root 56898 41.4 3.1 37024 32404 ?? Ss 9:30PM 0:02.72 /usr/local/sbin/httpd -DSSL www 57036 0.0 3.1 37024 32420 ?? S 9:31PM 0:00.01 /usr/local/sbin/httpd -DSSL www 57037 0.0 3.1 37024 32420 ?? S 9:31PM 0:00.00 /usr/local/sbin/httpd -DSSL www 57038 0.0 3.1 37024 32420 ?? S 9:31PM 0:00.01 /usr/local/sbin/httpd -DSSL www 57039 0.0 3.1 37024 32420 ?? S 9:31PM 0:00.01 /usr/local/sbin/httpd -DSSL www 57040 0.0 3.1 37024 32420 ?? S 9:31PM 0:00.00 /usr/local/sbin/httpd -DSSL ns : 21:31:03 /usr/local/etc/apache#
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20061128054846.GA59193>