Installing PHP 5
I was wondering if anyone can help me with a problem I am having installing PHP 5 on my CentOS server?
I followed the install instructions PHP provides to no avail. I get this error when trying to start httpd:
httpd: Syntax error on line 53 of /usr/local/apache2/conf/httpd.conf: Cannot load /usr/local/apache2/modules/libphp5.so into server: /usr/local/apache2/modules/libphp5.so: undefined symbol: sapi_globals
I'm not specifically familiar with CentOS's arrangement, but it's an RPM distribution, so you can use the RPM database to check for corruption.
The rpm -V command tests an installed package for changes or corruption. The rpm -qa command lists all installed RPMs that match the argument. You can combine these to test all of your installed PHP RPMs like this. If all is well, you will get no output. If any file is changed in any way, it will be listed with a code that says how it was changed.
Similarly, you can test all your apache files like this. You may have several configuration files and directories changed that are no problem, but investigate any file you see that's modified that shouldn't be.
rpm -V $(rpm -qa '*php*')
Of course you should also check for updates. If there is a bug, CentOS may have released an RPM update to fix it.
rpm -V $(rpm -qa '*apache*')