[root@localhost ~]# docker run hello-word
Unable to find image 'hello-word:latest' locally
docker: Error response from daemon: Get https://registry-1.docker.io/v2/library/hello-word/manifests/latest: Get https://auth.docker.io/token?scope=repository%3Alibrary%2Fhello-word%3Apull&service=registry.docker.io: net/http: request canceled while waiting for connection (Client.Timeout exceeded while awaiting headers).
这个错误是镜像源的问题 ,修改成国内的镜像源就可以了
vim /etc/docker/daemon.json
{
"registry-mirrors":[
"http://hub-mirror.c.163.com" # 网易
]
}
[root@localhost ~]# systemctl start docker
Job for docker.service failed because the control process exited with error code. See "systemctl status docker.service" and "journalctl -xe" for details.
这个错误是 /etc/docker/daemon.json 文件配置错误,如果存在该文件且文件为空也会报这个错误