CentOS下安装php gd库报错Error: php56w-common conflicts with php-common-5.3.3-48.el6_8.x86_64

因为服务器缺少php gd库,因为系统是centos,就是用yum去安装,一安装就报错如下:

[root@iZ28sdxghs2Z ~]# yum install php-gd

Loaded plugins: security
Setting up Install Process
Repository base is listed more than once in the configuration
Repository updates is listed more than once in the configuration
Repository extras is listed more than once in the configuration
Repository centosplus is listed more than once in the configuration
Repository contrib is listed more than once in the configuration
base                                                                                   | 3.7 kB     00:00     
extras                                                                                 | 3.4 kB     00:00     
updates                                                                                | 3.4 kB     00:00     
updates/primary_db                                                                     | 3.1 MB     00:00     
webtatic                                                                               | 3.6 kB     00:00     
Resolving Dependencies
--> Running transaction check
---> Package php-gd.x86_64 0:5.3.3-48.el6_8 will be installed
--> Processing Dependency: php-common(x86-64) = 5.3.3-48.el6_8 for package: php-gd-5.3.3-48.el6_8.x86_64
--> Processing Dependency: libXpm.so.4()(64bit) for package: php-gd-5.3.3-48.el6_8.x86_64
--> Running transaction check
---> Package libXpm.x86_64 0:3.5.10-2.el6 will be installed
---> Package php-common.x86_64 0:5.3.3-48.el6_8 will be installed
--> Processing Conflict: php56w-common-5.6.22-1.w6.x86_64 conflicts php-common < 5.5.0
--> Restarting Dependency Resolution with new changes.
--> Running transaction check
---> Package php56w-common.x86_64 0:5.6.22-1.w6 will be updated
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-mbstring-5.6.22-1.w6.x86_64
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-pdo-5.6.22-1.w6.x86_64
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-fpm-5.6.22-1.w6.x86_64
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-5.6.22-1.w6.x86_64
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-cli-5.6.22-1.w6.x86_64
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-xml-5.6.22-1.w6.x86_64
--> Processing Dependency: php56w-common(x86-64) = 5.6.22-1.w6 for package: php56w-process-5.6.22-1.w6.x86_64
---> Package php56w-common.x86_64 0:5.6.26-1.w6 will be an update
--> Running transaction check
---> Package php56w.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-cli.x86_64 0:5.6.22-1.w6 will be updated
--> Processing Dependency: php56w-cli(x86-64) = 5.6.22-1.w6 for package: php56w-devel-5.6.22-1.w6.x86_64
---> Package php56w-cli.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-fpm.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w-fpm.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-mbstring.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w-mbstring.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-pdo.x86_64 0:5.6.22-1.w6 will be updated
--> Processing Dependency: php56w-pdo(x86-64) = 5.6.22-1.w6 for package: php56w-odbc-5.6.22-1.w6.x86_64
---> Package php56w-pdo.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-process.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w-process.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-xml.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w-xml.x86_64 0:5.6.26-1.w6 will be an update
--> Running transaction check
---> Package php56w-devel.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w-devel.x86_64 0:5.6.26-1.w6 will be an update
---> Package php56w-odbc.x86_64 0:5.6.22-1.w6 will be updated
---> Package php56w-odbc.x86_64 0:5.6.26-1.w6 will be an update
--> Processing Conflict: php56w-common-5.6.26-1.w6.x86_64 conflicts php-common < 5.6
--> Finished Dependency Resolution
Error: php56w-common conflicts with php-common-5.3.3-48.el6_8.x86_64
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest

大概的意思是错误:php56w-common与php-common-5.3.3-48.el6_8.x86_64冲突

后来phpinfo看了一下php版本,如下图:

那如何解决呢?

答案就是使用    yum install php56w-gd  安装,ok 问题解决,记录一下。

转载于:https://www.cnblogs.com/jian-ge/p/9437852.html

  • 2
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值