grub2-common:中断:shim(

grub2-common:中断:shim(

安装 woeusb 后出现这些错误:

krish@krish-Inspiron-3558:~$ sudo apt-get upgrade
[sudo] password for krish: 
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
 grub2-common : Breaks: shim (< 13) but 0.9+1474479173.6c180c6-1ubuntu1 is installed
 shim-signed : Depends: shim (= 13-0ubuntu2) but 0.9+1474479173.6c180c6-1ubuntu1 is installed
E: Unmet dependencies. Try using -f.
krish@krish-Inspiron-3558:~$ sudo apt-get autoremove
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these.
The following packages have unmet dependencies:
 grub2-common : Breaks: shim (< 13) but 0.9+1474479173.6c180c6-1ubuntu1 is installed
 shim-signed : Depends: shim (= 13-0ubuntu2) but 0.9+1474479173.6c180c6-1ubuntu1 is installed
E: Unmet dependencies. Try using -f.

我还得到:

The following packages will be upgraded:
  shim
1 upgraded, 0 newly installed, 0 to remove and 257 not upgraded.
2 not fully installed or removed.
Need to get 440 kB of archives.
After this operation, 24.6 kB of additional disk space will be used.
Get:1 http://archive.ubuntu.com/ubuntu/ trusty-updates/main shim amd64 13-0ubuntu2 [440 kB]
Fetched 440 kB in 3s (119 kB/s) 
dpkg-deb: error: archive '/var/cache/apt/archives/shim_13-0ubuntu2_amd64.deb' has premature member 'control.tar.xz' before 'control.tar.gz', giving up
dpkg: error processing archive /var/cache/apt/archives/shim_13-0ubuntu2_amd64.deb (--unpack):
 subprocess dpkg-deb --control returned error exit status 2
E: Sub-process /usr/bin/dpkg returned an error code (1)

答案1

它说包有问题shim。此命令:

sudo rm /var/cache/apt/archives/shim_13-0ubuntu2_amd64.deb

将删除该包的当前版本。

然后清除以前安装的所有残余shim,更新 apt 的缓存并重新安装:

sudo apt purge shim; sudo apt update; sudo apt install shim

相关内容