Upgrade PHP From 5.4 to 7.0 on a CentOS 7 Cloud Server
This is a significant upgrade, with potential for causing serious conflicts with any web software you may be running.
We strongly recommend that you create a snapshot of your server before you proceed. This will allow you to roll back any changes if you encounter a problem with the upgrade.
Requirements
- A Cloud Server running CentOS 7
- PHP version 5.4
Use the php -v command to verify your current PHP version:
Upgrade to PHP 7
We will be using the IUS repository to upgrade PHP. Although there are several repositories which have made available versions of PHP 7 for CentOS 7, IUS is the only one which carries the official recommendation of the CentOS Project.
Remove the existing version of PHP:
Update packages:
Install PHP 7:
Restart Apache:
Use the php -v command to verify that PHP has been upgraded:
- Free Wildcard SSL for safer data transfers
- Free private registration for more privacy
- Free 2 GB email account