LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   PHP install: httpsd.conf not found? (https://www.linuxquestions.org/questions/linux-software-2/php-install-httpsd-conf-not-found-51710/)

J_Szucs 03-25-2003 03:12 PM

PHP install: httpsd.conf not found?
 
I tried to install PHP4 as a loadable apache module, configuring it as follows:
./configure --with-apxs --with-pgsql --enable-mbstring --enable-mbregex

The configuration seemed to be OK, though I could not clearly find out from the PHP manual what is that --with-apxs option on the command line.
When running make install, however, I got the following error:
apxs:Error: Config file /usr/local/etc/apache/httpsd.conf not found

I simply want to install PHP as a loadable apache module, with pgsql support. Do I need the --with-apxs option for that?
If so, do I need to reconfigure or worse: recompile apache in order that I can install PHP correctly?

mcleodnine 03-25-2003 03:27 PM

what did ./configure --help tell you about that option?

J_Szucs 03-25-2003 04:11 PM

Here it is:
--with-apxs[FILE]: Build shared Apache 1.x module. FILE is the optional pathname to the Apache apxs tool; defaults to apxs.

This is all ./configure --help provides, and the same short information is in the PHP manual.
Not much for a green newbie.

The problem is that I have to do manual configuration on this machine.
On an other machine I have SuSe, which did the configuration for me. PHP is working well there. However I could not find any file or directory there with name 'apxs' or https.conf, so that machine did not give me the clue how to configure this one manually.

J_Szucs 03-25-2003 10:42 PM

Now I found apxs in /usr/local/sbin, and think that PHP found it, too. It is clear now that it is a tool needed to compile the PHP apache module.
The only thing that i do not know is why httpsd.conf is missing and how can I get one.

(It was not me who installed apache on this production server, and would prefer to avoid recompiling it, if possible. I could not even find the apache sources on the server)

J_Szucs 03-26-2003 02:14 AM

Now I created httpsd.conf and compiled php with success. (Things improve from day to day, it may even happen that I will have php running in a month...)

So, I also added the LoadModule statement in httpd.conf, together with the type declaration line.

However, when I put a .php file (being actually a html page, only) in my html doc directory, it is simply downloaded as a text file by the clients.
If I put it elsewhere, the clients get an error 'page not found'.

What did I do wrong?
How can I check if the php module is actually loaded when that .php file is requested?

J_Szucs 03-26-2003 02:29 AM

Problem solved:
The php module was actually not loaded since there was a ClearModules statement following the AddModules statement in the httpd.conf file.
So I had to insert an AddModule mod_php4.c line into httpd.conf.


All times are GMT -5. The time now is 12:30 PM.