-
Notifications
You must be signed in to change notification settings - Fork 86
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? #535
Comments
Same problem with the same configuration. |
I tried everything from that issue - nothing helps((( |
Can you look at |
as suggestest in the other issue, try to downgrade and better wait for the next version. |
|
Sorry, this does not look like the logs from |
|
@fpavlik Ok, seems like this may be the missing .socket file. |
@cpuguy83 and what i need to do? |
You can either put the socket back in place (18.09.0 incorrectly removed it), here's the file: https://github.com/docker/docker-ce/blob/18.06/components/packaging/deb/systemd/docker.socket Or you can remove |
@cpuguy83 at first i copied |
Should be something like |
Docker 18.09.1 should be available now |
@cpuguy83 @thaJeztah Oh, i reinstalled docker, now i have 18.09.1, after reinstal it still not works. Next step i found |
@fpavlik what do |
and
|
@cpuguy83 in which place i have to put |
Well, I'm using Ubuntu 18.04 and it randomly happened with me. I decided to install a newer version of docker following the official guide: https://docs.docker.com/install/linux/docker-ce/ubuntu/ And now it works without even restart the machine. |
@fpavlik If you install the latest package you should automatically get the |
I was also facing the same issue in Ubuntu on Windows machine. I have created the docker service in |
I have the same error on Ubuntu with docker 18.09.5 $ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 16.04.1 LTS
Release: 16.04
Codename: xenial On a clear system: $ apt-get install docker.io
...
$ docker --version
Docker version 18.09.5, build e8ff056
$ docker ps
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running? $ systemctl status docker.service
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
Active: inactive (dead) (Result: exit-code) since Tue 2019-06-04 13:32:43 EDT; 5s ago
Docs: https://docs.docker.com
Process: 5277 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=1/FAILURE)
Main PID: 5277 (code=exited, status=1/FAILURE)
Jun 04 13:32:41 server systemd[1]: Failed to start Docker Application Container Engine.
Jun 04 13:32:41 server systemd[1]: docker.service: Unit entered failed state.
Jun 04 13:32:41 server systemd[1]: docker.service: Failed with result 'exit-code'.
Jun 04 13:32:43 server systemd[1]: docker.service: Service hold-off time over, scheduling restart.
Jun 04 13:32:43 server systemd[1]: Stopped Docker Application Container Engine.
Jun 04 13:32:43 server systemd[1]: docker.service: Start request repeated too quickly.
Jun 04 13:32:43 server systemd[1]: Failed to start Docker Application Container Engine. $ journalctl -xe
-- Unit docker.service has begun starting up.
Jun 04 13:37:24 server dockerd[5384]: time="2019-06-04T13:37:24.431996207-04:00" level=fatal msg="Your Linux kernel version 2.6.32-042stab136.1 is not supported for running docker. Please upgrade
Jun 04 13:37:24 server systemd[1]: docker.service: Main process exited, code=exited, status=1/FAILURE
Jun 04 13:37:24 server systemd[1]: Failed to start Docker Application Container Engine.
-- Subject: Unit docker.service has failed
-- Defined-By: systemd
-- Support: http://lists.freedesktop.org/mailman/listinfo/systemd-devel
--
-- Unit docker.service has failed.
--
-- The result is failed.
Jun 04 13:37:24 server systemd[1]: docker.service: Unit entered failed state.
Jun 04 13:37:24 server systemd[1]: docker.service: Failed with result 'exit-code'. I'm concerned about this line: How is this possible, and what should I do? |
You're running Ubuntu Xenial (which should be running on a 4.x kernel), but your kernel is version 2.6? That looks like a strange setup. Kernel 2.6 is definitely not supported by Docker. |
Run: |
Getting this error: docker: Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?. |
Installed Subsytem Linux with LxRunOffline as instructed here: https://stackoverflow.com/questions/51584765/how-do-you-install-multiple-separate-instances-of-ubuntu-in-wsl Installed cURL then
Still cannot run hello-world.
|
Unless you are using WSL2, you cannot run docker this way. If you are seeing this error it is because the CLI could not connect to the daemon. |
Worked for me too! |
Same problem:
My solution to start docker on ubuntu 18.04 was:
|
Worked for me as well |
For me, removing |
Run the below command: |
Worked first try! |
Try with $ systemctl start docker |
Brevity assumes you are using Docker Desktop so of course don't try this if you're not running Docker Desktop |
i am on a redhat 7 and i am facing same issue please any help. |
Are you using Docker Desktop? |
Worked for me only when running in another terminal |
Ran into this issue on Ubuntu 20.10. Using "unset DOCKER_HOST" fixed it for me. See https://docs.docker.com/engine/install/linux-postinstall/#configure-docker-to-start-on-boot |
You can try out this:
It worked fine for me. P.S.: after if there are commands that you can't do without sudo, try this:
|
The error persists till Docker version 20.10.3, build 48d30b5. Once you complete the installation steps from https://docs.docker.com/engine/install/ubuntu/ , run |
Check if docker is actually installed on the host machine by running docker in command. if not in Ubuntu run |
Try turning off the VPN i had the same issue related when starting |
|
I also encountered the same problem,After finding all the solutions, I still can't solve it。 |
just wanted to add onto this in case anyone was in the same boat as me... I was getting this error message and tried pretty much everything here but nothing worked, it ended up being a problem with my firewall. Luckily I found this thread and the following steps fixed it for me:
Afterwards I ran |
I have encountered this problem. When I start the container in the container, this error will occur. At this time, you need to run it on the command line of the server. |
|
For anyone stumbling on this, the nested docker inside the sonic-slave-buster and such makes assumptions on the gid of the docker group on the host and inside the container, a mismatch causes a permission issue when accessing the nested docker container. |
Ran into this with Kali Linux. To fix it based on comments found here.
And now it works! Thanks to all of the comments in this ticket! Also don't forget to enable so it will load after reboots. |
do you solve this program? |
I Tried countless commands from the beginning to the end, and the result still did not solve the problem. |
WOrked for me |
@cobbr2 @buleliuche if |
I created the file /var/run/docker.sock and gave it the rights for current user. This solved the problem. ubuntu 20 |
the following helped me $ sudo apt purge docker-ce docker-ce-cli containerd.io |
Expected behavior
Correct command execution
sudo docker info
Actual behavior
More info
Journal output:
Output of
docker version
:Output of
docker info
:Additional environment details (AWS, VirtualBox, physical, etc.)
OS info:
I'm using VPS
The text was updated successfully, but these errors were encountered: