Score:0

Upgrade Ubuntu 20.04 to 22.04 fails; too many broken packages reported

co flag

I was upgrading my initial Ubuntu 18.04 installation to 20.04 without any issues. sudo apt upgrade does not report any outstanding packages. However, trying to upgrade to 22.04 with sudo do-release-upgrade fails:

...
Calculating the changes

Could not determine the upgrade

An unresolvable problem occurred while calculating the upgrade.

This was likely caused by:
* Unofficial software packages not provided by Ubuntu
Please use the tool 'ppa-purge' from the ppa-purge
package to remove software from a Launchpad PPA and
try the upgrade again.

If none of this applies, then please report this bug using the
command 'ubuntu-bug ubuntu-release-upgrader-core' in a terminal. If
you want to investigate this yourself the log files in
'/var/log/dist-upgrade' will contain details about the upgrade.
Specifically, look at 'main.log' and 'apt.log'.


Restoring original system state

Aborting
...

Looking into apt.log with $ cat /var/log/dist-upgrade/apt.log | grep roken reports tons of broken packages (this is just an excerpt):

Starting pkgProblemResolver with broken count: 54
Starting 2 pkgProblemResolver with broken count: 54
Broken libapparmor1:amd64 Breaks on libapparmor-perl:amd64 < 2.13.3-7ubuntu5.1 @ii mK Ib > (< 3.0.3-3)
Broken gnome-settings-daemon:amd64 Breaks on libmutter-6-0:amd64 < 3.36.9-0ubuntu0.20.04.2 @ii mK > (< 3.37)
Broken gnome-shell:amd64 Breaks on gnome-shell-extension-desktop-icons:amd64 < 20.04.0-3~ubuntu20.04.6 @ii mK > (< 21.04)
Broken libgcc1:amd64 Depends on gcc-11-base:amd64 < 11.1.0-1ubuntu1~18.04.1 -> 11.3.0-1ubuntu1~22.04 @ii umU > (= 11.1.0-1ubuntu1~18.04.1)
Broken fuse3:amd64 Breaks on fuse:amd64 < 2.9.9-3 -> 2.9.9-5ubuntu3 @ii umU >
Broken qtbase5-dev:amd64 Breaks on qt5-default:amd64 < 5.12.8+dfsg-0ubuntu2.1 @ii mK Ib > (< 5.15.1+dfsg-2~)
Broken libayatana-appindicator3-1:amd64 Conflicts on libappindicator3-1:amd64 < 12.10.1+20.04.20200408.1-0ubuntu1 -> 12.10.1+20.10.20200706.1-0ubuntu1 @ii umU >
Broken gir1.2-unity-7.0:amd64 Conflicts on gir1.2-unity-5.0:amd64 < 7.1.4+19.04.20190319-0ubuntu3 @ii mK >
Broken usrmerge:amd64 Conflicts on libpng12-0:amd64 < 1.2.54-1ubuntu1.1 @ii mK > (< 1.2.54-4~)
Broken libobjc4:amd64 Depends on libgc1:amd64 < none | 1:8.0.6-1.1build1 @un uH > (>= 1:7.2d)
Broken libnfsidmap1:amd64 Conflicts on libnfsidmap2:amd64 < 0.25-5.1ubuntu1 @ii mK Ib >
Broken libnfsidmap1:amd64 Breaks on libnfsidmap2:amd64 < 0.25-5.1ubuntu1 @ii mK Ib > (< 0.25-7~)
Broken libtss2-esys-3.0.2-0:amd64 Breaks on libtss2-esys0:amd64 < 2.3.2-1ubuntu0.20.04.1 @ii mK > (< 3.0.2-1)
Broken php-common:amd64 Breaks on php7.0-common:amd64 < 7.0.33-0ubuntu0.16.04.16 @ii mK >
Broken qemu-system-x86:amd64 Breaks on qemu-kvm:amd64 < 1:4.2-3ubuntu6.23 @ii mK Ib >
Broken guile-2.2-libs:amd64 Depends on libgc1:amd64 < none | 1:8.0.6-1.1build1 @un uH > (>= 1:7.4.2)
Broken libboost1.74-dev:amd64 Conflicts on libboost1.71-dev:amd64 < 1.71.0-6ubuntu6 @ii mK >
Broken xfce4-helpers:amd64 Breaks on libexo-helpers:amd64 < 0.12.11-1ubuntu1.20.04.1 @ii mK >
Broken libgupnp-av-1.0-3:amd64 Breaks on libgupnp-av-1.0-2:amd64 < 0.12.11-2 @ii mK > (< 0.14)
Broken libobjc-9-dev:amd64 Depends on libobjc4:amd64 < 11.1.0-1ubuntu1~18.04.1 | 12.1.0-2ubuntu1~22.04 @ii umR > (>= 9.5.0-1ubuntu1~22.04)
Broken libobjc-5-dev:amd64 Depends on libobjc4:amd64 < 11.1.0-1ubuntu1~18.04.1 | 12.1.0-2ubuntu1~22.04 @ii umR > (>= 5.5.0-12ubuntu1)
Broken libsepol-dev:amd64 Breaks on libsepol1-dev:amd64 < 3.0-1ubuntu0.1 @ii mK Ib > (< 3.2)
...

What does this messages tell me ? Are there some remainder from Ubuntu 18.04 which were not / couldn't get updated ? How do I resolve that ?

I tried all those suggestions with sudo apt install -f or sudo dpkg --configure -a without success.

I'm stuck and would need some help on how to get out of that to upgrade to 22.04, please. Thanks

Mochan avatar
kr flag
Have you tried `ppa-purge` as it recommends to remove 3rd-party ppas? Note that removing them will also remove the package associated, but you can note them down and install them again later.
MlaKe avatar
co flag
I only have vscode as separate ppa (in `/etc/apt/source.list.d/`. I also did the upgrade 18 -> 20 -> 22 on a 2nd machine without any issues and even more ppa's
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.