ERROR: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon runn
systemctl status docker 居然显示的是正常状态查询系统日志发现应该是错误退出的docker导致的
·
docker学习问题记录
打开docker遇到这种情况
ERROR: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?
奇怪的是:systemctl restart docker 后作用 systemctl restart docker.service
systemctl status docker 居然显示的是正常状态
查询系统日志发现应该是错误退出的docker导致的
于是使用systemctl stop docker.service
Warning: Stopping docker.service, but it can still be activated by:
docker.socket
虽然是warning,还是去研究一下原因
查询得到解释:
这是docker在关闭状态下被访问自动唤醒机制,很人性化,即这时再执行任意docker命令会直接启动
执行 systemctl stop docker
后再执行systemctl stop docker.socket
即可
成功。重新systemctl start docker.service
docker不再报错
更多推荐
已为社区贡献1条内容
所有评论(0)