apt-get: Could not resolve 'archive.ubuntu.com'
2015-03-05 22:48
591 查看
最近在搭建 Vagrant 服务器的时候, 使用
sudo apt-get update的时候出现了访问错误
Err http://archive.ubuntu.com trusty InRelease Err http://archive.ubuntu.com trusty-updates InRelease Err http://security.ubuntu.com trusty-security InRelease Err http://archive.ubuntu.com trusty Release.gpg Could not resolve 'archive.ubuntu.com' Err http://security.ubuntu.com trusty-security Release.gpg Could not resolve 'security.ubuntu.com' Err http://archive.ubuntu.com trusty-updates Release.gpg Could not resolve 'archive.ubuntu.com' Reading package lists... Done W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/trusty/InRelease W: Failed to fetch http://archive.ubuntu.com/ubuntu/dists/trusty-updates/InRelease[/code]
使用ping www.baidu.com发现可以返回数据, 但是ping archive.Ubuntu.com则没有反应, host 机器是有访问返回的.
修正方法是:
step 1: 修改host/etc/hosts
添加如下映射91.189.91.93 archive.ubuntu.com 91.189.91.93 security.ubuntu.com
step 2: 重启network服务$ /etc/init.d/networking restart
相关文章推荐
- Ubuntu apt-get install 问题: Could not resolve 'cn.archive.ubuntu.com'
- apt-get: Could not resolve 'archive.ubuntu.com'
- apt-get: Could not resolve 'archive.ubuntu.com'解决方法
- apt-get: Could not resolve 'archive.ubuntu.com'
- Ubuntu apt-get install 问题: Could not resolve 'cn.archive.ubuntu.com'
- Ubuntu下的Ubuntu虚拟机--源配置问题:apt-get update 显示could not resolve 'mirrors.163.com'
- ubuntu下sudo apt-get update出错:E: Could not get lock /var/lib/apt/lists/lock - open……
- Ubuntu Could not get lock /var/lib/apt/lists/lock - open (11: Resource temporarily unavailable)
- 关于Ubuntu中执行apt-get和get出现Could not get lock /var/lib/dpkg/lock解决方案
- Ubuntu使用apt-get install 安装软件时报错:could not get lock /var/lib/dpkg/lock -open
- [Ubuntu] Solution: "E: Could Not Get Lock /var/lib/apt/lists/lock"
- ubuntu系统刚安装结束时运行apt-get出现error:could not get lock /var/apt/lists/lock
- Ubuntu上出现无法获得锁“Could not get lock /var/lib/apt/lists/lock”问题的解决
- ubuntu的安装软件问题:E:Could not get lock /var/lib/apt/lists/lock - open (11: Resource temporarily unavaila
- apt-get update 失败 ubuntu:Tempory failure resolving 'cn.archive.ubuntu.com ubuntu
- Ubuntu apt-get 故障:Could not get lock
- 在Ubuntu中,有时候运用sudo apt-get install 安装软件时,会出现一下的情况 E: Could not get lock /var/lib/dpkg/lock - open
- ubuntu常见错误--Could not get lock /var/lib/dpkg/lock解决 通过终端安装程序sudo apt-get install xxx时出错: E: Coul
- ubuntu apt-get 解锁:Could not get lock /var/lib/apt/lists/lock
- Could not get lock/var/lib/apt/lists错误的处理