[root@k8smaster ~]# docker search busybox
Error response from daemon: Get https://index.docker.io/v1/search?q=busybox&n=25: dial tcp: lookup index.docker.io on [::1]:53: read udp [::1]:44869->[::1]:53: read: connection refused

解决办法:

[root@k8smaster ~]# vim /etc/resolv.conf

#add these lines on top and above one for home router…
nameserver 8.8.8.8
nameserver 8.8.4.4

sudo systemctl daemon-reload
sudo systemctl restart docker
sudo systemctl status docker

[root@k8smaster ~]# docker pull busybox
Using default tag: latest
latest: Pulling from library/busybox
24fb2886d6f6: Pull complete
Digest: sha256:52f73a0a43a16cf37cd0720c90887ce972fe60ee06a687ee71fb93a7ca601df7
Status: Downloaded newer image for busybox:latest
docker.io/library/busybox:latest

成功拉取镜像!

Logo

K8S/Kubernetes社区为您提供最前沿的新闻资讯和知识内容

更多推荐