由於「未滿足的依賴關係」而無法安裝 libssl1.0.0:i386?

由於「未滿足的依賴關係」而無法安裝 libssl1.0.0:i386?

我已閱讀並遵循中的建議這個問題無濟於事。我嘗試libssl1.0.0:i386在我的 14.04 機器 (amd64) 上安裝,但是當我嘗試透過 APT 執行此操作時,我收到以下錯誤訊息:

nathan@nathan-desktop:~$ sudo apt-get install libssl1.0.0:i386
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help resolve the situation:

The following packages have unmet dependencies:
 default-jre-headless : Depends: openjdk-7-jre-headless (>= 7~u3-2.1.1) but it is not going to be installed
 openjdk-7-jre : Depends: openjdk-7-jre-headless (= 7u55-2.4.7-1ubuntu1) but it is not going to be installed
                 Recommends: libgnome2-0 but it is not going to be installed
                 Recommends: libgnomevfs2-0 but it is not going to be installed
 openssh-client : Depends: libssl1.0.0 (>= 1.0.1) but it is not going to be installed
 openssh-server : Depends: libssl1.0.0 (>= 1.0.1) but it is not going to be installed
                  Depends: openssh-sftp-server but it is not going to be installed
                  Recommends: ssh-import-id but it is not going to be installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused by held packages.

我已安裝所有最新更新。我跑了apt-get -f install。我已確保在軟體來源中啟用所有儲存庫。

可能是什麼原因造成的?


更新:

以下是 的內容apt-cache policy libssl1.0.0

libssl1.0.0:
  Installed: 1.0.1g-1ppa1~trusty1
  Candidate: 1.0.1g-1ppa1~trusty1
  Version table:
 *** 1.0.1g-1ppa1~trusty1 0
        100 /var/lib/dpkg/status
     1.0.1f-1ubuntu2.1 0
        500 http://ca.archive.ubuntu.com/ubuntu/ trusty-updates/main amd64 Packages
        500 http://security.ubuntu.com/ubuntu/ trusty-security/main amd64 Packages
     1.0.1f-1ubuntu2 0
        500 http://ca.archive.ubuntu.com/ubuntu/ trusty/main amd64 Packages

....和apt-cache policy libssl1.0.0:i386

libssl1.0.0:i386:
  Installed: (none)
  Candidate: 1.0.1f-1ubuntu2.1
  Version table:
     1.0.1f-1ubuntu2.1 0
        500 http://ca.archive.ubuntu.com/ubuntu/ trusty-updates/main i386 Packages
        500 http://security.ubuntu.com/ubuntu/ trusty-security/main i386 Packages
     1.0.1f-1ubuntu2 0
        500 http://ca.archive.ubuntu.com/ubuntu/ trusty/main i386 Packages

答案1

我使用的是 Ubuntu 20.04,以下步驟對我有用:

使用新增 18.04 的主儲存庫

echo "deb http://security.ubuntu.com/ubuntu bionic-security main" | sudo tee -a /etc/apt/sources.list.d/bionic.list

更新儲存庫快取並檢查 libssl1.0-dev 現在是否可用。

sudo apt update
apt-cache policy libssl1.0-dev

安裝 libssl1.0-dev。

sudo apt-get install libssl1.0-dev 

答案2

此類錯誤訊息通常表示正在安裝的軟體包與其他已安裝的軟體包發生衝突,並且會強制刪除其他依賴套件。同時為多個架構安裝相同的軟體包時(請參閱多架構),amd64i386這種情況下,要安裝的軟體包的版本必須匹配確切地

在這種情況下可能發生的情況(我們在評論中的討論證實了這一點)是libssl1.0.0升級到的 PPA 版本比 Ubuntu 儲存庫中可用的任何版本都要新。如果後來停用或取消配置 PPA,通常會保留較新的軟體包。讀這個問題了解停用和清除 PPA 之間的差異。但是,如果您已經從 apt 配置中刪除了 PPA,則需要手動降級先前從 PPA 升級的軟體包。

為了能夠安裝,您必須從儲存庫安裝libssl1.0.0:i386相同的版本。libssl1.0.0:amd64並且由於openssl來源包建置了多個相關的二進位包,因此您必須確保其所有包也處於同一版本。如果您沒有指定要降級的所有軟體包,apt 會選擇卸載而不是降級。在這種情況下,如果您有libssl1.0.0libssl-dev、 和openssl透過 PPA 安裝,您應該

sudo apt-get install libssl1.0.0/trusty libssl-dev/trusty openssl/trusty

apt-get對降級軟體包的提示回答「是」 。您現在應該能夠libssl1.0.0:i386從儲存庫安裝該套件。

答案3

這是因為沒有安裝web socket庫。嘗試跑步

sudo apt-get install libwebsockets-dev

跑步前

sudo apt-get install mosquitto

答案4

我到達這裡嘗試在 debian 9stretch 上安裝官方 mongodb-org。但我遇到了與你類似的錯誤:

user@debian:~/folder$ sudo apt-get install -y mongodb-org
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 mongodb-org : Depends: mongodb-org-shell but it is not going to be installed
               Depends: mongodb-org-server but it is not going to be installed
               Depends: mongodb-org-mongos but it is not going to be installed
               Depends: mongodb-org-tools but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

並嘗試一一安裝軟體包:

user@debian:~/folder$ sudo apt-get install -y mongodb-org-tools 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 mongodb-org-tools : Depends: libssl1.0.0 (>= 1.0.1) but it is not installable
E: Unable to correct problems, you have held broken packages.

我在下一篇文章中找到了我的解決方案: https://linuxconfig.org/how-to-install-spotify-on-debian-9-stretch-linux

它只安裝舊的 ssl 套件:

$ wget http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u6_amd64.deb
$ sudo dpkg -i libssl1.0.0_1.0.1t-1+deb8u6_amd64.deb

這樣做之後,mongodb-org就安裝好了。希望您會發現它有幫助。

相關內容