I have a server with centos 6.8 I am trying to install

  1. php 5.5.
  2. mysql 5.5
  3. php-mbstring

But it shows error message as: Error: php55w-common conflicts with php-common-5.3.3-48.el6_8.x86_64

Please tell me step by step guide to install.


to remove the previous install

yum remove php-common-5.3.3-48.el6_8.x86_64

this was suggested on another forum:

rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-6.noarch.rpm rpm -Uvh https://mirror.webtatic.com/yum/el6/latest.rpm

you can install php5.5 using

yum install php55w php55w-opcache

or upgrade your existing installation using

yum install yum-plugin-replace

yum replace php-common --replace-with=php55w-common

package name for mbstring is php55w-mbstring

the package name for mysql is php55w-mssql

information for centos was aquired from


information for linux debian/ubuntu based below

for if you do not have it, you can install the ondrej PPA

add-apt-repository ppa:ondrej/php5

or the general php ppa

add-apt-repository ppa:ondrej/php

if this gives an error for UTF 8 localization you can use

LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php5


LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php

then uninstall the previous php installation

sudo apt purge php-common-5.3.3-48.el6_8.x86_64

and update your ppa lists with

sudo apt update

right after if this all went correctly you should be able to use

sudo apt-get install php(version of choice) mysql(version of choice) php-mbstring
  • sorry, i came to realize that centos doesn't use apt ill be looking for another answer! ill update this once i found the correct answer – Jesse Dec 7 '16 at 10:23
  • you're welcome, just let me know if it worked or not :) – Jesse Dec 7 '16 at 11:33

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.