Docker服务启动报错:Job for docker.service failed because the control process exited with error code.

docker服务无法启动,启动报错信息:Job for docker.service failed because the control process exited with error code. See “systemctl status docker.service” and “journalctl -xe” for details.

如果忽略错误进行操作,就会出现:Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

因为docker就没有启动成功

解决方案:

1
2
3
4
[root@szl harbor]# vim /etc/sysconfig/docker-storage
//配置文件改为
DOCKER_STORAGE_OPTIONS="–selinux-enabled --log-driver=journald --signature-verification
=false"

写入指定参数:

1
2
3
4
[root@szl harbor]# vim /etc/docker/daemon.json
{
"insecure-registries": ["http://192.168.80.6:85"],"storage-driver": "devicemapper"
}

然后重启docker服务

1
2
3
systemctl start docker
systemctl enable docker
systemctl restart docker

没有出现错误信息,说明问题已经解决