因为修改配置文件后执行 systemctl daemon-reload,导致docker启动失败.
报错:
[root@localhost ~]# systemctl status docker.service
● docker.service - Docker Application Container Engine
Loaded: loaded (/usr/lib/systemd/system/docker.service; disabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Fri 2017-12-01 04:56:50 EST; 8s ago
Docs: https://docs.docker.com
Process: 3793 ExecStart=/usr/bin/docker daemon -H fd:// (code=exited, status=1/FAILURE)
Main PID: 3793 (code=exited, status=1/FAILURE)
Dec 01 04:56:50 localhost.localdomain docker[3793]: time="2017-12-01T04:56:50.640327383-05:00" level=warning msg="devmapper: Base device already exists and has filesystem xfs on it. User specifi... be ignored."
Dec 01 04:56:50 localhost.localdomain docker[3793]: time="2017-12-01T04:56:50.646133768-05:00" level=info msg="[graphdriver] using prior storage driver \"devicemapper\""
Dec 01 04:56:50 localhost.localdomain docker[3793]: time="2017-12-01T04:56:50.648809844-05:00" level=info msg="Graph migration to content-addressability took 0.00 seconds"
Dec 01 04:56:50 localhost.localdomain docker[3793]: time="2017-12-01T04:56:50.655689105-05:00" level=info msg="Firewalld running: false"
Dec 01 04:56:50 localhost.localdomain docker[3793]: time="2017-12-01T04:56:50.713593692-05:00" level=info msg="Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon optio...d IP address"
Dec 01 04:56:50 localhost.localdomain docker[3793]: time="2017-12-01T04:56:50.742934960-05:00" level=fatal msg="Error starting daemon: Error initializing network controller: Error creating default \"bridge\"...
Dec 01 04:56:50 localhost.localdomain systemd[1]: docker.service: main process exited, code=exited, status=1/FAILURE
Dec 01 04:56:50 localhost.localdomain systemd[1]: Failed to start Docker Application Container Engine.
Dec 01 04:56:50 localhost.localdomain systemd[1]: Unit docker.service entered failed state.
Dec 01 04:56:50 localhost.localdomain systemd[1]: docker.service failed.
解决办法:
rm -rf /var/lib/docker/network/files/*
重启 :
systemctl restart docker
网友评论