Cannot install mbstring php conflict

user1011332 picture user1011332 · Jan 18, 2016 · Viewed 8.9k times · Source

I am trying to install php-mbstring with php 5.6 and I get this error:

Error: php56w-common conflicts with php-common-5.4.45-3.el6.remi.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest

I have attempted to install php56-mbstring, but I get the following. I am not sure if this means it is already installed or not:

Nothing to do

What is the most appropriate package to install? Which one should I be trying to resolve and how can I resolve it. Thanks!

Answer

Aleksi picture Aleksi · Jan 25, 2016

I run into same problem with my server running PHP 5.6.17. For me it seems that the extension that I was looking for was php56w-mbstring.x86_64

It can be found from webtatic repository. I don't remember enabling that by myself, but in case it is missing here is the instructions how to enable said repo: http://www.certdepot.net/rhel7-install-webtatic-repository/

You can list available repos in your server by command yum repolist

To search if your repos has something related to mbstring use command yum list *mbstring*

So solution for me was this: yum install php56w-mbstring.x86_64

Finally restart Apache: service httpd restart

By the way, I am running CentOS server so your commands might be slightly different on your OS.