无法在 CentOS 5.6 上安装 php-posix 包

无法在 CentOS 5.6 上安装 php-posix 包

我在我的 CentOS 5.6 主机上安装了以下 PHP 软件包,并且我正在尝试安装php-posix.当我运行时,yum install php-posix我收到一条错误,指出php53-commonphp-common.

[root@dev ~]# yum list installed | grep php
php.x86_64                               5.3.10-1.w5                   installed
php-cli.x86_64                           5.3.10-1.w5                   installed
php-common.x86_64                        5.3.10-1.w5                   installed
php-devel.x86_64                         5.3.10-1.w5                   installed
php-gd.x86_64                            5.3.10-1.w5                   installed
php-ldap.x86_64                          5.3.10-1.w5                   installed
php-mcrypt.x86_64                        5.3.10-1.w5                   installed
php-mysql.x86_64                         5.3.10-1.w5                   installed
php-pdo.x86_64                           5.3.10-1.w5                   installed
php-pear.noarch                          1:1.9.4-1.w5                  installed
php-soap.x86_64                          5.3.10-1.w5                   installed
php-xml.x86_64                           5.3.10-1.w5                   installed


[root@dev ~]# yum install php-posix
Loaded plugins: fastestmirror
Loading mirror speeds from cached hostfile
 * base: mirror.krystal.co.uk
 * epel: ftp.uni-koeln.de
 * extras: mirror.krystal.co.uk
 * rpmforge: mirror.nl.leaseweb.net
 * updates: mirror.krystal.co.uk
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package php53-process.x86_64 0:5.3.3-7.el5_8 set to be updated
--> Processing Dependency: php53-common = 5.3.3-7.el5_8 for package: php53-process
--> Running transaction check
---> Package php53-common.x86_64 0:5.3.3-7.el5_8 set to be updated
--> Processing Conflict: php53-common conflicts php-common
--> Finished Dependency Resolution
php53-common-5.3.3-7.el5_8.x86_64 from updates has depsolving problems
  --> php53-common conflicts with php-common
Error: php53-common conflicts with php-common
 You could try using --skip-broken to work around the problem
 You could try running: package-cleanup --problems
                        package-cleanup --dupes
                        rpm -Va --nofiles --nodigest
The program package-cleanup is found in the yum-utils package.

是什么阻止我安装php-posix

答案1

该错误是由于php-common53包与已安装的包冲突引起的php-common。该php-common53软件包的版本是 5.3.3,而安装的php软件包是 5.3.10。安装的php软件包可能来自 EPEL 或 RPMForge 存储库。你可以通过运行找出来yum info php

您必须删除php-common和依赖包,然后安装php53-common.如果存储库中没有对应的 PHP 软件包,您可能会丢失当前安装的一些 PHP 软件包。

# yum remove  php php-cli php-common php-devel php-gd php-ldap php-mcrypt php-mysql php-pdo php-pear php-soap php-xml

安装时,会自动安装和php-posix等依赖包。php53php53-common

# yum install php-posix

您应该意识到,如果您不小心,启用 EPEL 和 RPMForge 存储库中的一个或两个可能会导致问题。熟悉yum命令(例如 --enablerepo 和 --disablerepo)和一些可用插件(yum-plugin-protect-packages 和 yum-plugin-protectbase),以帮助管理软件并保持存储库正常运行。

答案2

我已经得到了解决方案,我所做的是:

yum install php-process --enablerepo=webtatic

虽然,它把我所有的 PHP 包更新到了​​ 5.3.13

相关内容