可怜可怜我吧,我正试图从 10.04 一路爬到 16.04。第一步是升级到 12.04。
我已更新我的/etc/apt/sources.list
使用old-releases
:
## main & restricted repositories
deb http://old-releases.ubuntu.com/ubuntu/ lucid main restricted
deb-src http://old-releases.ubuntu.com/ubuntu/ lucid main restricted
deb http://old-releases.ubuntu.com/ubuntu lucid-updates main restricted
deb-src http://old-releases.ubuntu.com/ubuntu lucid-updates main restricted
deb http://old-releases.ubuntu.com/ubuntu lucid-security main restricted
deb-src http://old-releases.ubuntu.com/ubuntu lucid-security main restricted
## universe repositories - uncomment to enable
deb http://old-releases.ubuntu.com/ubuntu/ lucid universe
deb-src http://old-releases.ubuntu.com/ubuntu/ lucid universe
deb http://old-releases.ubuntu.com/ubuntu/ lucid-updates universe
deb-src http://old-releases.ubuntu.com/ubuntu/ lucid-updates universe
deb http://old-releases.ubuntu.com/ubuntu lucid-security universe
deb-src http://old-releases.ubuntu.com/ubuntu lucid-security universe
apt-get update
并且apt-get upgrade
通过这一改变可以正常工作。
但是,当我尝试通过升级到 12.04 时,do-release-upgrade
它失败并出现以下错误(见下文)。奇怪的是,它似乎仍在尝试访问archive
URL 而不是old-releases
URL。应该是 吗old-releases
?有没有办法强制系统在那里查找而不是archive
?
$ do-release-upgrade
WARNING:root:estimate_kernel_size_in_boot() returned '0'?
Reading cache
Checking package manager
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
WARNING: Failed to read mirror file
Ign http://archive.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid Release.gpg
Hit http://old-releases.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid-security Release.gpg
Ign http://archive.ubuntu.com lucid-updates Release
Hit http://old-releases.ubuntu.com lucid Release
Hit http://old-releases.ubuntu.com lucid-updates Release
Ign http://archive.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid-security Release
Ign http://archive.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid/main Packages
Hit http://old-releases.ubuntu.com lucid/restricted Packages
Hit http://old-releases.ubuntu.com lucid/main Sources
Hit http://old-releases.ubuntu.com lucid/restricted Sources
Hit http://old-releases.ubuntu.com lucid/universe Packages
Hit http://old-releases.ubuntu.com lucid/universe Sources
Hit http://old-releases.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid-updates/restricted Packages
Hit http://old-releases.ubuntu.com lucid-updates/main Sources
Hit http://old-releases.ubuntu.com lucid-updates/restricted Sources
Err http://archive.ubuntu.com lucid-updates/main Packages
404 Not Found [IP: 91.189.88.149 80]
Hit http://old-releases.ubuntu.com lucid-updates/universe Packages
Hit http://old-releases.ubuntu.com lucid-updates/universe Sources
Hit http://old-releases.ubuntu.com lucid-security/main Packages
Hit http://old-releases.ubuntu.com lucid-security/restricted Packages
Hit http://old-releases.ubuntu.com lucid-security/main Sources
Hit http://old-releases.ubuntu.com lucid-security/restricted Sources
Hit http://old-releases.ubuntu.com lucid-security/universe Packages
Hit http://old-releases.ubuntu.com lucid-security/universe Sources
Fetched 0B in 0s (0B/s)
ERROR:root:IOError/SystemError in cache.update(): 'W:Failed to fetch http://archive.ubuntu.com/ubuntu/dists/lucid-updates/main/binary-i386/Packages.gz 404 Not Found [IP: 91.189.88.149 80]
, E:Some index files failed to download, they have been ignored, or old ones used instead.'. Retrying (currentRetry: 0)
Hit http://old-releases.ubuntu.com lucid Release.gpg
Hit http://old-releases.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid-security Release.gpg
Ign http://archive.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid Release
Hit http://old-releases.ubuntu.com lucid-updates Release
Ign http://archive.ubuntu.com lucid-updates Release
Hit http://old-releases.ubuntu.com lucid-security Release
Ign http://archive.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid/main Packages
Hit http://old-releases.ubuntu.com lucid/restricted Packages
Hit http://old-releases.ubuntu.com lucid/main Sources
Hit http://old-releases.ubuntu.com lucid/restricted Sources
Hit http://old-releases.ubuntu.com lucid/universe Packages
Hit http://old-releases.ubuntu.com lucid/universe Sources
Hit http://old-releases.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid-updates/restricted Packages
Hit http://old-releases.ubuntu.com lucid-updates/main Sources
Hit http://old-releases.ubuntu.com lucid-updates/restricted Sources
Ign http://archive.ubuntu.com lucid-updates/main Packages
Err http://archive.ubuntu.com lucid-updates/main Packages
404 Not Found [IP: 91.189.88.149 80]
Hit http://old-releases.ubuntu.com lucid-updates/universe Packages
Hit http://old-releases.ubuntu.com lucid-updates/universe Sources
Hit http://old-releases.ubuntu.com lucid-security/main Packages
Hit http://old-releases.ubuntu.com lucid-security/restricted Packages
Hit http://old-releases.ubuntu.com lucid-security/main Sources
Hit http://old-releases.ubuntu.com lucid-security/restricted Sources
Hit http://old-releases.ubuntu.com lucid-security/universe Packages
Hit http://old-releases.ubuntu.com lucid-security/universe Sources
Fetched 0B in 0s (0B/s)
ERROR:root:IOError/SystemError in cache.update(): 'W:Failed to fetch http://archive.ubuntu.com/ubuntu/dists/lucid-updates/main/binary-i386/Packages.gz 404 Not Found [IP: 91.189.88.149 80]
, E:Some index files failed to download, they have been ignored, or old ones used instead.'. Retrying (currentRetry: 1)
Ign http://archive.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid Release.gpg
Hit http://old-releases.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid-security Release.gpg
Ign http://archive.ubuntu.com lucid-updates Release
Hit http://old-releases.ubuntu.com lucid Release
Hit http://old-releases.ubuntu.com lucid-updates Release
Ign http://archive.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid-security Release
Ign http://archive.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid/main Packages
Hit http://old-releases.ubuntu.com lucid/restricted Packages
Hit http://old-releases.ubuntu.com lucid/main Sources
Hit http://old-releases.ubuntu.com lucid/restricted Sources
Hit http://old-releases.ubuntu.com lucid/universe Packages
Hit http://old-releases.ubuntu.com lucid/universe Sources
Hit http://old-releases.ubuntu.com lucid-updates/main Packages
Hit http://old-releases.ubuntu.com lucid-updates/restricted Packages
Hit http://old-releases.ubuntu.com lucid-updates/main Sources
Hit http://old-releases.ubuntu.com lucid-updates/restricted Sources
Err http://archive.ubuntu.com lucid-updates/main Packages
404 Not Found [IP: 91.189.88.149 80]
Hit http://old-releases.ubuntu.com lucid-updates/universe Packages
Hit http://old-releases.ubuntu.com lucid-updates/universe Sources
Hit http://old-releases.ubuntu.com lucid-security/main Packages
Hit http://old-releases.ubuntu.com lucid-security/restricted Packages
Hit http://old-releases.ubuntu.com lucid-security/main Sources
Hit http://old-releases.ubuntu.com lucid-security/restricted Sources
Hit http://old-releases.ubuntu.com lucid-security/universe Packages
Hit http://old-releases.ubuntu.com lucid-security/universe Sources
Fetched 0B in 0s (0B/s)
ERROR:root:IOError/SystemError in cache.update(): 'W:Failed to fetch http://archive.ubuntu.com/ubuntu/dists/lucid-updates/main/binary-i386/Packages.gz 404 Not Found [IP: 91.189.88.149 80]
, E:Some index files failed to download, they have been ignored, or old ones used instead.'. Retrying (currentRetry: 2)
ERROR:root:doUpdate() failed completely
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Fetched 0B in 0s (0B/s)
WARNING:root:estimate_kernel_size_in_boot() returned '0'?
Reading cache
Checking package manager
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Ign http://old-releases.ubuntu.com lucid InRelease
Ign http://old-releases.ubuntu.com lucid-updates InRelease
Ign http://old-releases.ubuntu.com lucid-security InRelease
Hit http://old-releases.ubuntu.com lucid Release.gpg
Hit http://old-releases.ubuntu.com lucid-updates Release.gpg
Hit http://old-releases.ubuntu.com lucid-security Release.gpg
Hit http://old-releases.ubuntu.com lucid Release
Hit http://old-releases.ubuntu.com lucid-updates Release
Hit http://old-releases.ubuntu.com lucid-security Release
Hit http://old-releases.ubuntu.com lucid/main Sources
Hit http://old-releases.ubuntu.com lucid/restricted Sources
Hit http://old-releases.ubuntu.com lucid/universe Sources
Hit http://old-releases.ubuntu.com lucid/main i386 Packages
Hit http://old-releases.ubuntu.com lucid/restricted i386 Packages
Hit http://old-releases.ubuntu.com lucid/universe i386 Packages
Ign http://old-releases.ubuntu.com lucid/main TranslationIndex
Ign http://old-releases.ubuntu.com lucid/restricted TranslationIndex
Ign http://old-releases.ubuntu.com lucid/universe TranslationIndex
Hit http://old-releases.ubuntu.com lucid-updates/main Sources
Hit http://old-releases.ubuntu.com lucid-updates/restricted Sources
Hit http://old-releases.ubuntu.com lucid-updates/universe Sources
Hit http://old-releases.ubuntu.com lucid-updates/main i386 Packages
Hit http://old-releases.ubuntu.com lucid-updates/restricted i386 Packages
Hit http://old-releases.ubuntu.com lucid-updates/universe i386 Packages
Hit http://old-releases.ubuntu.com lucid-updates/main TranslationIndex
Hit http://old-releases.ubuntu.com lucid-updates/restricted TranslationIndex
Hit http://old-releases.ubuntu.com lucid-updates/universe TranslationIndex
Hit http://old-releases.ubuntu.com lucid-security/main Sources
Hit http://old-releases.ubuntu.com lucid-security/restricted Sources
Hit http://old-releases.ubuntu.com lucid-security/universe Sources
Hit http://old-releases.ubuntu.com lucid-security/main i386 Packages
Hit http://old-releases.ubuntu.com lucid-security/restricted i386 Packages
Hit http://old-releases.ubuntu.com lucid-security/universe i386 Packages
Ign http://old-releases.ubuntu.com lucid-security/main TranslationIndex
Ign http://old-releases.ubuntu.com lucid-security/restricted TranslationIndex
Ign http://old-releases.ubuntu.com lucid-security/universe TranslationIndex
Err http://old-releases.ubuntu.com lucid/main Translation-en
Err http://old-releases.ubuntu.com lucid/restricted Translation-en
Err http://old-releases.ubuntu.com lucid/universe Translation-en
Err http://old-releases.ubuntu.com lucid-security/main Translation-en
Err http://old-releases.ubuntu.com lucid-security/restricted Translation-en
Err http://old-releases.ubuntu.com lucid-security/universe Translation-en
Err http://old-releases.ubuntu.com lucid/main Translation-en
Err http://old-releases.ubuntu.com lucid/restricted Translation-en
Err http://old-releases.ubuntu.com lucid/universe Translation-en
Err http://old-releases.ubuntu.com lucid-security/main Translation-en
Err http://old-releases.ubuntu.com lucid-security/restricted Translation-en
Err http://old-releases.ubuntu.com lucid-security/universe Translation-en
Err http://old-releases.ubuntu.com lucid/main Translation-en
Err http://old-releases.ubuntu.com lucid/restricted Translation-en
Err http://old-releases.ubuntu.com lucid/universe Translation-en
Err http://old-releases.ubuntu.com lucid-security/main Translation-en
Err http://old-releases.ubuntu.com lucid-security/restricted Translation-en
Err http://old-releases.ubuntu.com lucid-security/universe Translation-en
Err http://old-releases.ubuntu.com lucid/main Translation-en
Err http://old-releases.ubuntu.com lucid/restricted Translation-en
Err http://old-releases.ubuntu.com lucid/universe Translation-en
Err http://old-releases.ubuntu.com lucid-security/main Translation-en
Err http://old-releases.ubuntu.com lucid-security/restricted Translation-en
Err http://old-releases.ubuntu.com lucid-security/universe Translation-en
Ign http://old-releases.ubuntu.com lucid/main Translation-en
Ign http://old-releases.ubuntu.com lucid/restricted Translation-en
Ign http://old-releases.ubuntu.com lucid/universe Translation-en
Ign http://old-releases.ubuntu.com lucid-security/main Translation-en
Ign http://old-releases.ubuntu.com lucid-security/restricted Translation-en
Ign http://old-releases.ubuntu.com lucid-security/universe Translation-en
Fetched 0 B in 0s (0 B/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Updating repository information
WARNING: Failed to read mirror file
Ign http://archive.ubuntu.com precise InRelease
Get:1 http://archive.ubuntu.com precise-updates InRelease [55.7 kB]
Get:2 http://archive.ubuntu.com precise-security InRelease [55.7 kB]
Ign http://archive.ubuntu.com precise-updates InRelease
Ign http://archive.ubuntu.com precise-security InRelease
Hit http://archive.ubuntu.com precise Release.gpg
Ign http://archive.ubuntu.com precise-updates/main Sources/DiffIndex
Ign http://archive.ubuntu.com precise-updates/restricted Sources/DiffIndex
Ign http://archive.ubuntu.com precise-updates/universe Sources/DiffIndex
Ign http://archive.ubuntu.com precise-updates/main i386 Packages/DiffIndex
Ign http://archive.ubuntu.com precise-updates/restricted i386 Packages/DiffIndex
Ign http://archive.ubuntu.com precise-updates/universe i386 Packages/DiffIndex
Hit http://archive.ubuntu.com precise-updates/main TranslationIndex
Hit http://archive.ubuntu.com precise-updates/restricted TranslationIndex
Hit http://archive.ubuntu.com precise-updates/universe TranslationIndex
Ign http://archive.ubuntu.com precise-security/main Sources/DiffIndex
Ign http://archive.ubuntu.com precise-security/restricted Sources/DiffIndex
Ign http://archive.ubuntu.com precise-security/universe Sources/DiffIndex
Ign http://archive.ubuntu.com precise-security/main i386 Packages/DiffIndex
Ign http://archive.ubuntu.com precise-security/restricted i386 Packages/DiffIndex
Ign http://archive.ubuntu.com precise-security/universe i386 Packages/DiffIndex
Hit http://archive.ubuntu.com precise-security/main TranslationIndex
Hit http://archive.ubuntu.com precise-security/restricted TranslationIndex
Hit http://archive.ubuntu.com precise-security/universe TranslationIndex
Hit http://archive.ubuntu.com precise Release
Hit http://archive.ubuntu.com precise-updates/main Sources
Hit http://archive.ubuntu.com precise-updates/restricted Sources
Hit http://archive.ubuntu.com precise-updates/universe Sources
Hit http://archive.ubuntu.com precise-updates/main i386 Packages
Hit http://archive.ubuntu.com precise-updates/restricted i386 Packages
Hit http://archive.ubuntu.com precise-updates/universe i386 Packages
Hit http://archive.ubuntu.com precise-updates/main Translation-en
Hit http://archive.ubuntu.com precise-updates/restricted Translation-en
Hit http://archive.ubuntu.com precise-updates/universe Translation-en
Hit http://archive.ubuntu.com precise-security/main Sources
Hit http://archive.ubuntu.com precise-security/restricted Sources
Hit http://archive.ubuntu.com precise-security/universe Sources
Hit http://archive.ubuntu.com precise-security/main i386 Packages
Hit http://archive.ubuntu.com precise-security/restricted i386 Packages
Hit http://archive.ubuntu.com precise-security/universe i386 Packages
Hit http://archive.ubuntu.com precise-security/main Translation-en
Hit http://archive.ubuntu.com precise-security/restricted Translation-en
Hit http://archive.ubuntu.com precise-security/universe Translation-en
Hit http://archive.ubuntu.com precise/main Sources
Hit http://archive.ubuntu.com precise/restricted Sources
Hit http://archive.ubuntu.com precise/universe Sources
Hit http://archive.ubuntu.com precise/main i386 Packages
Hit http://archive.ubuntu.com precise/restricted i386 Packages
Hit http://archive.ubuntu.com precise/universe i386 Packages
Hit http://archive.ubuntu.com precise/main TranslationIndex
Hit http://archive.ubuntu.com precise/restricted TranslationIndex
Hit http://archive.ubuntu.com precise/universe TranslationIndex
Hit http://archive.ubuntu.com precise/main Translation-en
Hit http://archive.ubuntu.com precise/restricted Translation-en
Hit http://archive.ubuntu.com precise/universe Translation-en
Fetched 111 kB in 0s (0 B/s)
Checking package manager
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
Calculating the changes
Calculating the changes
Error authenticating some packages
It was not possible to authenticate some packages. This may be a
transient network problem. You may want to try again later. See below
for a list of unauthenticated packages.
accountsservice
apache2
<snip, many packages>
vim-runtime
vim-tiny
wget
xkb-data
Restoring original system state
Aborting
Reading package lists... Done
Building dependency tree
Reading state information... Done
Building data structures... Done
=== Command detached from window (Thu Jan 18 23:53:49 2018) ===
=== Command terminated with exit status 1 (Thu Jan 18 23:53:49 2018) ===
答案1
请注意,Ubuntu 10.04 的支持期限已经过了很久,Ubuntu 12.04 的生命周期也已经结束 6 个多月了。我猜他们已经关闭了大多数(如果不是全部的话)镜像。
由于这 7 年来发生了相当大的变化(配置文件甚至可能发生了变化!),如果您想保留程序和配置,我会这样做:
- 备份主目录和可能包含程序和配置的所有其他目录(例如,/etc,如果您手动修改配置,...)
- 全新安装 Ubuntu 16.04
- 从实时 CD/USB 启动、挂载 HDD 并使用备份覆盖主页。
- 测试它是否有效。
- 如果有效,重复 3-5。否则转到 6
- 调试。也许重新安装并复制较少的文件以排除故障。
- 如果有效,则返回 3。否则,返回 6。
很抱歉,如果您打算保留程序和配置,这将是一个非常痛苦和缓慢的过程。
简单的方法是(我会如何做):
- 备份您的文档、照片等。
- 列出您拥有的程序的清单。
- 全新安装 Ubuntu 16.04。
- 重新安装程序并手动恢复配置
答案2
我发现的一个解决方法是,您可以修改/etc/hosts
文件,以便archive.ubuntu.com
重定向到相同的 IP,这样old-releases.ubuntu.com
就足以令人满意do-release-upgrade
了。