症狀
之前一直使用的debian環境,今天突然aptitude update失敗,錯誤信息如下:
root@ Tue Oct 28 20:26:35 ~ $ aptitude update Err http://mirrors.163.com wheezy Release.gpg Could not resolve 'mirrors.163.com' Err http://mirrors.163.com wheezy-proposed-updates Release.gpg Could not resolve 'mirrors.163.com' Err http://mirrors.163.com wheezy-updates Release.gpg Could not resolve 'mirrors.163.com' Err http://mirrors.163.com wheezy/updates Release.gpg Could not resolve 'mirrors.163.com' W: Failed to fetch http://mirrors.163.com/debian/dists/wheezy/Release.gpg: Could not resolve 'mirrors.163.com' W: Failed to fetch http://mirrors.163.com/debian/dists/wheezy-proposed-updates/Release.gpg: Could not resolve 'mirrors.163.com' W: Failed to fetch http://mirrors.163.com/debian/dists/wheezy-updates/Release.gpg: Could not resolve 'mirrors.163.com' W: Failed to fetch http://mirrors.163.com/debian-security/dists/wheezy/updates/Release.gpg: Could not resolve 'mirrors.163.com' W: Some index files failed to download. They have been ignored, or old ones used instead.
但網絡是通的:
root@ Tue Oct 28 20:31:54 ~ $ ping 8.8.8.8 PING 8.8.8.8 (8.8.8.8) 56(84) bytes of data. 64 bytes from 8.8.8.8: icmp_req=2 ttl=128 time=37.5 ms 64 bytes from 8.8.8.8: icmp_req=3 ttl=128 time=45.9 ms 64 bytes from 8.8.8.8: icmp_req=4 ttl=128 time=36.9 ms ^C --- 8.8.8.8 ping statistics --- 4 packets transmitted, 3 received, 25% packet loss, time 3010ms rtt min/avg/max/mdev = 36.975/40.156/45.922/4.084 ms root@ Tue Oct 28 20:39:38 ~ $
環境說明
系統版本:
root@ Mon Oct 27 17:10:30 /usr/share/vim/vim73/colors $ uname -a Linux Ulric 3.2.0-4-686-pae #1 SMP Debian 3.2.63-2 i686 GNU/Linux
軟件源
root@ Tue Oct 28 20:26:45 ~ $ cat /etc/apt/sources.list #deb http://ftp.debian.org/debian wheezy main contrib non-free #deb-src http://ftp.debian.org/debian wheezy main contrib non-free deb http://mirrors.163.com/debian wheezy main non-free contrib deb-src http://mirrors.163.com/debian wheezy main non-free contrib deb http://mirrors.163.com/debian wheezy-proposed-updates main contrib non-free deb-src http://mirrors.163.com/debian wheezy-proposed-updates main contrib non-free deb http://mirrors.163.com/debian wheezy-updates main contrib non-free deb-src http://mirrors.163.com/debian wheezy-updates main contrib non-free deb http://mirrors.163.com/debian-security wheezy/updates main contrib non-free deb-src http://mirrors.163.com/debian-security wheezy/updates main contrib non-free
解決方案:
經過baidu的幫助,終於找到原因了:
http://tieba.baidu.com/p/2110278694
今天早上開了EasyConnect(http://baike.baidu.com/view/6614495.htm?fr=aladdin),用來跳轉到其它服務器。個人猜測是代理導致本地的公鑰驗證失敗,從而導致update失敗。
把EasyConnect關閉后,就順利update了。