J'essaie d'installer des packages mais il ne peut pas atteindre de DNS mais manuellement lorsque j'ajoute DNS à IP, cela fonctionne, mais le dernier enregistrement DNS échoue toujours.
# cat /etc/hosts
127.0.0.1 localhost
127.0.1.1 Sun-Alienware-X51
91.189.91.15 us.archive.ubuntu.com
91.189.92.152 extras.ubuntu.com
91.189.92.184 security.ubuntu.com
91.189.94.156 ubuntu.com
# The following lines are desirable for IPv6 capable hosts
::1 ip6-localhost ip6-loopback
fe00::0 ip6-localnet
ff00::0 ip6-mcastprefix
ff02::1 ip6-allnodes
ff02::2 ip6-allrouters
# Dig ubuntu.com
; <<>> Dig 9.8.1-P1 <<>> ubuntu.com
;; global options: +cmd
;; connection timed out; no servers could be reached
#/var/tmp/dist# apt-get update
Ign http://us.archive.ubuntu.com precise InRelease
Ign http://us.archive.ubuntu.com precise-updates InRelease
Ign http://us.archive.ubuntu.com precise-backports InRelease
Err http://extras.ubuntu.com precise InRelease
Err http://extras.ubuntu.com precise Release.gpg
Unable to connect to extras.ubuntu.com:http:
Hit http://us.archive.ubuntu.com precise Release.gpg
Hit http://us.archive.ubuntu.com precise-updates Release.gpg
Ign http://security.ubuntu.com precise-security InRelease
Hit http://us.archive.ubuntu.com precise-backports Release.gpg
Hit http://us.archive.ubuntu.com precise Release
Hit http://security.ubuntu.com precise-security Release.gpg
Hit http://us.archive.ubuntu.com precise-updates Release
Hit http://us.archive.ubuntu.com precise-backports Release
Hit http://us.archive.ubuntu.com precise/main Sources
Hit http://us.archive.ubuntu.com precise/restricted Sources
Hit http://us.archive.ubuntu.com precise/universe Sources
Hit http://us.archive.ubuntu.com precise/multiverse Sources
Hit http://us.archive.ubuntu.com precise/main AMD64 Packages
Hit http://security.ubuntu.com precise-security Release
Hit http://us.archive.ubuntu.com precise/restricted AMD64 Packages
Hit http://us.archive.ubuntu.com precise/universe AMD64 Packages
Hit http://us.archive.ubuntu.com precise/multiverse AMD64 Packages
Hit http://us.archive.ubuntu.com precise/main i386 Packages
Hit http://us.archive.ubuntu.com precise/restricted i386 Packages
Hit http://us.archive.ubuntu.com precise/universe i386 Packages
Hit http://us.archive.ubuntu.com precise/multiverse i386 Packages
Hit http://us.archive.ubuntu.com precise/main TranslationIndex
Hit http://us.archive.ubuntu.com precise/multiverse TranslationIndex
Hit http://us.archive.ubuntu.com precise/restricted TranslationIndex
Hit http://us.archive.ubuntu.com precise/universe TranslationIndex
Hit http://us.archive.ubuntu.com precise-updates/main Sources
Hit http://us.archive.ubuntu.com precise-updates/restricted Sources
Hit http://us.archive.ubuntu.com precise-updates/universe Sources
Hit http://us.archive.ubuntu.com precise-updates/multiverse Sources
Hit http://us.archive.ubuntu.com precise-updates/main AMD64 Packages
Hit http://us.archive.ubuntu.com precise-updates/restricted AMD64 Packages
Hit http://us.archive.ubuntu.com precise-updates/universe AMD64 Packages
Hit http://us.archive.ubuntu.com precise-updates/multiverse AMD64 Packages
Hit http://us.archive.ubuntu.com precise-updates/main i386 Packages
Hit http://us.archive.ubuntu.com precise-updates/restricted i386 Packages
Hit http://us.archive.ubuntu.com precise-updates/universe i386 Packages
Hit http://us.archive.ubuntu.com precise-updates/multiverse i386 Packages
Hit http://us.archive.ubuntu.com precise-updates/main TranslationIndex
Hit http://security.ubuntu.com precise-security/main Sources
Hit http://us.archive.ubuntu.com precise-updates/multiverse TranslationIndex
Hit http://us.archive.ubuntu.com precise-updates/restricted TranslationIndex
Hit http://us.archive.ubuntu.com precise-updates/universe TranslationIndex
Hit http://us.archive.ubuntu.com precise-backports/main Sources
Hit http://us.archive.ubuntu.com precise-backports/restricted Sources
Hit http://us.archive.ubuntu.com precise-backports/universe Sources
Hit http://us.archive.ubuntu.com precise-backports/multiverse Sources
Hit http://us.archive.ubuntu.com precise-backports/main AMD64 Packages
Hit http://us.archive.ubuntu.com precise-backports/restricted AMD64 Packages
Hit http://us.archive.ubuntu.com precise-backports/universe AMD64 Packages
Hit http://us.archive.ubuntu.com precise-backports/multiverse AMD64 Packages
Hit http://us.archive.ubuntu.com precise-backports/main i386 Packages
Hit http://us.archive.ubuntu.com precise-backports/restricted i386 Packages
Hit http://us.archive.ubuntu.com precise-backports/universe i386 Packages
Hit http://us.archive.ubuntu.com precise-backports/multiverse i386 Packages
Hit http://security.ubuntu.com precise-security/restricted Sources
Hit http://security.ubuntu.com precise-security/universe Sources
Hit http://security.ubuntu.com precise-security/multiverse Sources
Hit http://security.ubuntu.com precise-security/main AMD64 Packages
Hit http://security.ubuntu.com precise-security/restricted AMD64 Packages
Hit http://us.archive.ubuntu.com precise-backports/main TranslationIndex
Hit http://us.archive.ubuntu.com precise-backports/multiverse TranslationIndex
Hit http://us.archive.ubuntu.com precise-backports/restricted TranslationIndex
Hit http://us.archive.ubuntu.com precise-backports/universe TranslationIndex
Hit http://us.archive.ubuntu.com precise/main Translation-en
Hit http://us.archive.ubuntu.com precise/multiverse Translation-en
Hit http://us.archive.ubuntu.com precise/restricted Translation-en
Hit http://us.archive.ubuntu.com precise/universe Translation-en
Hit http://us.archive.ubuntu.com precise-updates/main Translation-en
Hit http://us.archive.ubuntu.com precise-updates/multiverse Translation-en
Hit http://us.archive.ubuntu.com precise-updates/restricted Translation-en
Hit http://us.archive.ubuntu.com precise-updates/universe Translation-en
Hit http://us.archive.ubuntu.com precise-backports/main Translation-en
Hit http://us.archive.ubuntu.com precise-backports/multiverse Translation-en
Hit http://us.archive.ubuntu.com precise-backports/restricted Translation-en
Hit http://us.archive.ubuntu.com precise-backports/universe Translation-en
Hit http://security.ubuntu.com precise-security/universe AMD64 Packages
Hit http://security.ubuntu.com precise-security/multiverse AMD64 Packages
Hit http://security.ubuntu.com precise-security/main i386 Packages
Hit http://security.ubuntu.com precise-security/restricted i386 Packages
Hit http://security.ubuntu.com precise-security/universe i386 Packages
Hit http://security.ubuntu.com precise-security/multiverse i386 Packages
Hit http://security.ubuntu.com precise-security/main TranslationIndex
Hit http://security.ubuntu.com precise-security/multiverse TranslationIndex
Hit http://security.ubuntu.com precise-security/restricted TranslationIndex
Hit http://security.ubuntu.com precise-security/universe TranslationIndex
Hit http://security.ubuntu.com precise-security/main Translation-en
Hit http://security.ubuntu.com precise-security/multiverse Translation-en
Hit http://security.ubuntu.com precise-security/restricted Translation-en
Hit http://security.ubuntu.com precise-security/universe Translation-en
Reading package lists... Done
W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/precise/InRelease
W: Failed to fetch http://extras.ubuntu.com/ubuntu/dists/precise/Release.gpg Unable to connect to extras.ubuntu.com:http:
W: Some index files failed to download. They have been ignored, or old ones used instead.
#/var/tmp/dist# ping extras.ubuntu.com
PING extras.ubuntu.com (91.189.92.152) 56(84) bytes of data.
64 bytes from extras.ubuntu.com (91.189.92.152): icmp_req=1 ttl=50 time=111 ms
64 bytes from extras.ubuntu.com (91.189.92.152): icmp_req=2 ttl=50 time=111 ms
^C
--- extras.ubuntu.com ping statistics ---
2 packets transmitted, 2 received, 0% packet loss, time 1001ms
rtt min/avg/max/mdev = 111.371/111.614/111.858/0.413 ms
Quels serveurs DNS utilisez-vous? Ouvrez "Paramètres système" et allez dans "Réseau". Vous pouvez modifier les serveurs DNS à partir de là. Votre FAI doit avoir des serveurs que vous pouvez utiliser, mais vous pouvez également essayer autre chose. Je sais que Google a deux serveurs à 8.8.8.8
et 8.8.4.4
ça marche pour moi.
Pour déboguer les problèmes DNS, vous pouvez utiliser Dig et ping. Essayez ces commandes:
Dig <some-domain.com>
ping <DNS-server-IP-address>
Les valeurs peuvent être, par exemple:
Dig ubuntu.com
ping 8.8.8.8
Si le changement de serveurs DNS ne fonctionne pas, publiez ici la sortie des commandes ci-dessus.