首页 > 技术文章 > ubuntu 16.04 apt-get 出现The package 'xxx' needs to be reinstalled, but I can't find an archive for it.

llfctt 2018-08-03 15:24 原文

参考网址:http://www.ihaveapc.com/2011/10/fix-annoying-the-package-needs-to-be-reinstalled-but-i-cant-find-an-archive-for-it-error-in-linux-mint-ubuntu/

解决办法:

sudo cp /var/lib/dpkg/status status.bkp

sudo gedit /var/lib/dpkg/status

Search for the package name that appears in the error. Note that, in our case the culprit package was ‘urd’ which was in ‘purge reinstreq half-installed’ state. After you have located the culprit package, delete the section of information related to that package and save the file. In our case, we deleted the section related to ‘urd’ inside the rectangle and saved the file. Close ‘gedit’ when done.

 

推荐阅读