Ubuntu apt-get install 问题: Could not resolve 'cn.archive.ubuntu.com'
2015-10-25 15:07
507 查看
网上很多朋友给了很多启发,其实都是配置问题,打开hosts将正向解析映射输入进去
解决方法:
从Error Message 上看来似乎是“cn.archive.ubuntu.com”域名解析出错。于是在Terminal 里Ping了一下这个域名,发现可以Ping 通。
ping cn.archive.ubuntu.com
PING mirror.neu.edu.cn (202.118.1.64) 56(84) bytes of data.
64 bytes from ftp2.neu.edu.cn (202.118.1.64): icmp_seq=1 ttl=45 time=86.3 ms
64 bytes from ftp2.neu.edu.cn (202.118.1.64): icmp_seq=2 ttl=45 time=100 ms
64 bytes from ftp2.neu.edu.cn (202.118.1.64): icmp_seq=3 ttl=45 time=86.8 ms
于是尝试通过修改 /etc/hosts 解决这个问题:
vi /etc/hosts
在文件末尾加入 “202.118.1.64 cn.archive.ubuntu.com”。
运行 “#/etc/init.d/networking restart” 重启网络。
运行 “sudo apt-get install xinit
解决方法:
从Error Message 上看来似乎是“cn.archive.ubuntu.com”域名解析出错。于是在Terminal 里Ping了一下这个域名,发现可以Ping 通。ping cn.archive.ubuntu.com
PING mirror.neu.edu.cn (202.118.1.64) 56(84) bytes of data.
64 bytes from ftp2.neu.edu.cn (202.118.1.64): icmp_seq=1 ttl=45 time=86.3 ms
64 bytes from ftp2.neu.edu.cn (202.118.1.64): icmp_seq=2 ttl=45 time=100 ms
64 bytes from ftp2.neu.edu.cn (202.118.1.64): icmp_seq=3 ttl=45 time=86.8 ms
于是尝试通过修改 /etc/hosts 解决这个问题:
vi /etc/hosts
在文件末尾加入 “202.118.1.64 cn.archive.ubuntu.com”。
运行 “#/etc/init.d/networking restart” 重启网络。
运行 “sudo apt-get install xinit
相关文章推荐
- 字符串转换成整数
- RQNOJ-PID39 / 饮食问题
- 《WEB前端黑客技术揭秘》基础知识(一)
- UML学习笔记之序列图
- poj2184Cow Exhibition【01背包 负数】
- linux配置网络配置
- Android 高级UI设计笔记05:使用TextView实现跑马灯的效果
- MySql 二进制类型
- poj 1182 食物链 并查集
- HDU 1114 Piggy-Bank 完全背包变形
- 设计模式——策略模式_2
- Struts2 和spring整合的 Action层托管问题
- 有关栈溢出漏洞的利用
- * &
- [ARM7--LPC2478]Memory Map
- z-index:9999在CSS中是什么意思
- 1016. 部分A+B (15)
- HDU 3364 Lanterns (高斯消元解开关问题)
- js引用类型之Object类型
- Linux中网络编程常用函数