本文主要是介绍docker download failed after attempts=6:dial tcp IP:Port i/o timeout,希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!
国内服务器使用docker拉取镜像出现下载超时问题,直觉问题是网络不通,ping相关的域名或IP发现是无法ping通的,鉴于此本文提供两种方法:
1)添加公开的docker加速代理(下文的代理一段时间后可能失效):
a)vim /etc/docker/daemon.json
{
"registry-mirrors":
[
"https://docker.mirrors.sjtug.sjtu.edu.cn",
"https://docker.m.daocloud.io",
"https://noohub.ru",
"https://huecker.io",
"https://dockerhub.timeweb.cloud",
"https://registry.cn-hangzhou.aliyuncs.com"
]
}
b)systemctl daemon-reload
c)systemctl restart docker
2)在可连接国外网络的vps或服务器上下载镜像,并迁移:
a) docker pull vulfocus/vulfocus:latest
b)docker save -o /home/test/vulfocus.tar vulfocus/vulfocus:latest
c)拷贝vulfocus.tar至目标服务器/home/test/vulfocus.tar
d)docker load -i /home/test/vulfocus.tar
参考连接:
1、Docker拉取镜像失败,download failed after attempts 6 IO Timeout,Docker拉取镜像失败,download failed after attempts 6 IO Timeout - 南瓜慢说官网
2、Docker Hub 镜像加速器,https://gist.github.com/y0ngb1n/7e8f16af3242c7815e7ca2f0833d3ea6
这篇关于docker download failed after attempts=6:dial tcp IP:Port i/o timeout的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!