While DSO is one of the oldest PHP handlers in use, it is also one of the fastest. As such, you may find yourself looking to use this PHP handler instead of suPHP. By default, DSO is installed on most CentOS servers, however, it is not enabled by default.
In order to enable DSO, you must manually switch your PHP handler via the command-line interface. As this change affects everyone on your server, it is only possible to do so with root access. In this article, we will outline how to enable DSO in the command-line after it has been installed.
Note that you will need root access in order to use these directions.
Topics Include:
Check DSO Availability
Before enabling DSO, it is a good idea to first confirm that it is installed properly. Using the same command, we can also check to see if RUID2 is enabled.
Enabling RUID2 will further enhance server performance for PHP heavy websites, but it is not recommended for use on servers with a large number of websites. As it is an older technology, it is not as efficient or secure as newer PHP handlers such as suPHP.
- First, log into your server via SSH.
- Next, run the following command to make sure your current PHP handlers are installed correctly:
/usr/local/cpanel/bin/rebuild_phpconf --current
Enabling DSO
Now that you have confirmed that DSO is installed, you can begin the installation process.
- First, log into your server via SSH.
- Next, run the following command to change the system from your current configuration to DSO:
/usr/local/cpanel/bin/rebuild_phpconf 5 none dso disable
- Finally, run the following command to confirm the changes have been made:
/usr/local/cpanel/bin/rebuild_phpconf --current
Congratulations, now you know how to enable DSO on your dedicated server!
Would you rather install suPHP? Check out our guide for installing suPHP using EasyApache 4!