考虑到系统的稳定性,也因为懒,一直没升级Ubuntu 1610,也没有update。最近发现官方已经不支持1610了,而且直接把yakkety的镜像给取消了。所以,即使是利用系统自带的update manager,也无法直接升级到1710,会出现如下的两类错误,

无法更新
1
2
3
4
5
6
7
8
E:The repository 'http://archive.canonical.com/ubuntu yakkety Release' does not have a Release file.,
W:Updating from such a repository can't be done securely, and is therefore disabled by default.,
W:See apt-secure(8) manpage for repository creation and user configuration details.,
E:The repository 'http://archive.ubuntu.com/ubuntu yakkety Release' does not have a Release file.,
W:Updating from such a repository can't be done securely, and is therefore disabled by default.,
W:See apt-secure(8) manpage for repository creation and user configuration details.,
E:The repository 'http://archive.ubuntu.com/ubuntu yakkety-updates Release' does not have a Release file.,
...
无法升级
1
An upgrade from 'yakkety' to 'artful' is not supported with this tool.

参考Askubuntu上的问题,有如下的解决方法,

1
2
3
4
5
6
7
8
9
10
11
cd /etc/apt/
# 备份现有的sources.list
sudo cp sources.list sources.list.bkp
# 替换yakkety为artful
sudo vim sources.list
:%s/yakkety/artful/g
# 保存并重新更新和升级
sudo update
sudo upgrade
# 重启系统
reboot

Reference

[1] How to upgrade ubuntu from 1610 to 1710