Can't get past "Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?" Error on Windows

Viewed 961

I am a Windows user trying to run "docker-compose up" command but continue to get the error in title. I am writing this code in Ubuntu using WSL 2.

I have tried everything - from this post to this post - and have made sure I have docker installed correctly. When I run "sudo service docker start" I get "docker: unrecognized service". I'm thinking of switching to Podman (though would prefer not to if can avoid it) to get past having to use the docker daemon- though I can't seem to get this to run in wsl.

Any and all guidance would be appreciated!

1 Answers

This typically means that your Docker Service is not running.

Open RUN and type services.msc, then click OK or hit enter

Search for service named as Docker Desktop Service. Make sure it is running.

You can also set the Docker service to start when you login from Docker Desktop GUI setting panel

Docker Desktop Settings

Related