2017-04-27 21 views
0

我試圖更新我的PHP,但當我用的yum更新PHP的,這就是我的了:嘗試更新從5.4 PHP 5.6在CentOS 7 - 得到一個錯誤(和網站下載下來的現在)

Error: Package: gd-last-2.2.4-1.el6.remi.x86_64 (remi) 
      Requires: libwebp.so.5()(64bit) 
Error: Package: php-mysql-5.4.45-13.el6.remi.x86_64 (remi) 
      Requires: php-pdo(x86-64) = 5.4.45-13.el6.remi 
      Removing: php-pdo-5.4.16-42.el7.x86_64 (@base) 
       php-pdo(x86-64) = 5.4.16-42.el7 
      Updated By: php-pdo-5.6.30-1.el6.remi.x86_64 (remi-php56) 
       php-pdo(x86-64) = 5.6.30-1.el6.remi 
      Available: php-pdo-5.4.45-13.el6.remi.x86_64 (remi) 
       php-pdo(x86-64) = 5.4.45-13.el6.remi 
      Available: php-pdo-5.6.29-1.el6.remi.x86_64 (remi-php56) 
       php-pdo(x86-64) = 5.6.29-1.el6.remi 
Error: Package: php-5.6.30-1.el6.remi.x86_64 (remi-php56) 
      Requires: httpd-mmn = 20051115 
      Installed: httpd-2.4.6-40.el7.centos.4.x86_64 (@updates) 
       httpd-mmn = 20120211 
       httpd-mmn = 20120211x8664 
       httpd-mmn = 20120211-x86-64 
      Available: httpd-2.4.6-45.el7.centos.x86_64 (base) 
       httpd-mmn = 20120211x8664 
       httpd-mmn = 20120211-x86-64 
       httpd-mmn = 20120211 
      Available: httpd-2.4.6-45.el7.centos.4.x86_64 (updates) 
       httpd-mmn = 20120211x8664 
       httpd-mmn = 20120211-x86-64 
       httpd-mmn = 20120211 
You could try using --skip-broken to work around the problem 
You could try running: rpm -Va --nofiles --nodigest 

我試過使用--skip-broken,然後重新啓動,但我的版本沒有幫助。我搜索了這個網站,發現了一個我遵循的線程(Can't install PHP Package on CentOS)。

基本上這是我第一次輸入:

yum install epel-release 
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm 
yum clean 
yum update 

得到了完全同樣的錯誤之前,(所以我想它什麼也沒做)。然後,我這樣做:

yum update -y; yum remove httpd && yum install httpd; yum install php56w-common php56w-opcache php56w-mysql 

這是我得到的錯誤(所以我雖然部分問題已經解決):

Error: Package: gd-last-2.2.4-1.el6.remi.x86_64 (remi) 
      Requires: libwebp.so.5()(64bit) 
You could try using --skip-broken to work around the problem 
You could try running: rpm -Va --nofiles --nodigest 

但是爲了以防萬一,我訪問了我的網站,現在我得到一個502錯誤:(:( - 我甚至不能連接到Sentora(我已經安裝)。當我嘗試重新安裝sentora(這樣它可能會修復它),它說它需要一個乾淨的服務器,因爲mariadb是已經安裝!! 請幫幫我!!

關於

回答

0

Error: Package: php-5.6.30-1.el6.remi.x86_64 (remi-php56) Requires: httpd-mmn = 20051115 Installed: httpd-2.4.6-40.el7.centos.4.x86_64 (@updates)

你顯然是一個錯誤的配置,CentOS的7服務器上混合爲CentOS 6倉庫。

所以,去掉不好安裝的軟件包:

yum remove remi-release epel-release webtatic-release 
yum clean all 

然後,看到了configuration wizard並安裝正確的配置包雷米和EPEL存儲庫。

0

您可以檢查/etc/yum.conf文件,查看是否從更新中排除了httpd和/或httpd *軟件包。如果是,請修改yum.conf排除行併除去httpd *包,運行「yum clean all」,然後嘗試再次更新PHP。

相關問題