解决方法0:
$ ps axf | grep docker | grep -v grep | awk \'{print \"kill -9 \" $1}\' | sudo sh
$ nohup dockerd &
解决方法1:
$ ps axf | grep docker | grep -v grep | awk \'{print \"kill -9 \" $1}\' | sudo sh
$ sudo systemctl start docker
解决方法2:
Same issue here. Seems the json conf can’t override the systemd one, which is a bug, IMHO.
In summary
First, delete the hosts entry from the json file.
Create a conf file in /etc/systemd/system/docker.service.d, e.g
/etc/systemd/system/docker.service.d/hosts.conf
Configure the start with the extra options. In my case, ubuntu with systemd, it uses file discovery sockets (fd://), and I added a tcp one.
[Service]
ExecStart=
ExecStart=/usr/bin/dockerd -H fd:// -H tcp://0.0.0.0:2736
Note the empty ExecStart. Seems to be an issue with how systemd declares units.
Save, reload
systemctl daemon-reload
and restart the service
systemctl restart docker.service
You should see the new settings
# systemctl status docker.service
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
Drop-In: /etc/systemd/system/docker.service.d
└─hosts.conf
Active: active (running) since Thu 2017-07-27 11:45:54 PDT; 3s ago
Docs: https://docs.docker.com
Main PID: 20482 (dockerd)
Tasks: 18 (limit: 4915)
Memory: 15.3M
CPU: 351ms
CGroup: /system.slice/docker.service
├─20482 /usr/bin/dockerd -H fd:// -H tcp://0.0.0.0:2736
└─20489 docker-containerd -l unix:///var/run/docker/libcontainerd/docker-containerd.sock --metrics-interval=0 --start-timeout 2m --state-dir /var/run/docker/libcontainerd/containerd -- 继续阅读与本文标签相同的文章
-
听众提建议,鼎城区城管局马上改
2026-05-18栏目: 教程
-
PARTsolutions让旺众/Wanzl的新设计缩短了2个多小时
2026-05-18栏目: 教程
-
第六届世界互联网大会将推出5G自动公交线路
2026-05-18栏目: 教程
-
市科技局加快黄石双创战略团队培育
2026-05-18栏目: 教程
-
阿里研究员:测试稳定性三板斧,我怎么用?| 9月6号栖夜读
2026-05-18栏目: 教程
