即使不是发布日,从主 Ubuntu 存档下载也很慢,我如何让 apt-get 自动使用离我很近的镜像?
与上面的注释相反,我还没有找到我的问题的答案。
我已经阅读了近十二个 apt-get 更新问题,其中大部分来自 askubuntu.com,其中包含“无法获取”错误,并尝试了在那里回答的解决方案。不幸的是,没有一个奏效。我最近在笔记本电脑上安装了 Ubuntu 12.04,与 Windows 7 一起双启动。当我尝试时
sudo apt-get update
Run Code Online (Sandbox Code Playgroud)
在终端上,以下不断发生:
Err http://ph.archive.ubuntu.com precise InRelease
Err http://ph.archive.ubuntu.com precise-updates InRelease
Err http://ph.archive.ubuntu.com precise-backports InRelease
Err http://ph.archive.ubuntu.com precise Release.gpg
Unable to connect to ph.archive.ubuntu.com:http: [IP: 91.189.92.177 80]
Err http://ph.archive.ubuntu.com precise-updates Release.gpg
Unable to connect to ph.archive.ubuntu.com:http: [IP: 91.189.92.177 80]
Err http://ph.archive.ubuntu.com precise-backports Release.gpg
Unable to connect to ph.archive.ubuntu.com:http: [IP: 91.189.92.177 80]
Err http://extras.ubuntu.com precise InRelease
Err http://extras.ubuntu.com precise Release.gpg
Unable to connect to extras.ubuntu.com:http:
Err http://security.ubuntu.com precise-security InRelease
Err …Run Code Online (Sandbox Code Playgroud) 我正在尝试做
sudo apt-get update
Run Code Online (Sandbox Code Playgroud)
但我收到以下错误:
W: Failed to fetch http://ftp.udc.es/ubuntu/dists/trusty/Release Unable to find expected entry 'main/binary-x8-64/Packages' in Release file (Wrong sources.list entry or malformed file)
Run Code Online (Sandbox Code Playgroud)
我已经尝试重置 /etc/apt/sources.list 就像这里建议的那样:
并且还尝试选择另一台服务器来下载更新:Ubuntu 12.04 上的“sudo apt-get update”错误
但我一直收到同样该死的错误信息。有任何想法吗?
正如评论中所问,做:
$ grep -R ftp.udc.es /etc/apt/sources.list*
/etc/apt/sources.list:deb http://ftp.udc.es/ubuntu/ trusty main universe
/etc/apt/sources.list.save:deb http://ftp.udc.es/ubuntu/ trusty main
$ cat sources.list
## See sources.list(5) for more information, especialy
# Remember that you can only use http, ftp or file URIs
deb http://ftp.udc.es/ubuntu/ trusty main universe
# CDROMs …Run Code Online (Sandbox Code Playgroud)