Cannot get net-tools to install on Linux because of this error.
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
libc-bin
0 upgraded, 1 newly installed, 0 to remove and 316 not upgraded.
Need to get 0 B/633 kB of archives.
After this operation, 3802 kB of additional disk space will be used.
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
LANGUAGE = (unset),
LC_ALL = (unset),
LANG = "C.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.
Selecting previously unselected package libc-bin.
(Reading database ... 57438 files and directories currently installed.)
Preparing to unpack .../libc-bin_2.31-0ubuntu9.9_amd64.deb ...
Unpacking libc-bin (2.31-0ubuntu9.9) ...
Setting up libc-bin (2.31-0ubuntu9.9) ...
Aborted (core dumped)
/sbin/ldconfig.real: Can't stat /usr/local/lib/x86_64-linux-gnu: No such file or directory
/sbin/ldconfig.real: Path `/usr/lib/x86_64-linux-gnu' given more than once
/sbin/ldconfig.real: Path `/usr/lib32' given more than once
/sbin/ldconfig.real: Path `/lib/x86_64-linux-gnu' given more than once
/sbin/ldconfig.real: Path `/usr/lib/x86_64-linux-gnu' given more than once
/sbin/ldconfig.real: Path `/usr/lib' given more than once
/usr/lib/x86_64-linux-gnu/libfakeroot:
libfakeroot-0.so -> libfakeroot-tcp.so
/usr/lib/wsl/lib:
/usr/local/lib:
/lib/x86_64-linux-gnu:
Aborted (core dumped)
dpkg: error processing package libc-bin (--configure):
installed libc-bin package post-installation script subprocess returned error exit status 134
Errors were encountered while processing:
libc-bin
E: Sub-process /usr/bin/dpkg returned an error code (1)
I Tried purging and reinstalling with no success
sudo dpkg --purge --force-all libc-bin
sudo apt-get install libc-bin
Fairly new to Linux so I would love to have someone tell me what I can do to fix this.
Not sure where to look next.
I tried many commands but always get the error dpkg: error processing package libc-bin
like you.
The only method that worked for me is below.
Try to install net-tools after these commands.
sudo rm /var/lib/dpkg/info/libc-bin.*
sudo apt-get clean
sudo apt-get update
sudo apt install libc-bin