当我尝试安装 phpmyadin 时出现一些错误,我是否遗漏了什么?
CentOS 7
# wget http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-2.noarch.rpm
# wget http://rpms.famillecollet.com/enterprise/remi-release-7.rpm
# rpm -Uvh remi-release-7*.rpm epel-release-7*.rpm
# yum update
# yum --enablerepo=remi,remi-php55 install php php-common
# yum --enablerepo=remi,remi-php55 install php-gd php-pdo php-mysql
# yum install mysql
# yum install mariadb-server
# systemctl start mariadb
# mysql_secure_installation
# service httpd start
# yum install phpmyadmin or yum --enablerepo=remi install phpmyadmin
错误
Error: Package: php-mbstring-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
php-common(x86-64) = 5.5.18-1.el7.remi
Available: php-common-5.4.16-21.el7.x86_64 (base)
php-common(x86-64) = 5.4.16-21.el7
Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0
Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.1
Available: php-common-5.4.16-23.el7_0.3.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.3
Available: php-common-5.4.33-2.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.33-2.el7.remi
Available: php-common-5.4.34-1.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.34-1.el7.remi
Error: Package: php-recode-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
php-common(x86-64) = 5.5.18-1.el7.remi
Available: php-common-5.4.16-21.el7.x86_64 (base)
php-common(x86-64) = 5.4.16-21.el7
Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0
Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.1
Available: php-common-5.4.16-23.el7_0.3.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.3
Available: php-common-5.4.33-2.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.33-2.el7.remi
Available: php-common-5.4.34-1.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.34-1.el7.remi
Error: Package: php-tidy-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
php-common(x86-64) = 5.5.18-1.el7.remi
Available: php-common-5.4.16-21.el7.x86_64 (base)
php-common(x86-64) = 5.4.16-21.el7
Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0
Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.1
Available: php-common-5.4.16-23.el7_0.3.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.3
Available: php-common-5.4.33-2.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.33-2.el7.remi
Available: php-common-5.4.34-1.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.34-1.el7.remi
Error: Package: php-mcrypt-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
php-common(x86-64) = 5.5.18-1.el7.remi
Available: php-common-5.4.16-21.el7.x86_64 (base)
php-common(x86-64) = 5.4.16-21.el7
Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0
Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.1
Available: php-common-5.4.16-23.el7_0.3.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.3
Available: php-common-5.4.33-2.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.33-2.el7.remi
Available: php-common-5.4.34-1.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.34-1.el7.remi
Error: Package: php-bcmath-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
php-common(x86-64) = 5.5.18-1.el7.remi
Available: php-common-5.4.16-21.el7.x86_64 (base)
php-common(x86-64) = 5.4.16-21.el7
Available: php-common-5.4.16-23.el7_0.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0
Available: php-common-5.4.16-23.el7_0.1.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.1
Available: php-common-5.4.16-23.el7_0.3.x86_64 (updates)
php-common(x86-64) = 5.4.16-23.el7_0.3
Available: php-common-5.4.33-2.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.33-2.el7.remi
Available: php-common-5.4.34-1.el7.remi.x86_64 (remi)
php-common(x86-64) = 5.4.34-1.el7.remi
答案1
线索就在错误消息中:
Error: Package: php-mbstring-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
php-common(x86-64) = 5.5.18-1.el7.remi
Error: Package: php-recode-5.4.34-1.el7.remi.x86_64 (remi)
Requires: php-common(x86-64) = 5.4.34-1.el7.remi
Installed: php-common-5.5.18-1.el7.remi.x86_64 (@remi-php55)
您运行的是来自 remi repo 的 php55,但 phpmyadmin 依赖 php54 组件。我不确定最好的解决方法,但您有几个选择。您可以尝试安装 php55 版本的 php-mbstring 和 php-recode。但据我猜测,您可能会得到与它相同的错误需求该版本的依赖项。
您可以尝试使用 php 5.4 而不是 php 5.5,如果您因为任何特殊原因不需要 php 5.5,那么最好还是使用它,因为它可能比 php 5.5 更稳定。
如果你需要php 5.5 查看是否有支持 php5.5 的 phpmyadmin 的新版本,不过它可能不在存储库中,您可能必须从源代码构建。抱歉,我没有全部答案,我只是看到了一个看似明显的问题,并想指出它。您可以执行以下操作:
yum provides phpmyadmin
这应该会向您显示您安装的 repos 中有哪些选项,如果您尚未在 /etc/yum.repo.d/conf 文件中将它们设置为启用,则可能需要添加 enable repo 命令(假设它们还没有在 CentOS 7 中移动 - 我还没有尝试过)。
我希望这能有所帮助!