Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Docker: How to fix "Job for docker.service failed because the control process exited with error code"

Tags:

docker

I'm trying to use docker in Manjaro (my kernel version is 4.19) and it is not working.

After running sudo pamac install docker I run sudo systemctl start docker.service and receive this message:

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

So sudo systemctl status docker.service returns:

● docker.service - Docker Application Container Engine    Loaded: loaded (/usr/lib/systemd/system/docker.service; disabled; vendor preset: disabled)    Active: failed (Result: exit-code) since Mon 2019-04-29 12:28:44 -03; 39s ago      Docs: https://docs.docker.com   Process: 17769 ExecStart=/usr/bin/dockerd -H fd:// (code=exited, status=1/FAILURE)  Main PID: 17769 (code=exited, status=1/FAILURE)  abr 29 12:28:44 tamer-pc systemd[1]: docker.service: Service RestartSec=100ms expired, scheduling restart. abr 29 12:28:44 tamer-pc systemd[1]: docker.service: Scheduled restart job, restart counter is at 3. abr 29 12:28:44 tamer-pc systemd[1]: Stopped Docker Application Container Engine. abr 29 12:28:44 tamer-pc systemd[1]: docker.service: Start request repeated too quickly. abr 29 12:28:44 tamer-pc systemd[1]: docker.service: Failed with result 'exit-code'. abr 29 12:28:44 tamer-pc systemd[1]: Failed to start Docker Application Container Engine.  

and journalctl -xe returns:

-- Defined-By: systemd -- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel --  -- The unit docker.service has entered the 'failed' state with result 'exit-code'. abr 29 12:28:44 tamer-pc systemd[1]: Failed to start Docker Application Container Engine. -- Subject: A unidade docker.service falhou -- Defined-By: systemd -- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel --  -- A unidade docker.service falhou. --  -- O resultado é failed. abr 29 12:28:44 tamer-pc systemd[1]: docker.socket: Failed with result 'service-start-limit-hit'. -- Subject: Unit failed -- Defined-By: systemd -- Support: https://lists.freedesktop.org/mailman/listinfo/systemd-devel --  -- The unit docker.socket has entered the 'failed' state with result 'service-start-limit-hit'. abr 29 12:29:02 tamer-pc dbus-daemon[650]: [system] Activating via systemd: service name='org.freedesktop.resolve1' unit='> abr 29 12:29:02 tamer-pc dbus-daemon[650]: [system] Activation via systemd failed for unit 'dbus-org.freedesktop.resolve1.> abr 29 12:29:24 tamer-pc sudo[17879]:    tamer : TTY=pts/0 ; PWD=/etc/docker ; USER=root ; COMMAND=/usr/bin/systemctl stat> abr 29 12:29:24 tamer-pc sudo[17879]: pam_unix(sudo:session): session opened for user root by (uid=0) abr 29 12:29:24 tamer-pc sudo[17879]: pam_unix(sudo:session): session closed for user root lines 1703-1725/1725 (END)  

I'm looking for resolution for two days but whatever I read seems not to be exactly the same as my problem.

like image 650
Tâmer Cuba Avatar asked Apr 29 '19 15:04

Tâmer Cuba


People also ask

Is the Docker daemon running?

The operating-system independent way to check whether Docker is running is to ask Docker, using the docker info command. You can also use operating system utilities, such as sudo systemctl is-active docker or sudo status docker or sudo service docker status , or checking the service status using Windows utilities.

What is the Docker daemon?

The Docker daemon ( dockerd ) listens for Docker API requests and manages Docker objects such as images, containers, networks, and volumes. A daemon can also communicate with other daemons to manage Docker services.


2 Answers

I really dont know what was happening, but I run sudo dockerd --debug like Zeitounator orients me, reboot my pc and docker works perfectly.

like image 165
Tâmer Cuba Avatar answered Sep 28 '22 15:09

Tâmer Cuba


I had the same problem, but I folow the advise of @Zeitounator, and I run this command sudo dockerd --debug to see the problem. It display this message :

Your Linux kernel version 2.6.32-042stab138.1 is not supported for running docker. Please upgrade your kernel to 3.10.0 or newer.

I've update my kernel and it works perfectly. I hope that help you !

like image 39
Ibrahima Sory TRAORE Avatar answered Sep 28 '22 14:09

Ibrahima Sory TRAORE