0

I am currently on Ubuntu 22.04 LTS.

When I run sudo apt-get upgrade I receive the following error:

The following packages have unmet dependencies:
 libcrypt1 : Depends: libc6 (>= 2.25) but it is not installed
 libgcc-s1 : Depends: libc6 (>= 2.35) but it is not installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

When I attempt apt --fix-broken install and also manually installing libc6 I receive the following error:

Errors were encountered while processing:
 /var/cache/apt/archives/libc6_2.35-0ubuntu3.1_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Then I followed the steps I found on this website for that error message:

https://itsfoss.com/dpkg-returned-an-error-code-1/

None of these steps resolved my issue. Is there anyway to fix these broken package dependencies? Thank you in advance for any assistance.

EDIT: Adding the following requested outputs.

sudo apt update:

Hit:1 http://us.archive.ubuntu.com/ubuntu jammy InRelease
Hit:2 http://us.archive.ubuntu.com/ubuntu jammy-updates InRelease
Get:3 http://us.archive.ubuntu.com/ubuntu jammy-backports InRelease [108 kB]
Hit:4 http://security.ubuntu.com/ubuntu jammy-security InRelease                                                                   
Hit:5 https://ppa.launchpadcontent.net/danielrichter2007/grub-customizer/ubuntu jammy InRelease                                    
Fetched 108 kB in 11s (10.2 kB/s)                                                                                                  
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
All packages are up to date.

apt policy libcrypt1:

libcrypt1:
  Installed: 1:4.4.27-1
  Candidate: 1:4.4.27-1
  Version table:
 *** 1:4.4.27-1 500
        500 http://us.archive.ubuntu.com/ubuntu jammy/main amd64 Packages
        100 /var/lib/dpkg/status

apt policy libgcc-s1:

libgcc-s1:
  Installed: 12.1.0-2ubuntu1~22.04
  Candidate: 12.1.0-2ubuntu1~22.04
  Version table:
 *** 12.1.0-2ubuntu1~22.04 500
        500 http://us.archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages
        500 http://security.ubuntu.com/ubuntu jammy-security/main amd64 Packages
        100 /var/lib/dpkg/status
     12-20220319-1ubuntu1 500
        500 http://us.archive.ubuntu.com/ubuntu jammy/main amd64 Packages

apt policy libc6:

libc6:
  Installed: (none)
  Candidate: 2.35-0ubuntu3.1
  Version table:
     2.35-0ubuntu3.1 500
        500 http://us.archive.ubuntu.com/ubuntu jammy-updates/main amd64 Packages
     2.35-0ubuntu3 500
        500 http://us.archive.ubuntu.com/ubuntu jammy/main amd64 Packages

dpkg -l libc6:

Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version      Architecture Description
+++-==============-============-============-=================================
in  libc6:amd64    <none>       amd64        (no description available)

sudo apt install libc6:i386:

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 libc6:i386 : Depends: libgcc-s1:i386 but it is not going to be installed
              Depends: libcrypt1:i386 (>= 1:4.4.10-10ubuntu4) but it is not going to be installed
              Recommends: libidn2-0:i386 (>= 2.0.5~) but it is not going to be installed
              Recommends: libnss-nis:i386 but it is not going to be installed
              Recommends: libnss-nisplus:i386 but it is not going to be installed
 libcrypt1 : Depends: libc6 (>= 2.25) but it is not going to be installed
 libgcc-s1 : Depends: libc6 (>= 2.35) but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

dpkg -S /lib/x86_64-linux-gnu/libc.so.6:

dpkg-query: warning: files list file for package 'libcrypt1:amd64' missing; assuming package has no files currently installed
dpkg-query: warning: files list file for package 'libgcc-s1:amd64' missing; assuming package has no files currently installed
dpkg-query: no path found matching pattern /lib/x86_64-linux-gun/libc.so.6
8
  • Do you have both the amd and 32 bit libc6 packages? Check with dpkg -l libc6
    – ubfan1
    Jun 24, 2023 at 18:36
  • I added the output to the original comment. It does not appear I have the 32 bit package. Jun 24, 2023 at 18:51
  • Unless your system is based on an alternative C implementation like musl, it's hard to see how it can function at all if the libraries provided by the libc6 package were missing - perhaps the package has somehow become marked as not installed in the database, but its files are still there? Does /lib/x86_64-linux-gnu/libc.so.6 exist for example, and if so, what does dpkg -S /lib/x86_64-linux-gnu/libc.so.6 report? Jun 24, 2023 at 20:36
  • @steeldriver I don't believe I have any kind of special implementation. I use Grub to dual boot Windows 11 and Ubuntu 22.04. That file does exist. I posted the output in the original post. Jun 25, 2023 at 1:44
  • Does this answer your question? How do I resolve unmet dependencies after adding a PPA?
    – karel
    Jun 25, 2023 at 3:17

1 Answer 1

2

My solution ended up being to clean install Ubuntu 23.04. At this point it was much more efficient. I have Windows, Ubuntu, and my data all on separate drives, so nothing important is lost and setting Ubuntu up is fast and easy.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .