Centos – Errors with a phpMyAdmin install on CentOS 7

centosPHPphpmyadmin

Well, I was trying to install phpMyAdmin on CentOS 7 (64bit) and this happens.

Here is a Pastebin of the output from yum install phpmyadmin because can’t get code thing to work.

[root@ftb ~]# yum install phpmyadmin
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: repos.dfw.quadranet.com
 * epel: fedora-epel.mirror.lstn.net
 * extras: centos.host-engine.com
 * updates: centos.arvixe.com
Resolving Dependencies
--> Running transaction check
---> Package phpMyAdmin.noarch 0:4.0.10.8-1.el6 will be installed
--> Processing Dependency: php-mcrypt >= 5.2.0 for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Processing Dependency: php-mbstring >= 5.2.0 for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Processing Dependency: php-gd >= 5.2.0 for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Processing Dependency: php-xmlwriter for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Processing Dependency: php-tcpdf-dejavu-sans-fonts for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Processing Dependency: php-tcpdf for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Processing Dependency: php-php-gettext for package: phpMyAdmin-4.0.10.8-1.el6.noarch
--> Running transaction check
---> Package php-gd.x86_64 0:5.4.16-23.el7_0.3 will be installed
--> Processing Dependency: libt1.so.5()(64bit) for package: php-gd-5.4.16-23.el7_0.3.x86_64
--> Processing Dependency: libXpm.so.4()(64bit) for package: php-gd-5.4.16-23.el7_0.3.x86_64
---> Package php-mbstring.x86_64 0:5.4.16-23.el7_0.3 will be installed
---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
--> Processing Dependency: php(zend-abi) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: php(api) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: libmcrypt.so.4()(64bit) for package: php-mcrypt-5.3.3-3.el6.x86_64
---> Package php-php-gettext.noarch 0:1.0.11-3.el6 will be installed
---> Package php-tcpdf.noarch 0:6.2.4-1.el6 will be installed
--> Processing Dependency: php-tidy for package: php-tcpdf-6.2.4-1.el6.noarch
--> Processing Dependency: php-bcmath for package: php-tcpdf-6.2.4-1.el6.noarch
---> Package php-tcpdf-dejavu-sans-fonts.noarch 0:6.2.4-1.el6 will be installed
--> Processing Dependency: dejavu-sans-fonts for package: php-tcpdf-dejavu-sans-fonts-6.2.4-1.el6.noarch
---> Package php-xml.x86_64 0:5.4.16-23.el7_0.3 will be installed
--> Running transaction check
---> Package dejavu-sans-fonts.noarch 0:2.33-6.el7 will be installed
--> Processing Dependency: dejavu-fonts-common = 2.33-6.el7 for package: dejavu-sans-fonts-2.33-6.el7.noarch
---> Package libXpm.x86_64 0:3.5.10-5.1.el7 will be installed
---> Package libmcrypt.x86_64 0:2.5.8-9.el6 will be installed
---> Package php-bcmath.x86_64 0:5.4.16-23.el7_0.3 will be installed
---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
--> Processing Dependency: php(zend-abi) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: php(api) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
---> Package php-tcpdf.noarch 0:6.2.4-1.el6 will be installed
--> Processing Dependency: php-tidy for package: php-tcpdf-6.2.4-1.el6.noarch
---> Package t1lib.x86_64 0:5.1.2-14.el7 will be installed
--> Running transaction check
---> Package dejavu-fonts-common.noarch 0:2.33-6.el7 will be installed
---> Package php-mcrypt.x86_64 0:5.3.3-3.el6 will be installed
--> Processing Dependency: php(zend-abi) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
--> Processing Dependency: php(api) = 20090626 for package: php-mcrypt-5.3.3-3.el6.x86_64
---> Package php-tcpdf.noarch 0:6.2.4-1.el6 will be installed
--> Processing Dependency: php-tidy for package: php-tcpdf-6.2.4-1.el6.noarch
--> Finished Dependency Resolution
Error: Package: php-tcpdf-6.2.4-1.el6.noarch (epel)
           Requires: php-tidy
Error: Package: php-mcrypt-5.3.3-3.el6.x86_64 (epel)
           Requires: php(api) = 20090626
           Installed: php-common-5.4.16-23.el7_0.3.x86_64 (@updates)
               php(api) = 20100412-64
           Available: php-common-5.4.16-21.el7.x86_64 (base)
               php(api) = 20100412-64
           Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
               php(api) = 20100412-64
           Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
               php(api) = 20100412-64
Error: Package: php-mcrypt-5.3.3-3.el6.x86_64 (epel)
           Requires: php(zend-abi) = 20090626
           Installed: php-common-5.4.16-23.el7_0.3.x86_64 (@updates)
               php(zend-abi) = 20100525-64
           Available: php-common-5.4.16-21.el7.x86_64 (base)
               php(zend-abi) = 20100525-64
           Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
               php(zend-abi) = 20100525-64
           Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
               php(zend-abi) = 20100525-64
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

Best Answer

To solve your problem you need to install priorities:

yum install yum-priorities

Next edit your /etc/yum.repos.d/remi.repo:

nano /etc/yum.repos.d/remi.repo

and add priority=5 to remi repository. Warning: priority MUST be 10 on EPEL repository.

[remi-php56]
name=Remi's PHP 5.6 RPM repository for Enterprise Linux 7 - $basearch
#baseurl=http://rpms.remirepo.net/enterprise/7/php56/$basearch/
mirrorlist=http://rpms.remirepo.net/enterprise/7/php56/mirror
# NOTICE: common dependencies are in "remi-safe"
enabled=1
priority=5
gpgcheck=1
gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi

then yum update
and yum install php_mcrypt
*normaly it works because it goes to the remy's repositiry to install php_mcrypt package.

Related Question