LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 03-24-2005, 09:51 AM   #1
atom
Member
 
Registered: Feb 2004
Location: Slovenia
Distribution: archlinux
Posts: 271

Rep: Reputation: 31
Thumbs up [solved] php5 apache2 mysql4 don't work, php does not seem to read php.ini


Hi everyone, and thanks for reading this.

I'm setting up a server on FC 3. Done the same thing on RH9 and it worked, and i'm stumped.

I downloaded apache2, php5 (src) and mysql (standard bin they provide).
I compiled apache2. Installed, configured, starts fine.
Compiled php5 as sapi module for apache2. Apache loads module fine, phpinfo() displays fine. php works (at least as code is concerned). I compiled it with mysql support too, but now i'm clueless as to why it does not work. this is my php5 compilation command:
Code:
configure.sh:
#!/bin/bash
./configure \
--prefix=/usr/local/php5/ \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-config-file-path=/etc \
--with-zlib \
--with-bz2 \
--with-jpeg \
--with-tiff \
--enable-ftp \
--with-gd \
--with-mysql=/usr/local/mysql/ \
--with-mysql-sock=/var/lib/mysql/mysql.sock \
--disable-cgi
echo -e "\n\nconfigure complete\a"
sleep 5
echo -e "\n\nstarting compilation\a"
make
echo -e "\n\ninstalling...\a"
make install
echo -e "\n\nall done. \n"
now it compiles fine. But when it's run it does not seem to read the php.ini, or even try and use the mysql.sock that was compiled in. However, the path to the php.ini is set fine. (according to phpinfo()).

Any ideas anyone?

oh, btw, it's this server, if anyone wants to check... http://193.2.145.160/phpinfo.php

Thanks again for any help... this has been getting on my nerves for some time now.

Last edited by atom; 03-24-2005 at 11:05 AM.
 
Old 03-24-2005, 10:17 AM   #2
trevelluk
Member
 
Registered: Nov 2003
Location: Bristol, UK
Distribution: Debian Lenny, Gentoo (at work)
Posts: 388

Rep: Reputation: 32
I think the path to the php.ini actually needs to include the filename. So it should be /etc/php.ini, not just /etc

This is the way that it's set up here anyway (admittedly, this is the Windows version of PHP, but I'd imagine that the Linux version is the same).
 
Old 03-24-2005, 10:20 AM   #3
atom
Member
 
Registered: Feb 2004
Location: Slovenia
Distribution: archlinux
Posts: 271

Original Poster
Rep: Reputation: 31
Tried that too, didn't work.

Anyway both *should* work, because php.ini is always php.ini... i'll try with /etc/ this time ... i'll keep you guys posted. In the meantime, ideas are still welcome, I don't think this will work either.

Gasper
 
Old 03-24-2005, 10:35 AM   #4
trevelluk
Member
 
Registered: Nov 2003
Location: Bristol, UK
Distribution: Debian Lenny, Gentoo (at work)
Posts: 388

Rep: Reputation: 32
Just a thought, but what are the permissions on the php.ini file? You could try giving read access to everyone and see if this helps.
 
Old 03-24-2005, 10:42 AM   #5
atom
Member
 
Registered: Feb 2004
Location: Slovenia
Distribution: archlinux
Posts: 271

Original Poster
Rep: Reputation: 31
Code:
 -rw-r--r--   1 root root   41177 mar  9 14:28 php.ini
Yeah, i thought of that... it would seem it isn't connected. I'll try giving the file to user apache (group apache) and see if that's what's preventing it to read it.

Code:
 -rw-r--r--   1 apache apache   41177 mar  9 14:28 php.ini
No change whatsoever.

Meanwhile, i'll try mrproper-ing the php source and see if that's what's blocking it. I'll also try the v. 2.0.53 version of apache, 2.0.52 was masked with php5 out of portage for a reason...
 
Old 03-24-2005, 11:05 AM   #6
atom
Member
 
Registered: Feb 2004
Location: Slovenia
Distribution: archlinux
Posts: 271

Original Poster
Rep: Reputation: 31
Problem solved. Apparently version 2.0.52 does not work well with php5. Everything should work now.

Thanks for your time
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
installing apache2+php5+mysql4 problem yangying Linux - Software 5 04-21-2005 01:24 AM
Upgraded PHP from 4.3.4 to 4.3.10 and now it won't read php.ini gregmcavoy Linux - Software 11 01-22-2005 12:16 PM
php5 configure with different php.ini file dtra Linux - Software 2 01-19-2005 08:04 PM
php: different mail server from php.ini rayds Programming 0 09-14-2004 03:48 AM
PHP unable to read .php files tuka Linux - Software 6 10-12-2003 06:40 PM


All times are GMT -5. The time now is 09:32 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration