sudo apt-get update
返回一些错误:
W: Failed to fetch http:// archive.ubuntu.com/ubuntu/dists/trusty/Release Unable to find expected entry ‘restricted/source/Sources’ in Release file (Wrong sources.list entry or malformed file)
W: Failed to fetch http:// archive.ubuntu.com/ubuntu/dists/trusty-security/main/binary-amd64/Packages Hash Sum mismatch
W: Failed to fetch http:// archive.ubuntu.com/ubuntu/dists/trusty-security/universe/binary-amd64/Packages Hash Sum mismatch
W: Failed to fetch http:// archive.ubuntu.com/ubuntu/dists/trusty-security/main/binary-i386/Packages Hash Sum mismatch
W: Failed to fetch http:// archive.ubuntu.com/ubuntu/dists/trusty-security/main/i18n/Translation-en Hash Sum mismatch
E: Some index files Failed to download. They have been ignored,or old ones used instead.
它似乎发生在ubuntu官方回购中.知道为什么吗?
有关信息,我的sources.list如下:
#----------------------------------------------------------# # OFFICIAL UBUNTU REPO # #----------------------------------------------------------# ###### Ubuntu Main Repos deb http://archive.ubuntu.com/ubuntu trusty main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu trusty main restricted universe multiverse ###### Ubuntu Update Repos deb http://archive.ubuntu.com/ubuntu trusty-security main restricted universe multiverse deb http://archive.ubuntu.com/ubuntu trusty-updates main restricted universe multiverse deb http://archive.ubuntu.com/ubuntu trusty-proposed main restricted universe multiverse deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu trusty-security main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu trusty-updates main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu trusty-proposed main restricted universe multiverse deb-src http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse ###### Ubuntu Partner Repo deb http://archive.canonical.com/ubuntu trusty partner deb-src http://archive.canonical.com/ubuntu trusty partner ###### Ubuntu Extras Repo deb http://extras.ubuntu.com/ubuntu trusty main deb-src http://extras.ubuntu.com/ubuntu trusty main #------------------------------------------------------------------------------# # UNOFFICIAL UBUNTU REPOS # #------------------------------------------------------------------------------# ###### 3rd Party Binary Repos #### MongoDB - http://www.mongodb.org/ ## Run this command: sudo apt-key adv --keyserver keyserver.ubuntu.com --recv 7F0CEB10 deb http://downloads-distro.mongodb.org/repo/ubuntu-upstart dist 10gen
这是我的resolv.conf:
domain local search local nameserver 8.8.8.8 nameserver 8.8.4.4
我使用谷歌的公共dns(https://developers.google.com/speed/public-dns/)
然后尝试apt-get update