Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I'm trying out Ubuntu Server 12.04 on a home server and the update is not working. Not sure why.

I've done a sudo su and apt-get update. After which I get the following:

Err gb.archive.ubuntu.com precise InRelease

Err gb.archive.ubuntu.com precise-updates InRelease

Err gb.archive.ubuntu.com precise-backports InRelease

Err security.ubuntu.com precise-security InRelease

Err archive.canonical.com precise InRelease

Err extras.ubuntu.com precise InRelease

Err gb.archive.ubuntu.com precise Release.gpg
  Temporary failure resolving âgb.archive.ubuntu.comâ
Err gb.archive.ubuntu.com precise-updates Release.gpg
  Temporary failure resolving âgb.archive.ubuntu.comâ
Err security.ubuntu.com precise-security Release.gpg
  Temporary failure resolving âsecurity.ubuntu.comâ
Err archive.canonical.com precise Release.gpg
  Temporary failure resolving âarchive.canonical.comâ
Err gb.archive.ubuntu.com precise-backports Release.gpg
  Temporary failure resolving âgb.archive.ubuntu.comâ
Err extras.ubuntu.com precise Release.gpg
  Temporary failure resolving âextras.ubuntu.comâ
Reading package lists... Done
W: Failed to fetch gb.archive.ubuntu.com/ubuntu/dists/precise/InRelease

W: Failed to fetch gb.archive.ubuntu.com/ubuntu/dists/precise-updates/InRelease

W: Failed to fetch gb.archive.ubuntu.com/ubuntu/dists/precise-backports/InRelease

W: Failed to fetch security.ubuntu.com/ubuntu/dists/precise-security/InRelease

W: Failed to fetch archive.canonical.com/ubuntu/dists/precise/InRelease

W: Failed to fetch extras.ubuntu.com/ubuntu/dists/precise/InRelease

W: Failed to fetch gb.archive.ubuntu.com/ubuntu/dists/precise/Release.gpg  Temporary failure resolving âgb.archive.ubuntu.comâ

W: Failed to fetch gb.archive.ubuntu.com/ubuntu/dists/precise-updates/Release.gpg  Temporary failure resolving âgb.archive.ubuntu.comâ

W: Failed to fetch gb.archive.ubuntu.com/ubuntu/dists/precise-backports/Release.gpg  Temporary failure resolving âgb.archive.ubuntu.comâ

W: Failed to fetch security.ubuntu.com/ubuntu/dists/precise-security/Release.gpg  Temporary failure resolving âsecurity.ubuntu.comâ

W: Failed to fetch archive.canonical.com/ubuntu/dists/precise/Release.gpg  Temporary failure resolving âarchive.canonical.comâ

W: Failed to fetch extras.ubuntu.com/ubuntu/dists/precise/Release.gpg  Temporary failure resolving âextras.ubuntu.comâ

W: Some index files failed to download. They have been ignored, or old ones used instead.

There are some odd characters which do not appear in the /etc/apt/sources.list

Any ideas anyone? NB I've had to take out the http:// as I couldn't post otherwise.

TIA

Dave

share|improve this question
    
What kind of quotes surround the URLs in sources.list? –  hexafraction Sep 18 '12 at 20:10
    
There are no quotes of any kind surrounding the URLs in the /etc/apt/sources.list –  bluekwak Sep 21 '12 at 17:56
1  
Please add the output from hd /etc/sources.list to your question. What happens if you enter the command ping gb.archive.ubuntu.com? –  John S Gruber Sep 21 '12 at 19:41

2 Answers 2

I think the odd characters are a result of your locale settings but I don't think this is your problem here.

Temporary failure resolving âgb.archive.ubuntu.comâ

This howerver suggest that your machine is using a DNS resolver configured in /etc/resolv.conf that cannot resolve gb.archive.ubuntu.com

When you experience this error, check that the command host gb.archive.ubuntu.com returns a list of IP addresses such as this:

gb.archive.ubuntu.com has address 194.169.254.10
gb.archive.ubuntu.com has address 91.189.92.156
gb.archive.ubuntu.com has address 91.189.92.177
gb.archive.ubuntu.com has address 91.189.92.200
gb.archive.ubuntu.com has address 91.189.92.201
gb.archive.ubuntu.com has address 91.189.92.202
gb.archive.ubuntu.com has IPv6 address 2a01:450:10:1::10

If not, look at the resolver configuration in the before mentioned file - it should contain at least one line with nameserver x.x.x.x where x.x.x.x is an IP address of your resolver.

If it's there, you can temporarily use a public resolver which is known to work:

echo 'nameserver 8.8.8.8' > /etc/resolv.conf

and see if it works then. If that doesn't help, you might have a more serious networking problem, but this should get you started.

share|improve this answer

My problem was in the interfaces file at /etc/network/interfaces. In Ubuntu 12.04 you must have a dns-nameservers line e.g.

dns-nameservers 8.8.8.8 8.8.4.4

edit this file and replace the 8.8.8.8 8.8.4.4 with your name servers IPs separating each IP with a space. If this line is not present add it. Then restart your networking:

/etc/init.d/networking restart

In this case this solves problems with the DNS.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.