Simply check server is SuExec or not?

Simply check server is SuExec or not?

How to check server is SuExec or not?

From your shell run the following command but make sure that you have logged in as a root user else it will throw the error “Permission denied”.

[root@xx.xx.xx.xx ~]#/usr/local/cpanel/bin/rebuild_phpconf –current

DEFAULT PHP: 5
PHP4 SAPI: suphp
PHP5 SAPI: suphp
SUEXEC: enabled

or make a php file under any account and change the permissions on that file to 777 and open it in a browser. If it gives 500 Internal Server Error, your most probably running suPHP.

Alternatively,
If you have access to WHM – login, in the menu find Configure PHP and SuExec
Check the drop down box for “PHP 4/5 Handler” – and if beside that it says “suPHP” – then your server is running it.

SuPHP activity is logged in /usr/local/apache/logs/suexec_log. If you tail it, you will see if there is any current activity:
Code:
tail -f /usr/local/apache/logs/suexec_log

you can also get this information from PHP INFO page:

IF

Server API = Apache then server is not running PHP in SuExec mode

And if

Server API = CGI the server is running PHP in SuExec mode

That’s all now you are sure about your server is SuExec or not

About Anant 372 Articles
Senior technical writer

1 Trackbacks & Pingbacks

  1. Disable safe_mode for individual hosting account – KTCHost

Comments are closed.