How to upgrade PHP to PHP 5.4 on CentOS 6 from a remi repository

Parallels Article ID: 115875

1. Install epel and remi repositories:
# wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
# wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
# sudo rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm

2. Enable remi repository:
# sudo vi /etc/yum.repos.d/remi.repo
In the [remi] section of the file, set the “enabled” option to 1.

3. Upgrade PHP with this command:
# yum install php

4. Set remi section back to 0.