IT Update Centos 6.5 from PHP 5.4 to 5.5 via Yum shell

When trying to update directly from PHP 5.4 to 5.5, we get a conflict about php-common :

Error: php55w-common conflicts with php54w-common-5.4.45-2.w6.x86_64

Trying to remove php54w-common via yum will not help, since Roundcube is listed as a dependancy of this package, and would be removed to.

So we have to proceed via yum shell. According to his manpage,

yum includes an interactive shell for conducting multiple commands or sets of commands during a single execution of yum.

This way, we can proceed to the removal of php5.4 and the install of 5.5 in a single action ; the dependancies will be evaluated only at the end of the action (and so, roundcube will not be removed by the uninstall of php54w-common.

First, we list the php54 packages to remove :

$  rpm -qa | grep php54w

The, we proceed via yum shell :

sudo yum shell 
> remove php54w-process php54w-gd php54w-common php54w php54w-mysql php54w-xml php54w-mbstring php54w-tidy php54w-pear php54w-cli php54w-mcrypt php54w-pdo
> install php55w-process php55w-gd php55w-common php55w php55w-mysql php55w-xml php55w-mbstring php55w-tidy php55w-pear php55w-cli php55w-mcrypt php55w-pdo
> run

Et voilà !

Comments are closed.