Score:0

UBUNTU 20.04 LTS: Missing 'lbconfig' and a 'libc-bin' c library

bt flag

A frustrating problem occurred when I sudo apt-get update --> then: sudo apt-get upgrade on UBUNTU 20.04.

I had recently gone through a successful upgrade of PYTHON3.8 to PYTHON3.10 - BUT I do not know if this was responsible for missing ldconfig files and a missing sbin library in usr/locale/.

I checked the 3 root sbin locations: /sbin, usr/locale/sbin, and usr/sbin. /sbin and usr/sbin had the c program utilities in them - but was missing 'ldconfig' utility. AND usr/locale/sbin directory was completely missing.

Here is the messages Linux gives me when I tried to fix broken links:

$ sudo apt --fix-broken install
Reading package lists... Done
Building dependency tree
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
  libc-bin
The following NEW packages will be installed:
  libc-bin
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 0 B/633 kB of archives.
After this operation, 3802 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
        LANGUAGE = (unset),
        LC_ALL = (unset),
        LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to the standard locale ("C").
Can't exec "locale": No such file or directory at /usr/share/perl5/Debconf/Encoding.pm line 16.
Use of uninitialized value $Debconf::Encoding::charmap in scalar chomp at /usr/share/perl5/Debconf/Encoding.pm line 17.
dpkg: warning: 'ldconfig' not found in PATH or not executable
dpkg: error: 1 expected program not found in PATH or not executable
Note: root's PATH should usually contain /usr/local/sbin, /usr/sbin and /sbin
E: Sub-process /usr/bin/dpkg returned an error code (2)

I had previously downloaded - but did not install - libc-bin - which was a .deb archive called libc-bin_2.31-0ubuntu9.9_amd64.deb - and had successfully cp'd it over to usr/locale/sbin. When I tried to install and checked - the archive name had changed to 'sbin' in usr/locale/ but had not extracted.

Has anyone run into this issue and been able to navigate to a solution that does not require scrapping the UBUNTU and doing a complete reinstall?

One final note: I am running UBUNTU in a Microsoft Windows 10 machine under WSL. I am only using the command line to configure UBUNTU 20.04 LTS.

ALSO --

The error msgs also mention a missing PERL5 script -- Encoding.pm - but I have not looked into it.

Thank you for your genius in helping me get out of this swamp of problems.

David avatar
cn flag
To be clear you have changed the default version of Python that came with the OS?
Jeff Thompson avatar
bt flag
Yes. I did this in order to add ROCm drivers to my AMD graphics card in order to use AI processes under AUTOMATIC1111 gui - that were designed to use NVIDIA cuda. The ROCm drivers work with AMDs HIP to translate and requires python3.10.
Hannu avatar
ca flag
**I'm guessing**, but replacing Python is prone to create problems, as it is an deeply buried dependency for many things - apt / apt-get for starters. In the process you also may have a created a situation with a replacement "new" libc which isn't "known" to some of the OS software. This kind of tinkering requires good knowledge of the OS internals.
Jeff Thompson avatar
bt flag
Thank You for your kind input. Would creating a Docker "shell" or environment around all this extra stuff that is needed for this prompt/image AI Graphical User Interface and AMD drivers and interpreters etc. be the cleanest way to keep from mucking up Ubuntu's innards?
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.