Score:0

Unable to upgrade to the next version (22.04) Due to Dependency issue(s)

iq flag

Before I layout the problem, this is my current system info.

➜  ~ lsb_release -a      
No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 20.04.5 LTS
Release:    20.04
Codename:   focal
➜  ~ uname -r
5.15.0-67-generic

When I try to upgrade the distro by running

sudo do-release-upgrade -d

I get the message

Checking for a new Ubuntu release
Please install all available updates for your release before upgrading.

I did sudo apt update && sudo apt upgrade -y and find that there is a package that be upgraded but not upgraded.

1 package can be upgraded. Run 'apt list --upgradable' to see it.
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Calculating upgrade... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

Next, I did sudo apt list --upgradable -a and get that

Listing... Done
libcurl3-gnutls/focal 7.87.0-1~20.04.sav0 amd64 [upgradable from: 7.68.0-1ubuntu2.16]
libcurl3-gnutls/focal-updates,focal-security,now 7.68.0-1ubuntu2.16 amd64 [installed,upgradable to: 7.87.0-1~20.04.sav0]
libcurl3-gnutls/focal 7.68.0-1ubuntu2 amd64

When I tried to install by doing sudo apt-get install libcurl3-gnutls, I get the following error

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:
 libcurl3-gnutls : Depends: libgnutls30 (>= 3.7.2) but 3.6.13-2ubuntu1.8 is to be installed
E: Unable to correct problems, you have held broken packages.

I've found similar questions and answers here and tried all the answers but it's still not resolved yet. This are a few commands I tried.

➜  ~ sudo apt-get install -f libcurl3-gnutls
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:
 libcurl3-gnutls : Depends: libgnutls30 (>= 3.7.2) but 3.6.13-2ubuntu1.8 is to be installed
E: Unable to correct problems, you have held broken packages.
➜  ~ sudo apt-get install -f libgnutls30               
Reading package lists... Done
Building dependency tree       
Reading state information... Done
libgnutls30 is already the newest version (3.6.13-2ubuntu1.8).
0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded.

One last thing, when I tried with aptitude tho, there are a bit more info but seems risky so I didn't proceed further (check the second step).

sudo aptitude install libcurl3-gnutls 
The following packages will be upgraded: 
  libcurl3-gnutls{b} 
1 packages upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Need to get 382 kB of archives. After unpacking 123 kB will be used.
The following packages have unmet dependencies:
 libcurl3-gnutls : Depends: libgnutls30 (>= 3.7.2) but 3.6.13-2ubuntu1.8 is installed
The following actions will resolve these dependencies:

     Keep the following packages at their current version:                      
1)     libcurl3-gnutls [7.68.0-1ubuntu2.16 (focal-security, focal-updates, now)]


Accept this solution? [Y/n/q/?] 
The following actions will resolve these dependencies:

      Remove the following packages:                                                        
1)      colord [1.4.4-2 (focal, now)]                                                       
2)      fwupd [1.7.9-1~20.04.2 (focal-proposed, now)]                                       
3)      gir1.2-vips-8.0 [8.10.5-2ubuntu1tonimelisma2 (focal, now)]                          
4)      git [1:2.25.1-1ubuntu3.10 (focal-security, focal-updates, now)]                     
5)      gnome-control-center [1:3.36.5-0ubuntu4 (focal-updates, now)]                       
6)      hplip [3.20.3+dfsg0-2 (focal, now)]                                                 
7)      kerneloops [0.12+git20140509-6ubuntu2 (focal, now)]                                 
8)      libcfitsio-dev [3.470-3 (focal, now)]                                               
9)      libcfitsio8 [3.470-3 (focal, now)]                                                  
10)     libcurl3-gnutls [7.68.0-1ubuntu2.16 (focal-security, focal-updates, now)]           
11)     libfwupd2 [1.7.9-1~20.04.2 (focal-proposed, now)]                                   
12)     libfwupdplugin5 [1.7.9-1~20.04.2 (focal-proposed, now)]                             
13)     libsane [1.0.29-0ubuntu5.2 (focal-updates, now)]                                    
14)     libvips-dev [8.10.5-2ubuntu1tonimelisma2 (focal, now)]                              
15)     libvips-tools [8.10.5-2ubuntu1tonimelisma2 (focal, now)]                            
16)     libvips42 [8.10.5-2ubuntu1tonimelisma2 (focal, now)]                                
17)     network-manager [1.22.10-1ubuntu2.3 (focal-updates, now)]                           
18)     network-manager-config-connectivity-ubuntu [1.22.10-1ubuntu2.3 (focal-updates, now)]
19)     network-manager-gnome [1.8.24-1ubuntu3 (focal-updates, now)]                        
20)     network-manager-openvpn [1.8.12-1 (focal, now)]                                     
21)     network-manager-openvpn-gnome [1.8.12-1 (focal, now)]                               
22)     network-manager-pptp [1.2.8-2 (focal, now)]                                         
23)     network-manager-pptp-gnome [1.2.8-2 (focal, now)]                                   
24)     network-manager-strongswan [1.4.5-2.1 (focal, now)]                                 
25)     nip2 [8.7.0-1 (focal, now)]                                                         
26)     sane-utils [1.0.29-0ubuntu5.2 (focal-updates, now)]                                 
27)     spotify-client [1:1.1.84.716.gc5f8b819-2 (now, stable)]                             
28)     tig [2.4.1-1ubuntu1 (focal, now)]                                                   
29)     ubuntu-desktop [1.450.2 (focal-updates, now)]                                       
30)     ubuntu-desktop-minimal [1.450.2 (focal-updates, now)]                               
31)     whoopsie [0.2.69ubuntu0.3 (focal-security, focal-updates, now)]                     

      Leave the following dependencies unresolved:                                          
32)     cups-filters recommends colord                                                      
33)     libcolord-gtk1 recommends colord                                                    
34)     libsane-hpaio recommends hplip (= 3.20.3+dfsg0-2)                                   
35)     libsane-hpaio recommends sane-utils                                                 
36)     cups recommends colord                                                              
37)     cups-daemon recommends colord                                                       
38)     fwupd-signed recommends fwupd                             
...

Now I am stuck and not sure how to resolve the whole mess.

Update

Output of the apt-cache

➜  ~ sudo apt-cache policy libcurl3-gnutls libgnutls30 
libcurl3-gnutls:
  Installed: (none)
  Candidate: 7.87.0-1~20.04.sav0
  Version table:
     7.87.0-1~20.04.sav0 500
        500 http://ppa.launchpad.net/savoury1/curl34/ubuntu focal/main amd64 Packages
     7.68.0-1ubuntu2.16 500
        500 http://sg.archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
        500 http://sg.archive.ubuntu.com/ubuntu focal-security/main amd64 Packages
     7.68.0-1ubuntu2 500
        500 http://sg.archive.ubuntu.com/ubuntu focal/main amd64 Packages
libgnutls30:
  Installed: 3.6.13-2ubuntu1.7
  Candidate: 3.6.13-2ubuntu1.8
  Version table:
     3.6.13-2ubuntu1.8 500
        500 http://sg.archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
        500 http://sg.archive.ubuntu.com/ubuntu focal-security/main amd64 Packages
 *** 3.6.13-2ubuntu1.7 100
        100 /var/lib/dpkg/status
     3.6.13-2ubuntu1 500
        500 http://sg.archive.ubuntu.com/ubuntu focal/main amd64 Packages

And list of apt sources

➜  ~ lsa /etc/apt/sources.list.d/*list
Permissions Size User Date Modified Name
.rw-r--r--   164 root  6 Mar 11:54  /etc/apt/sources.list.d/apandada1-ubuntu-brightness-controller-focal.list
.rw-r--r--   132 root  6 Mar 11:54  /etc/apt/sources.list.d/apt-fast-ubuntu-stable-focal.list
.rw-r--r--   109 root  6 Mar 11:54  /etc/apt/sources.list.d/azlux.list
.rw-r--r--   141 root  6 Mar 11:54  /etc/apt/sources.list.d/brave-browser-release.list
.rw-r--r--   130 root  6 Mar 11:54  /etc/apt/sources.list.d/docker.list
.rw-r--r--   130 root  6 Mar 11:54  /etc/apt/sources.list.d/gezakovacs-ubuntu-ppa-focal.list
.rw-r--r--   189 root  6 Mar 11:54  /etc/apt/sources.list.d/google-chrome.list
.rw-r--r--   106 root  6 Mar 11:54  /etc/apt/sources.list.d/google-cloud-sdk.list
.rw-r--r--   140 root  6 Mar 11:54  /etc/apt/sources.list.d/kgilmer-ubuntu-speed-ricer-focal.list
.rw-r--r--    54 root  6 Mar 11:54  /etc/apt/sources.list.d/kubernetes.list
.rw-r--r--    92 root  6 Mar 11:54  /etc/apt/sources.list.d/mongodb-org-5.0.list
.rw-r--r--   140 root  6 Mar 11:54  /etc/apt/sources.list.d/neovim-ppa-ubuntu-unstable-focal.list
.rw-r--r--    88 root  6 Mar 11:54  /etc/apt/sources.list.d/nextdns.list
.rw-r--r--    76 root  6 Mar 11:54  /etc/apt/sources.list.d/pgadmin4.list
.rw-r--r--   132 root  6 Mar 11:54  /etc/apt/sources.list.d/savoury1-ubuntu-curl34-focal.list
.rw-r--r--   146 root  6 Mar 11:54  /etc/apt/sources.list.d/serge-rider-ubuntu-dbeaver-ce-focal.list
.rw-r--r--   125 root  6 Mar 11:54  /etc/apt/sources.list.d/signal-xenial.list
.rw-r--r--   193 root  6 Mar 11:54  /etc/apt/sources.list.d/slack.list
.rw-r--r--    50 root  6 Mar 11:54  /etc/apt/sources.list.d/spotify.list
.rw-r--r--   140 root  6 Mar 11:54  /etc/apt/sources.list.d/strukturag-ubuntu-libde265-focal.list
.rw-r--r--   138 root  6 Mar 11:54  /etc/apt/sources.list.d/strukturag-ubuntu-libheif-focal.list
.rw-r--r--    50 root  6 Mar 11:54  /etc/apt/sources.list.d/sublime-text.list
.rw-r--r--    94 root  6 Mar 11:54  /etc/apt/sources.list.d/tailscale.list
.rw-r--r--   130 root  6 Mar 11:54  /etc/apt/sources.list.d/tonimelisma-ubuntu-ppa-focal.list
.rw-r--r--   266 root  6 Mar 11:54  /etc/apt/sources.list.d/ubuntu-esm-apps.list
.rw-r--r--   274 root  6 Mar 11:54  /etc/apt/sources.list.d/ubuntu-esm-infra.list
.rw-r--r--   203 root  6 Mar 11:54  /etc/apt/sources.list.d/vscode.list
.rw-r--r--   142 root  6 Mar 11:54  /etc/apt/sources.list.d/wireshark-dev-ubuntu-stable-focal.list
➜  ~ 
pl flag
What's the output of `apt-cache policy libcurl3-gnutls libgnutls30` and what's in your `/etc/apt/sources.list` and any additional `/etc/apt/sources.list.d/*.list`?
Ye Lin Aung avatar
iq flag
@popey Hey, thanks for the comment. I've updated my question with the requested info.
pl flag
Wow! That's a lot of PPAs. It looks like the savoury1/curl34 PPA is perhaps what's causing this. I'd be inclined to remove that PPA, and install the versions from the archive with `sudo apt install libcurl3-gnutls=7.68.0-1ubuntu2.16 libgnutls30=3.6.13-2ubuntu1.8` to get past this.
Ye Lin Aung avatar
iq flag
@popey you are right! I removed `savoury1/curl34` and downgraded `curl`/`libcurl`. Now everything is resolved!. Do you wanna add that as an answer? Then I can mark it as accepted.
pl flag
Great news! Glad we got it working!
Score:2
pl flag

It looks like the savoury1/curl34 PPA is perhaps what's causing this. I'd be inclined to remove that PPA, and install the versions from the archive with sudo apt install libcurl3-gnutls=7.68.0-1ubuntu2.16 libgnutls30=3.6.13-2ubuntu1.8 to get past this.

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.