How to check if a server is Suexec or not ?

First steps in cPanel, creating emails, databases, etc

How to check if a server is Suexec or not ?

Postby Mark » Sat Dec 19, 2009 6:57 am

To check the server is Suexec or not? follow the one of the steps which suitable with your privileges

1) Login into you server with the root login details and run following command

Code: Select all
[root@xx.xx.xx.xx ~]#/usr/local/cpanel/bin/rebuild_phpconf --current


If server is Suexec then result would look like

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

2)If you are not sure about Shell then you can also check the SuExec is enabled or not? from your WHM.Lgin into your WHM and 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 sever is SuExec enabled

3) If you are not having server root login details or WHM access.Then you can create a php file udner your account from cPanel >> File Manager 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.

4)As well as you can also create the phpinfo page under your account from your cPanel >> File manager For ex. phpinfo.php with the following code

Code: Select all
<? phpinfo() ?>


After creating phpinfo.php page browse it http://yourdomainname.com/phpinfo.php and if it shows

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
Mark
 
Posts: 124
Joined: Fri Dec 11, 2009 2:18 pm

Re: How to check if a server is Suexec or not ?

Postby naeem » Fri Jul 09, 2010 6:19 am

Hi, this is a good topic to have discussion on bit as I have go though all the posts replies there is not much to talk about every most of the replies have been written what I wanted to share.
naeem
 
Posts: 1
Joined: Fri Jul 09, 2010 6:17 am


Return to Basic cPanel usage tutorials

Who is online

Users browsing this forum: No registered users and 1 guest

cron