我正在尝试使用命令升级我的 20.04 do-release-upgrade
。上面给我的消息是我需要在升级之前安装所有可用的更新。
如果我然后运行sudo apt update && sudo apt upgrade
它会给我错误The following packages have been kept back: libheif1
我的下一步是sudo apt install --only-upgrade libheif1
这给了我
The following packages have unmet dependencies:
libheif1 : Depends: libheif-plugin-dav1d (= 1.17.6-1~20.04.sav0) but it is not going to be installed or
libheif-plugin-aomdec (= 1.17.6-1~20.04.sav0) but it is not going to be installed
Recommends: libheif-plugin-aomenc (= 1.17.6-1~20.04.sav0) but it is not going to be installed
这就是我陷入困境的地方。我似乎可以找到一种方法来安装这些软件包中的任何一个。
我如何从这里继续?可以卸载libheif1吗?
更新:
apt policy libheif1
libheif1:
Installed: 1.6.1-1build1
Candidate: 1.17.6-1~20.04.sav0
Version table:
1.17.6-1~20.04.sav0 500
500 http://ppa.launchpad.net/savoury1/digikam/ubuntu focal/main amd64 Packages
*** 1.6.1-1build1 500
500 http://archive.ubuntu.com/ubuntu focal/universe amd64 Packages
100 /var/lib/dpkg/status
sudo apt update
[sudo] password for tigre:
Hit:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://security.ubuntu.com/ubuntu focal-security InRelease
Hit:3 http://ppa.launchpad.net/atareao/atareao/ubuntu focal InRelease
Hit:4 http://ppa.launchpad.net/obsproject/obs-studio/ubuntu focal InRelease
Hit:5 http://ppa.launchpad.net/pipewire-debian/pipewire-upstream/ubuntu focal InRelease
Hit:6 http://ppa.launchpad.net/savoury1/digikam/ubuntu focal InRelease
Get:7 https://mega.nz/linux/repo/xUbuntu_20.04 ./ InRelease [2,961 B]
Hit:8 http://archive.ubuntu.com/ubuntu focal InRelease
Hit:9 http://archive.canonical.com/ubuntu focal InRelease
Get:10 http://archive.ubuntu.com/ubuntu focal-updates InRelease [114 kB]
Hit:11 http://archive.canonical.com focal InRelease
Hit:12 https://repo.fortinet.com/repo/forticlient/7.2/ubuntu /stable InRelease
Hit:13 https://repo.fortinet.com/repo/7.0/ubuntu /bionic InRelease
Fetched 117 kB in 1s (83.6 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
3 packages can be upgraded. Run 'apt list --upgradable' to see them.
运行以下命令来查找哪些包具有 libheif1 作为依赖项。
将结果保存
apt-cache rdepends libheif1
在文本文件中。如果您在保存的软件包列表上运行以下形式的命令apt policy <packagename>
,它将告诉您安装了哪些软件包。如果卸载这些软件包以及 libheif1,您将能够从 Ubuntu 20.04 升级到 Ubuntu 22.04。libheif 是 ISO/IEC 23008-12:2017 HEIF 文件格式解码器。HEIF 是一种新的图像文件格式,采用 HEVC (h.265) 图像编码,以实现当前可能的最佳压缩比。
升级到 Ubuntu 22.04 后,您将能够重新安装为了升级而卸载的任何软件包。
进一步的重要建议是您还收到一条
unmet dependencies
错误消息。此错误表明您的系统上的包管理存在问题。因此,在升级到 Ubuntu 22.04 后,您应该小心不要卸载太多软件包,因为如果这样做,您可能无法重新安装它们。