由于 GLIBC_2.28 错误,我无法使用任何安装命令

由于 GLIBC_2.28 错误,我无法使用任何安装命令

运行 sudo apt-get install packagename 时出现此错误。apt-get:/lib/i386-linux-gnu/libc.so.6:未找到版本“GLIBC_2.28”(/usr/lib/i386-linux-gnu/libapt-pkg.so.5.0 所需)

The output of " cat /etc/apt/sources.list" is:
deb http://us.archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ xenial-security main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ xenial-updates main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ xenial-proposed main restricted universe multiverse
deb http://us.archive.ubuntu.com/ubuntu/ xenial-backports main restricted universe multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-security main restricted universe multiverse
deb-src http://us.archive.ubuntu.com/ubuntu/ xenial-updates main restricted universe multiverse

在跑步的时候dpkg -l libapt*

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
+++-==============-============-============-=================================
un  libapt-inst    <none>       <none>       (no description available)
ii  libapt-inst1.4 0.8.16~exp12 i386         deb package format runtime librar
rc  libapt-inst1.5 1.0.1ubuntu2 i386         deb package format runtime librar
ii  libapt-inst2.0 1.6.6        i386         deb package format runtime librar
un  libapt-pkg     <none>       <none>       (no description available)
ii  libapt-pkg-per 0.1.33build1 i386         Perl interface to libapt-pkg
ii  libapt-pkg4.12 1.0.1ubuntu2 i386         package management runtime librar
ii  libapt-pkg5.0: 1.7.0ubuntu0 i386         package management runtime librar

cat /etc/lsb-release
DISTRIB_ID=Ubuntu DISTRIB_RELEASE=18.04 DISTRIB_CODENAME=bionic DISTRIB_DESCRIPTION="Ubuntu 18.04.1 LTS"

答案1

您的sources.list文件中已设置 16.04 存储库。

我建议删除该文件

sudo rm /etc/apt/sources.list

然后运行

software-properties-gtk

并检查其中的存储库,例如mainuniverse等。

这应该创建一个包含存储库而不是的新sources.list文件。bionicxenial

另一种方法是运行sudo nano /etc/apt/sources.list

并粘贴此文本

deb http://archive.ubuntu.com/ubuntu/ bionic main restricted universe multiverse  
deb http://archive.ubuntu.com/ubuntu/ bionic-updates main restricted universe multiverse
deb http://archive.ubuntu.com/ubuntu/ bionic-backports main restricted universe multiverse
deb http://security.ubuntu.com/ubuntu bionic-security main restricted universe multiverse

然后按Ctrl+O保存,按Ctrl+X退出。

跑步sudo apt update

相关内容