Linux – PHP debugging under Apache on CentOS 5.9

apache-2.2centos5linuxPHPvbulletin

After upgrading a vBulletin installation, accessing any page tells me that files are missing–even though they exist in the filesystem.

Based on other questions I found here, I have tried changing the file permissions to no avail, changing the error log directive and php.ini, and changed ownership of the files it's trying to access.

Nothing I do seems to give me an informative error message. Running the scripts from the command line fail to give me the same errors, so that doesn't help.

Is there any way to execute a php file from the command line as if it was running under Apache? I'm hoping that might produce more informative errors.

EDIT: it was a permissions issue on the directory. includes/datastore was 644 instead of 755.

…still don't know how to get informative php error messages. 🙁

Best Answer

"Is there any way to execute a php file from the command line as if it was running under Apache?"

Either you can run a php script from command line using php cli eg :

 php /path/to/myscript

But it won't execute it "as if it was running under Apache".

Either you can call the page from command line using curl or wget, but it won't be useful for debugging.