|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #15193 Module loads but does not work
Submitted: 2002-01-23 21:34 UTC Modified: 2002-06-06 21:17 UTC
Avg. Score:5.0 ± 0.0
Reproduced:1 of 1 (100.0%)
Same Version:1 (100.0%)
Same OS:0 (0.0%)
From: stephen at brightonline dot com dot au Assigned:
Status: Not a bug Package: Dynamic loading
PHP Version: 4.1.1 OS: solaris 2.8
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: stephen at brightonline dot com dot au
New email:
PHP Version: OS:


 [2002-01-23 21:34 UTC] stephen at brightonline dot com dot au
I am trying to get php 4.1.1 as a DSO to work with apache 2.0.28 running on solaris 2.8.

While I can compile both apache and php fine, when I load it as a module, php does not work, and it stops any other CGI (such as perl) working as well. Apache returns a 500 error saying the script header did not complete when I try to run a .cgi program. When I test a php script it asks to be downloaded.

apache config

./configure --prefix=/opt/apache --localstatedir=/var/run --enable-proxy --enable-proxy-http --enable-proxy-connect --enable-cgi --enable-rewrite --enable-so

I have also try with --enable-php4

php config

./configure --prefix=/opt/php --with-apxs2=/opt/apache/bin/apxs --enable-track-vars --enable-versioning

I have also tried with --enable-libgcc --with-gnu-ld

httpd.conf file is change to add the 

LoadModule php4_module        modules/
AddType application/x-httpd-php .php


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-01-24 03:01 UTC]
be careful the configuration change for Apache 2 you must use filter !

watch README from Apache2filter

you must replace :

LoadModule php4_module modules/
AddType application/x-httpd-php .php


LoadModule php4_module modules/
<Files *.php>
SetOutputFilter PHP
SetInputFilter PHP

 [2002-01-24 07:24 UTC]
Does it work now?
 [2002-01-24 20:02 UTC] stephen at brightonline dot com dot au
Thank-you for the reply.

The filters have worked for php, however loading the module still renders my cgi scripts non-operational. The error message is 

Server error!

Premature end of script headers: /var/www/webmail/index.cgi 

Error 500

If I remove the module, the script works fine. There is no additional information provided in the error logs.


 [2002-01-28 10:39 UTC] michel at construsoft dot be
After some debugging, I found that the problem is clearly in Apache. There is a segmentation violation inside procedure cleanup_pool_for_exec from file apr_pools.c. I suspect field sub_pools from struct apr_pool_t beeing corrupted. This procedure is called just before an execve in apr/threadproc/unix/proc.c.
 [2002-01-28 19:32 UTC] stephen at brightonline dot com dot au
So where to now?

Do I pass this on to the httpd team?

Down grade to httpd 1.3?

It seems other have this running already. Will installing it as a static module work?

Your help has been tremendous

 [2002-06-06 21:17 UTC]
Thank you for taking the time to report a problem with PHP.
Unfortunately your version of PHP is too old -- the problem
might already be fixed. Please download a new PHP
version from

If you are able to reproduce the bug with one of the latest
versions of PHP, please change the PHP version on this bug report
to the version you tested and change the status back to "Open".
Again, thank you for your continued support of PHP.

And of Apache2 too..

PHP Copyright © 2001-2020 The PHP Group
All rights reserved.
Last updated: Tue Sep 22 09:01:23 2020 UTC