We are trying to get PHP4 to work as a FastCGI module. We have successfully installed php4 and FastCGI, and added the module to the directives for the site we need PHP4 to run on, but instead of loading the site we are just getting a blank white page. When running the same site on Apache with PHP4 module, the site loaded just fine.
Using the FastCGI method we are getting the phpinfo() page to load just fine, from within the same site/directory as the site in question. We also made sure the permissions on the .php files are correctly set to the user who owns the virtual server. Not sure what else to check, any suggestions?
Right when I hit the site, there are no "fresh" log entries in error_log generated, but these are in the log from yesterday for some reason, might be from something we were doing…
/var/log/httpd/error_log (i’m not sure why its not writing this to the domain specific error_log?):
[code:1]
[Sat May 16 03:30:02 2009] [notice] mod_fcgid: call /home/citystudent/domains/toronto.citystudent.com/public_html/index.php with wrapper /home/citystudent/domains/toronto.citystudent.com/fcgi-bin/php4.fcgi
[Sat May 16 03:30:02 2009] [info] mod_fcgid: server /home/citystudent/domains/toronto.citystudent.com/public_html/index.php(2210) started
[/code:1]
Just another note, subsequent visits to the site are being logged in access_log but nothing is being recorded in error_log… I turned up the logging to Debug and still nothing…
So you’re not getting errors any more, but it’s still not working? That makes no sense. Are you sure the script is producing output? Could you try a simple phpinfo page?
<?php
// Show all information, defaults to INFO_ALL
phpinfo();
Hi Joe. I’m confused, where did you see that we’re running both mod_php and mod_fcgid at the same time? Also I don’t think Apache is crashing, that would probably be logged.
"Oh, are you loading both mod_php version 4 and 5 at the same time?"
And, as an afterthought I injected the bit about running mod_php and mod_fcgid.
To clarify, again: It is OK to run run mod_fcgid and mod_php together, but unnecessary.
It is not OK to run two versions of mod_php at the same time in the same Apache process, and it will break things to do so.
I was making no assumptions about your configuration. I was just mentioning one condition that would lead to Apache failing to respond and failing to log anything.
You know I’m just guessing at this point, right? I have no idea what’s wrong. Without errors, I’m completely flying blind. Just mentioning something I’ve seen in the past that seemed like a mysterious problem at the time.
#<Directory /home/citystudent/domains/toronto.citystudent.com/public_html> #Options -Indexes IncludesNOEXEC FollowSymLinks #allow from all #AllowOverride All
#</Directory>
<Directory /home/citystudent/domains/toronto.citystudent.com/public_html>
Options Indexes IncludesNOEXEC FollowSymLinks ExecCGI
allow from all
AllowOverride All
AddHandler fcgid-script .php
AddHandler fcgid-script .php4
FCGIWrapper /home/citystudent/domains/toronto.citystudent.com/fcgi-bin/php4.fcgi .php
</Directory>
Just a note, the citystudent site that is "live" on the net is sitting on my old server that is waiting to be decommissioned (uses HSphere), we are working on my new server (with IP 69.42.52.170), so you just need to point your HOSTS to that if you want to give it a try… and see the the wonderful blank white page.