首页 > 代码库 > 解决`docker pull`被 reset 的问题

解决`docker pull`被 reset 的问题

 

解决方法:

 

  1. 找到其它可用 IP :

 

$ dig auth.docker.io

; <<>> DiG 9.10.4-P6-RedHat-9.10.4-4.P6.fc25 <<>> auth.docker.io
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 7119
;; flags: qr rd ra; QUERY: 1, ANSWER: 3, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 4096
;; QUESTION SECTION:
;auth.docker.io.			IN	A

;; ANSWER SECTION:
auth.docker.io.		60	IN	A	34.193.147.40
auth.docker.io.		60	IN	A	50.17.62.194
auth.docker.io.		60	IN	A	52.5.246.212

;; Query time: 130 msec
;; SERVER: *.*.*.*#53(.*.*.*.*)
;; WHEN: Tue Mar 07 11:03:29 CST 2017
;; MSG SIZE  rcvd: 91

 

  1. /etc/hosts强制 docker.io 相关的域名解析到其它可用 IP :

 

# /etc/hosts
34.193.147.40 registry-1.docker.io auth.docker.io


https://www.v2ex.com/t/345517

解决`docker pull`被 reset 的问题