我已阅读并遵循这个问题无济于事。我试图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
这种错误消息通常表示正在安装的软件包与其他已安装的软件包冲突,并且会强制删除其他依赖软件包。当同时为多个体系结构安装同一个软件包时(请参阅多架构),amd64
在i386
这种情况下,要安装的软件包的版本必须匹配确切地。
在这种情况下可能发生的情况(我们在评论中的讨论证实了这一点)是libssl1.0.0
升级到比 Ubuntu 存储库中任何可用版本都新的 PPA 版本。如果后来禁用或取消配置了 PPA,则通常会保留较新的软件包。阅读这个问题了解禁用和清除 PPA 之间的区别。但是,如果您已经从 apt 配置中删除了 PPA,则需要手动降级之前从 PPA 升级的软件包。
为了能够安装,您必须从存储库安装libssl1.0.0:i386
相同版本的。并且由于源包会构建多个相关的二进制包,因此您必须确保其所有包也都为同一版本。如果您未指定要降级的所有包,apt 将倾向于卸载而不是降级。在这种情况下,如果您从 PPA 安装了、和 ,则应该libssl1.0.0:amd64
openssl
libssl1.0.0
libssl-dev
openssl
sudo apt-get install libssl1.0.0/trusty libssl-dev/trusty openssl/trusty
对于关于降级软件包的提示,回答“是” apt-get
。您现在应该能够libssl1.0.0:i386
从存储库安装该软件包。
答案3
这是因为未安装 Web 套接字库。尝试运行
sudo apt-get install libwebsockets-dev
跑步前
sudo apt-get install mosquitto
答案4
我来这里是为了尝试在 Debian 9 Strel 上安装官方的 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 就安装好了。希望对您有所帮助。