Hacker News new | ask | show | jobs
by encryptluks2 1869 days ago
Are you even on Windows? This is with WSL 2, as you can systemd doesn't work as expected in WSL2. This is a known issue. If systemd is working for you, then you are doing something magic:

  sudo systemctl start docker
  [sudo] password for u3332:
  System has not been booted with systemd as init system (PID 
  1). Can't operate.
  Failed to connect to bus: Host is down
https://stackoverflow.com/questions/55579342/why-systemd-is-...
2 comments

From that link (permalink to answer: https://stackoverflow.com/a/61887923) :

> Nowadays you can try:

> sudo service docker start

> when using WSL2, if you are running on windows version 2004 or higher (I assume).

Which is what I did in the listing above.

  sudo service docker start
  [sudo] password for u3323:
  docker: unrecognized service
Did you install docker from their own PPA linked in the instructions above, and are you on Ubuntu 20.04 with WSL2? Those are the only steps I took.

e:

  ver
on 'cmd' also shows

  Microsoft Windows [Version 10.0.19042.928]
if that helps

e:

Everything except the service start, which I had to find in that StackOverflow thread. We've hit the max comment depth, so I couldn't response to you directly.

Are you referring to the install instructions for Ubuntu? No where does it mention running the commands:

  sudo service docker start
If you run the Docker daemon manually, it works just fine. I'm running a container on it right now.

It's not a problem with Docker on WSL 2, but a problem with the way WSL uses its own init system instead of systemd, while some Ubuntu packages are packaged for a systemd system.