Not able to start docker Desktop in Windows

Viewed 21471

I am not able to start the Docker container in Microsoft Windows 10 profession. As I found the cause of this error is due to the docker engine is failing to start.

After installing docker I am able to run only the docker version command.

-> docker --version

As I found the error which is showing docker daemon is not running in windows while running any other docker commands on CMD.

I also enabled (checked) the Hyper-V option in "Turn Windows features on or off" in the Control panel -> Programs -> Turn Windows features on or off.

enter image description here

6 Answers

The error is related to the daemon part:

In the default daemon configuration on Windows, the docker client must be run elevated to connect.

We can switch the Docker daemon as an elevated user in order to run the docker daemon in the Windows professional:

Run below command with Windows Powershell as administrator:

Run the PowerShell command: -

& 'C:\Program Files\Docker\Docker\DockerCli.exe' -SwitchDaemon

OR

You can run the below command on CMD as administrator:

Run the CMD command: -

"C:\Program Files\Docker\Docker\DockerCli.exe" -SwitchDaemon

delete %appdata%\Docker\settings.json and let Docker to create a new one

Make sure to download the Linux Kernel Update Package and then try restarting Docker Desktop.

Download from here

My Docker Desktop failed to start after I forced it to exit while updating (it stuck during the update that's why I had to do it). No solution on the Internet helped me until I ran into this Powershell command:

wsl -l -v

It listed the following:

* Ubuntu-18.04           Stopped         2
  docker-desktop         Uninstalling    2
  docker-desktop-data    Stopped         2

It kept saying "Uninstalling" even after rebooting the whole system.

What I did was:

wsl -t docker-desktop

It terminated docker-desktop and made the problem gone.

You should check WSL:

Execute "wsl -l -v" at the command prompt.

If the result is like this:

wsl -l -v

Then execute "wsl --shutdown" on the command line.

Then execute "wsl -l -v", you will see:

wsl -l -v

Then start Docker Desktop.

This solved my problem.

I was getting the same exact issue and a solution was provided from thread The attempted operation is not supported for the type of object referenced." error after Windows Update fixed my problem. I had tried everything before this solution. To keep it simple just follow the below steps -

  1. Copy below snippet

[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\WinSock2\Parameters\AppId_Catalog\0408F7A3] "AppFullPath"="C:\Windows\System32\wsl.exe" "PermittedLspCategories"=dword:80000000

  1. Save it as a file wsl.reg
  2. Execute the file to update the wsl registry
  3. restart docker desktop

these steps are basically done to do some changes in the registry of wsl distribution that is installed standalone or by docker.

Related