本文记录如何解决Ubuntu update时候遇到的错误。
错误提示为:Update information is outdated…
- step1:运行
apt get update``` 1
2
3
4
5
6- step2:根据最后输出的信息错误进行修改,具体的修改方案参考这篇[博客](https://linux.cn/article-5603-1.html#3_447)
简单记录几种情况:
1. problems with merge lists
```shell
$sudo rm -r /var/lib/apt/lists/*
$sudo apt-get clean && sudo apt-get update
Failed to fecth … Package Hash Sum mismatch
1
2$sudo rm -rf /var/lib/apt/lists/*
$sudo apt-get updateppa过时导致的
找到software&update->other software->去掉过时的那个ppa前面的勾或者直接删除- 从某个网址下载失败
找到Software&Update->Ubuntu Software,更换源 not all update can install
1
$sudo apt-get install -f
error while loading shared libraries:
1
$sudo /sbin/ldconfig -v
Could not get lock /var/cache/apt/archives/lock
这个是因为你在其他地方在安装某个东西,而又在这里使用到apt1
$sudo rm /var/lib/apt/lists/lock
或者1
$sudo killall apt-get
下列签名无法验证
假设不能添加的key为: 68980A0EA10B4DE81
$sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 68980A0EA10B4DE8
如何是像这样的签名错误:The following signatures were invalid: BADSIG 16126D3A3E5C1192 Ubuntu Extras Archive Automatic Signing Key
1
2
3
4
5
6sudo apt-get clean
cd /var/lib/apt
sudo mv lists oldlist
sudo mkdir -p lists/partial
sudo apt-get clean
sudo apt-get update