PHP and Server 2008 not reading configuration file

Need help installing PHP, configuring a script, or configuring a server? Then come on in and post your questions! We'll try to help the best we can!

Moderator: General Moderators

Post Reply
johnhwyman
Forum Newbie
Posts: 5
Joined: Sun Feb 10, 2008 1:27 pm

PHP and Server 2008 not reading configuration file

Post by johnhwyman »

I have a new installation of Server 2008 and PHP 5.2.5 (php5isapi) when I run a test with phpinfo the entry
Configuration File Path C:\Windows
Loaded Configuration File (none) <<<<<--- this isn't right

I have the php.ini file in the windows directory
file has read rights for IUSR

everything else looks normal. I have the same setup on server 2003 and it works fine, what am I doing wrong

John
User avatar
liljester
Forum Contributor
Posts: 400
Joined: Tue May 20, 2003 4:49 pm

Re: PHP and Server 2008 not reading configuration file

Post by liljester »

I dont find an IIS user in my 2008 installs... Are you sure IIS runs under the same user in IIS7 as it did in older versions? Change the permissions on your php.ini to let everyone read. See if it works then. If so, you know its a permission issue.
User avatar
liljester
Forum Contributor
Posts: 400
Joined: Tue May 20, 2003 4:49 pm

Re: PHP and Server 2008 not reading configuration file

Post by liljester »

Upon further investigation, your config file is read by the service, and therefore requires that "NETWORK SERVICE" account have read/execute permissions. If youre worried about Unauthorized access to your config file, you should remove the IUSR permissions from php.ini file as well, its basically a guest account that IIS uses for remote connections.

Let know how it turns out for ya.
johnhwyman
Forum Newbie
Posts: 5
Joined: Sun Feb 10, 2008 1:27 pm

Re: PHP and Server 2008 not reading configuration file

Post by johnhwyman »

No go. Now things are even stranger. About 1/2 hour after I posted, php stopped working all together. I reinstalled server 2008 and php, worked for 30 minutes (still not reading ini) than quit without any warning. No entryies in logs, no nothing.

OK, I also installed PHP on my laptop running Vista Ultimate SP1 (release) and it exhibited the same behavior. a) doesn't read ini file, and quit working after 20-30 minutes. Nothing I do gets it working again. I wonder if SP1 and Server 2008 Production have some strange quirk. I had php working previously on my Vista laptop.

John
User avatar
liljester
Forum Contributor
Posts: 400
Joined: Tue May 20, 2003 4:49 pm

Re: PHP and Server 2008 not reading configuration file

Post by liljester »

are you changing any permissions at all on your php.ini file (or any of the files for that matter)? or it just fails? event viewer doesnt show any failures regarding php? installing php as isapi, or CGI?
johnhwyman
Forum Newbie
Posts: 5
Joined: Sun Feb 10, 2008 1:27 pm

Re: PHP and Server 2008 not reading configuration file

Post by johnhwyman »

I have tried initialy with no changes to anything, than to the extreme Everyone full Access, still no go. Also tried both Isapi and cgi no difference. Also once it stops working only a full reinstall of server 2008 gets me going again.

I am begining to think it has to do with Server 2008 and exactly same symptoms on Vista with SP1, only I don't have an image of my laptop so I'll need to reinstall and see if I can get it working without SP1

Really strange.

John
User avatar
liljester
Forum Contributor
Posts: 400
Joined: Tue May 20, 2003 4:49 pm

Re: PHP and Server 2008 not reading configuration file

Post by liljester »

Im at a loss...

what version of Server 2008 are you using? an old beta? RC?
johnhwyman
Forum Newbie
Posts: 5
Joined: Sun Feb 10, 2008 1:27 pm

Re: PHP and Server 2008 not reading configuration file

Post by johnhwyman »

Server 2008 SP1 X86

en_windows_server_2008_datacenter_enterprise_standard_x86_dvd_X14-26710.iso ISO-9660 DVD Image
User avatar
liljester
Forum Contributor
Posts: 400
Joined: Tue May 20, 2003 4:49 pm

Re: PHP and Server 2008 not reading configuration file

Post by liljester »

hm... ive only got my hands on an RC.

maybe theres a change since my RC version. Ill see if i can come up with the release version.
Post Reply