Tuesday, January 16, 2018

dial tcp lookup index.docker.io connection refused

I was trying to

docker run -d -p 8081:8081 --name nexus sonatype/nexus3

and I got the scary error "dial tcp lookup index.docker.io connection refused"

googling around, they suggest to "reset the docker settings to factory defaults." .
Everybody keeps repeating this mantra "reset to factory defaults" but nobody explains how to do it on Linux. I hate it. So I could not figure out what to do. iptables -F didn't work.

Someone mentions to add index.docker.io to the /etc/hosts file because the DNS playing tricks and truncate.. scary....

Eventually I rebooted the machine and it all works again. I only wish that Docker Inc stopped playing with docker and kept it stable. I hate them. They are destroying a great product.

No comments: