当我尝试使用 apt 安装任何包时,出现此错误:
E: Cannot get debconf version. Is debconf installed?
debconf: apt-extracttemplates failed: No such file or directory
Extract templates from packages: 26%E: Cannot get debconf version. Is debconf installed?
debconf: apt-extracttemplates failed: No such file or directory
Extract templates from packages: 53%E: Cannot get debconf version. Is debconf installed?
debconf: apt-extracttemplates failed: No such file or directory
Extract templates from packages: 79%E: Cannot get debconf version. Is debconf installed?
debconf: apt-extracttemplates failed: No such file or directory
Extract templates from packages: 100%
dpkg: error: parsing file '/var/lib/dpkg/status' near line 0:
end of file after field name ''
E: Sub-process /usr/bin/dpkg returned an error code (2)
attempting to run apt update fails with this error:
Reading package lists... Error!
E: Unable to parse package file /var/lib/dpkg/status (1)
W: To correct these problems, you may want to run apt update
E: The package cache file is corrupted
运行'head -n5 /var/lib/dpkg/status'输出一个空白行
运行“ls -al /var/lib/dpkg/status”输出“-rw-r--r-- 1 root root 1516491 Jul 11 19:14 /var/lib/dpkg/status”
我在这个安装中安装了很多软件包和文件,因此全新安装并不是一个真正的选择。