Centos7 dockers下载镜像报错: Get https://registry-1.docker.io/v2/: net/http: request canceled

docker: Error response from daemon: Get https://registry-1.docker.io/v2/: net/http: request canceled (Client.Timeout exceeded while awaiting headers).

解决方案:
1)创建daemon.json文件
vim /etc/docker/daemon.json
2) 写入

{
    "registry-mirrors":["https://docker.mirrors.ustc.edu.cn"]
}

3)重启:

[root@km docker]# systemctl daemon-reload 
[root@km docker]# systemctl restart docker

4)问题解决。

版权声明:本文为CSDN博主「liubocsn」的原创文章,遵循CC 4.0 BY-SA
原文链接:https://blog.csdn.net/liubocsn/article/details/91979333

你可能感兴趣的:(linux)