Upgrading From EasyApache3 to EasyApache4
Introduction
EasyApache is a built-in cPanel utility used to compile, update, and customize Apache and PHP. EasyApache 3 has been around for a long time, but its support will be ending soon. EasyApache 4 is the successor to EasyApache 3 and with it comes many benefits such as having prebuilt binary packages and multiple PHP versions including PHP 7 and 7.1 support. The EasyApache 3 depreciated schedule can be found on cPanel's website here:
Why should I upgrade?
In the past, to update EasyApache 3 or install an Apache or PHP module inside of EasyApache 3, it would be required a recompile which means site downtime. Now with EasyApache 4, there are prebuilt binary packages which mean there is virtually no site downtime for an install or upgrade. Also, these packages allow updates to be performed with server automatically which can maximize the stability and security of the associated services.
Please note that according to cPanel if you are running EasyApache 3, the server's cPanel software will be blocked from upgrading to v62 or later. It is highly recommended to upgrade to EasyApache4 and continue to get the latest updates of cPanel and WHM.
Checking Version
To see which version of EasyApache is running, you will need to navigate to WHM and log in as the root user. From there go the Software section, then to the EasyApache 4 option.
If the page displays as Currently Installed Packages, then the server has EasyApache 4 installed.
If the page displays EasyApache 4 is not available when EasyApache 3 is active, then the server is still running EasyApache 3. If this is a Hostgator VPS or dedicated server, you can contact us via phone or Live Chat and request a ticket be created to be updated to EasyApache 4.
Frequently Asked Questions
Which versions of Apache and PHP will be installed with Easy Apache 4?
PHP 5.4, 5.5, 5.6 and 7.0 will be installed with Apache 2.4. PHP 7.1 is also available, please see How can I add, remove or install components for EasyApache 4? on how to do this.
How can I change my site to use a different PHP version?
If a specific site needs to use a certain PHP version, this can be changed in WHM by:
- Going to the Software section > MultiPHP Manager > PHP Versions.
- Once here check the box on the left which is next to the domain you would like to have the custom PHP version.
- You will then want to select the desired PHP (ex: ea-php56) in the PHP Version drop-down in the upper right.
- Click on the Apply button on the right to apply the changes.
As an alternative, the following can be added to the .htaccess file:
AddType application/x-httpd-ea-php56 .php
How can I run a PHP script using a different PHP version?
Below is how to run a PHP script from the command line for a specific PHP version:
/usr/bin/php -ea_php 56 /path/to/filename.php
How can I add, remove or install components for EasyApache 4?
- Log in as root into WHM
- Go to Software >> EasyApache 4 and click on the Customize button. This will provide a series of menus to toggle on or off the desired component.
- The last screen will show a list of packages to be installed or removed, click on the Provision button continue.
- After the provisioning has completed, click Done and the main EasyApache 4 screen will return.