Please help me with this. I am getting "No address associated with the Host Name" error when I run "sudo apt-get update" command from the console
Asked
Active
Viewed 1,547 times
0
-
see [the answer](http://askubuntu.com/questions/199541/solving-the-ubuntu-12-04-update-error-5-no-address-associated-with-hostname) – David Jan 02 '14 at 11:55
-
I think this is to do something todo with name resolution. I can ping yahoo ip address but can not ping Yaho thru its name... Any Idea? – Neil Jan 02 '14 at 12:13
1 Answers
0
Check your /etc/resolv.conf
At least one from "nameserver x.x.x.x" ipaddrs should answer to pings.
If none, then try to ping 8.8.8.8
If 8.8.8.8 answers, then add it to resolv.conf:
echo nameserver 8.8.8.8 >> /etc/resolv.conf
If not, then check your internet connection.
Also check your APT sources:
grep -rv '^$' /etc/apt/sources.list* | grep -v ':#'
May be they are invalid and not reachable.
user2743554
- 361
- 3
- 8