Error Start Apache “php value”

I recently ran into this exact problem using Plesk 9.5 on CentOS.

I cannot say for sure whether it was caused by an update to Plesk, or not. The customer doesn’t think any changes were made recently, but Apache failed to start with this error.

After an assesment of the system to ensure it wasn’t due to a breach, I did some troubleshooting and determined that mod_php had been removed from the Apache config. After checking Plesk settings, every vhost on the box was using FastCGI and SuExec.

When using FastCGI and SuExec, you cannot change PHP directives in php.conf (FastCGI) and .htaccess (SuExec).

The customer had originally commented out the offending lines, but this broke session support for everything. The only way I was able to resolve it was to manually add mod_php back to httpd.conf.

Add the following line to the section with the other LoadModule’s. Make sure the path (../modules/) matches the rest of the modules in there. Chances are good that it already exists on your system and was simply removed from the config during the update.

bash# vi /etc/httpd/conf/httpd.conf
LoadModule php5_module ../modules/libphp5.so

bash# apachectl restart

This caught me off guard, and I cannot say for sure it is the upgrade that caused the issue or whether this is the best fix. I am open for comment, but highly advise against commenting out the php directives in /etc/httpd/conf.d/php.conf as it will break stuff.

Leave a Comment