微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

Ubuntu apt 出错解决办法: Problem parsing dependency Depends

问题:

Reading package lists... Error!
E: Problem parsing dependency Depends
E: Error occurred while processing xxxxx (NewVersion2)
E: Problem with MergeList /var/lib/apt/lists/ftp.debian.org_debian_dists_squeeze_main_binary-amd64_Packages
E: The package lists or status file Could not be parsed or opened.

the one thing that stands out the most to me is that it’s happening with the same MergeList off the very same package mirror and directory of that mirror. This naturally leads me to wonder if there isnt something in that mirror folder thats corrupt,or something there thats causing users’ local package databases to become corrupt. Even that swapping around of the status file in /var/lib/dpkg didnt seem to help at all. Any suggestions?
Hmm,sorry chris,only just saw this post on the thread,so apologies for the necropost to ALL. But,since this thread started I have found out a couple of methods for fixing these sort of errors without reverting to any drastic measures,and that normally work. If for anything,I will document them here for posterity.

First,dpkg has some neat options for fixing some problems,especially those with the “available” file. Here’s the link…

…of particular use is the…

Code:

dpkg --clear-avail

…command,when update complains of problems with the available file. And when there are problems with the MergeList,as in your case,simply clear them out with…

Code:

rm /var/lib/apt/lists/* --force

For both cases,a subsequent apt-get update appears to fix most problems. I seem to have “discovered” that if you use dpkg,on Debian,taking the time to learn dpkg’s varIoUs command facets is one of the most worthwhile things you can do.

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐