[问题] docker: Failed to start Docker Application Container Engine.

时间:2025-03-19 19:34:26

docker无法启动:

 # systemctl restart docker
Job for docker.service failed because the control process exited with error code.
See “systemctl status docker.service” and “journalctl -xe” for details.

journalctl -xe的提示信息为:

 docker.service: Main process exited, code=exited, status=/FAILURE
Failed to start Docker Application Container Engine.
docker.service: Unit entered failed state.
docker.service: Failed with result 'exit-code'.
docker.service: Service hold-off time over, scheduling restart.
Stopped Docker Application Container Engine.
Starting Docker Application Container Engine...
Failed to load listeners: no sockets found via socket activation: make sure the service was started by systemd

---------------------

解决方法:

参考:https://forums.docker.com/t/failed-to-load-listeners-no-sockets-found-via-socket-activation-make-sure-the-service-was-started-by-systemd/62505

# sudo systemctl edit docker.service

之后编辑: 将其中的fd:// 替换为 unix://

之后保存退出。

测试:

 $ service docker start
$ docker ps -a
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES