[PHP-DEV] PHP 4.0 Bug #7212 Updated: Writing to HTTPD.Conf From: clivestorey <email protected>
Date: 10/18/00

ID: 7212
User Update by: clivestorey <email protected>
Status: Open
Bug Type: *General Issues
Description: Writing to HTTPD.Conf

Hi
Another day another 8 hrs gone by.

Over the last 8 hrs we have configured php-4.0.3pl1 in every conceivable way but all with the same results. The php compile programme writes the files
                               LoadModule php4_module lib/apache/libphp.so
                               AddModule mod_php4.c
to the wrong place on the httpd.conf file with the result httpd.conf will not run.

When we change these to the correct place and check the file with httpd -t we get SYNTAX OK segmentation fault (core dump). On trying to run httpd.conf in stalls.

As a way of reference to other poor souls, we spent a considerable amount of time trying to find the command apachectl. We have over many hrs left e-mails, read FAQ,s and contacted Apache (useless). It appears that if you install apache via a rpm it does not compile with the apachectl command and if you install from source you have to specify --with-apachctl. Be warned!!!

By chance on having to replace our httpd.conf file for the umpteenth time, we noticed that when the php programme wrote to the http.conf file it changed the permission on the httpd.conf file to 0644, on changing them back to 0755 we did not get the segmentation fault and httpd.conf ran with the syntax specified.

Unfortunately this is not the end of our problems as we thought.

On clicking on one or all of our .php pages (which used to work a treat under php-4.0.2) instead of getting the page we now get the SAVE AS box appear??????.

HAS ANYONE HAD THE SAME PROBLEM?.

Has it anything to do with the AddType application/x-httpd-php .php line. I only ask because you actually load the module_php4 and AddModule mod_php4.c?????????

Any help would be much appreciated to save us any more long hours in the php wilderness!!!!!

Previous Comments:
---------------------------------------------------------------------------

[2000-10-16 15:18:12] clivestorey <email protected>
Hi
After another 8 hrs we have tried a variety of new things.
We dumped php-4.0.3 and installed php-4.0.3pl1 followed the instructions for DSO install using:

./configure --with-mysql=/usr --with-apxs=/usr/sbin/apxs
make
make install
there were no faults.

In the httpd.conf file the programme had now written the AddModules mod_php4.c to the correct location but still puts LoadModule php4_module lib/apache/libphp4.so at the bottom of the file. Moving this to the correct location and running apache we get the error that it cannot find the file etc/httpd/lib/apache/libphp4.so which is correct because this does not excist. On changing the path to modules/libphp4.so and checking with httpd -t we get SYNTAX OK segmentation fault (core dump).

This problem
is shown in bug 5701/4850

We have also encountered all of the syptoms in bug 6803/6674/5791/5758

As stated somewhere it is very frustating that we could get php-4.0.2 working

---------------------------------------------------------------------------

[2000-10-14 17:37:53] clivestorey <email protected>
After 27 hours of trying to install PHP4.0.3 we are lost. I cannot see the trouble we are having anywhere else/ so this maybe a bug or just us newbies.

Apache 1.3.x

We configured php-4.0.3 with
./configure --with-mysql=/usr --with-apxs there were no problems or error messages , nor with make & make install. On checking the httpd.conf file we see that the install programme has written to the file:
 
LoadModule php4_module lib/apache/libphp.so
AddModule mod_php4.c

We assume the programme is instructed to right these at the place after where it finds the last corresponding entry. In our case this places them after
LoadModule put module modules/mod_put and
AddModule mod_php4.c

this is way down in the section for home/http/html and causes the server not to run. We believe they should be placed in the section where all the other LoadModules are,
is this correct?

Also the programme sends the LoadModule php4_module to the path /lib/apache/libphp4.so. We do not have that directory. We do have usr/lib/apache/libphp4.so but on using that it states that the directory does not exist. We also have (etc/httpd/conf/)modules/libphp4.so, we tried that path without success.

Your help would be much appreciated

---------------------------------------------------------------------------

Full Bug description available at: http://bugs.php.net/?id=7212

-- 
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: php-dev-unsubscribe <email protected>
For additional commands, e-mail: php-dev-help <email protected>
To contact the list administrators, e-mail: php-list-admin <email protected>