簡體   English   中英

在 Centos 7.8 上安裝 php 7.4 的包錯誤問題

[英]Package erros problem with php 7.4 install on Centos 7.8

我在 Centos 7.8 和 PHP7 上遇到了問題 我已經瀏覽了 Stack Overlfow 並找到了一些類似的帖子,但沒有得到我的問題的答案。 我有 php 5.6,當我嘗試安裝 php 74 時,出現以下錯誤。 我試過安裝必需的文件,但它只是拋出另一個錯誤,說它需要相同的文件。

錯誤:

Package: php-mcrypt-7.1.33-10.el7.remi.x86_64 (remi-php71)
           Requires: php-common(x86-64) = 7.1.33-10.el7.remi
           Removing: php-common-5.6.40-23.el7.remi.x86_64 (@remi-php56)
               php-common(x86-64) = 5.6.40-23.el7.remi
           Updated By: php-common-7.4.12-1.el7.remi.x86_64 (remi-php74)
               php-common(x86-64) = 7.4.12-1.el7.remi
           Available: php-common-5.4.16-48.el7.x86_64 (base)
               php-common(x86-64) = 5.4.16-48.el7
           Available: php-common-5.4.45-18.el7.remi.x86_64 (remi)
               php-common(x86-64) = 5.4.45-18.el7.remi
           Available: php-common-5.6.40-22.el7.remi.x86_64 (remi-php56)
               php-common(x86-64) = 5.6.40-22.el7.remi
           Available: php-common-7.1.33-9.el7.remi.x86_64 (remi-php71)
               php-common(x86-64) = 7.1.33-9.el7.remi
           Available: php-common-7.1.33-10.el7.remi.x86_64 (remi-php71)
               php-common(x86-64) = 7.1.33-10.el7.remi
           Available: php-common-7.2.33-1.el7.remi.x86_64 (remi-php72)
               php-common(x86-64) = 7.2.33-1.el7.remi
           Available: php-common-7.2.34-1.el7.remi.x86_64 (remi-php72)
               php-common(x86-64) = 7.2.34-1.el7.remi
           Available: php-common-7.3.23-1.el7.remi.x86_64 (remi-php73)
               php-common(x86-64) = 7.3.23-1.el7.remi
           Available: php-common-7.3.24-1.el7.remi.x86_64 (remi-php73)
               php-common(x86-64) = 7.3.24-1.el7.remi
           Available: php-common-7.4.11-1.el7.remi.x86_64 (remi-php74)
               php-common(x86-64) = 7.4.11-1.el7.remi
Error: Package: php-recode-7.3.24-1.el7.remi.x86_64 (remi-php73)
           Requires: php-common(x86-64) = 7.3.24-1.el7.remi
           Removing: php-common-5.6.40-23.el7.remi.x86_64 (@remi-php56)
               php-common(x86-64) = 5.6.40-23.el7.remi
           Updated By: php-common-7.4.12-1.el7.remi.x86_64 (remi-php74)
               php-common(x86-64) = 7.4.12-1.el7.remi
           Available: php-common-5.4.16-48.el7.x86_64 (base)
               php-common(x86-64) = 5.4.16-48.el7
           Available: php-common-5.4.45-18.el7.remi.x86_64 (remi)
               php-common(x86-64) = 5.4.45-18.el7.remi
           Available: php-common-5.6.40-22.el7.remi.x86_64 (remi-php56)
               php-common(x86-64) = 5.6.40-22.el7.remi
           Available: php-common-7.1.33-9.el7.remi.x86_64 (remi-php71)
               php-common(x86-64) = 7.1.33-9.el7.remi
           Available: php-common-7.1.33-10.el7.remi.x86_64 (remi-php71)
               php-common(x86-64) = 7.1.33-10.el7.remi
           Available: php-common-7.2.33-1.el7.remi.x86_64 (remi-php72)
               php-common(x86-64) = 7.2.33-1.el7.remi
           Available: php-common-7.2.34-1.el7.remi.x86_64 (remi-php72)
               php-common(x86-64) = 7.2.34-1.el7.remi
           Available: php-common-7.3.23-1.el7.remi.x86_64 (remi-php73)
               php-common(x86-64) = 7.3.23-1.el7.remi
           Available: php-common-7.3.24-1.el7.remi.x86_64 (remi-php73)
               php-common(x86-64) = 7.3.24-1.el7.remi
           Available: php-common-7.4.11-1.el7.remi.x86_64 (remi-php74)
               php-common(x86-64) = 7.4.11-1.el7.remi

似乎您啟用了各種 php 存儲庫(remi-php71、remi-php72...),只保留您想要的一個

正如向導所解釋的

yum-config-manager --disable 'remi-php*'
yum-config-manager --enable   remi-php74

包:php-mcrypt-7.1.33-10.el7.remi.x86_64 (remi-php71)

mcrypt擴展已棄用並已從PHP 7.2 中刪除

另請閱讀: 關於 libmcrypt 和 php-mcrypt

錯誤:包:php-recode-7.3.24-1.el7.remi.x86_64 (remi-php73)

不推薦使用重新編碼擴展並已從PHP 7.4 中刪除

所以你必須在升級前刪除這些擴展,如果你“真的”需要它們,你就不能升級。

yum remove php-recode php-mcrypt

注意: php-pecl-mcrypt 和 php-pecl-recode 可用於遺留應用程序,但不鼓勵並且不支持。

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM