Docker on Ubuntu 14.04 - Could not resolve ''


I’ve having an issue with Docker 1.1.1 on my Ubuntu 14.04 VPS in the London zone.

I’m getting the following output when executing docker run --name="test" ubuntu:14.04 apt-get update,

Err trusty InRelease
Err trusty-updates InRelease
Err trusty-security InRelease
Err trusty Release.gpg
  Could not resolve ''
Err trusty-updates Release.gpg
  Could not resolve ''
Err trusty-security Release.gpg
  Could not resolve ''
Reading package lists...
W: Failed to fetch  

W: Failed to fetch  

W: Failed to fetch  

W: Failed to fetch  Could not resolve ''

W: Failed to fetch  Could not resolve ''

W: Failed to fetch  Could not resolve ''

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

I’ve done some Googling, but couldn’t find anything that was related to this specifically. /etc/resolv.conf contains the same contents as the parent VPS, which are,

# Dynamic resolv.conf(5) file for glibc resolver(3) generated by resolvconf(8)
nameserver 2001:4860:4860::8844
nameserver 2001:4860:4860::8888

Anyone have any ideas? Possibly IPv6 related as per


Submit an answer

This textbox defaults to using Markdown to format your answer.

You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

Sign In or Sign Up to Answer

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

Want to learn more? Join the DigitalOcean Community!

Join our DigitalOcean community of over a million developers for free! Get help and share knowledge in Q&A, subscribe to topics of interest, and get courses and tools that will help you grow as a developer and scale your project or business.

does this help: ? Apparently docker cannot resolv hostnames with IPv6 nameservers

As suspected, this is due to IPv6 being enabled on my droplet. See here.

For now, my fix was to remove the IPv6 nameservers from my /etc/resolv.conf. You can also use the --dns argument when running docker.