Configure suPHP on cPanel

After installing suPHP and before changing the PHP handler from your default one to suPHP, there are a few configuration options that need to be checked.

1) Check if the suPHP module is correctly loaded in the Apache configuration file.
# LoadModule suphp_module libexec/mod_suphp.so

2) Run the below scripts to double check the server settings:
# /scripts/postsuexecinstall
# /scripts/chownpublichtmls

3) Lets check the permissions now.
If there are files with either 777 or 666 permission inside the document root, you are most likely to get Internal Server Errors.
find /home/*/public_html/ -perm 777 -exec ls {} \;
find /home/*/public_html/ -perm 777 -exec ls {} \;
Set 755 and 644 respectively, for the files that gets listed in the above command.

4) Check the CGI scripts as well
# /scripts/fixsuexeccgiscripts

5) Last but not the least, make sure that there are no php_flags in the domain’s .htaccess file.
# grep -iRl php /home/*/public_html/.htaccess

If you want to use php flags for the domains, create a custom php.ini file and place it in the domain’s web root.

Comments

Popular posts from this blog

SVN: File remains in conflict

HowTo: Enable extended logging for exim

12 tweakings for WHM/cPanel to speed up WordPress