Installing a PHP Version Selector on your Linux VPS or Dedicated Server

If you have recently upgraded from our shared services to a VPS or Dedicated server, then you have probably noticed you do not have a PHP version selector anymore. No worries! Here is how to get one for your server, for free.

Before we begin: please ensure your server has suphp enabled. You can verify this from SSH by entering the following commands:

# /usr/local/cpanel/bin/rebuild_phpconf --current

If it is enabled, you will see the following output. If it says something else, like fcgi, then you will need to recompile Apache using EasyApache in cpanel. If you select “Arvixe Build” you will meet this requirement.

Available handlers: suphp dso fcgi cgi none
DEFAULT PHP: 5
PHP4 SAPI: suphp
PHP5 SAPI: suphp
SUEXEC: enabled

1. Log into your server via SSH, as root user. You must install this as root, otherwise you won’t have permissions for the right directories.

2. Change directory to /usr/local/src

cd /usr/local/src

2. Download the NixTree PHP Version selector installer script:

wget -N http://nixtree.com/download/free/ntphpselector_manage.sh

3. Execute the installer script:

sh ntphpselector_manage.sh install

This process will take an hour or two, depending on the speed of your machine. It is not a quick process, as it is compiling every version of PHP that is not present on your server already. The Arvixe build by default installs PHP 5.3 so you will see it install 5.2, 5.4, and 5.5. You will not need to restart the server afterwards.

Once you log in to your cpanel, you will see a tool called ntPHPSelector in your Software/Services section.

versionselectoricon

You can use this to manage your PHP versions per directory there in the same fashion you’d use our 1H version selector on our shared services.

versionselectorpage

Looking for quality web hosting? Look no further than Arvixe Web Hosting!

Tags: , , , , , , , , , | Posted under cPanel/Linux Hosting | RSS 2.0

Author Spotlight

Arian Jahansouz

Arian Jahansouz

Hello, I am Arian! I have been writing for Arvixe since 2009 and now head the Arvixe Blog. Feel free to contact me at any time with questions or comments!

Leave a Reply

Your email address will not be published. Required fields are marked *


4 + = 7

You may use these HTML tags and attributes: <a href="" title="" rel=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>