SanityCheck
SanityCheck

Reputation: 179

Docker does not start on Windows 10

Docker has been having intermittent problems on Windows 10 Enterprise. When the machine is rebooted, Docker starts sometimes but not always. If it does not start, I kill the Docker process and relaunch it manually by going to the menu item "Docker for Windows". But this never launches Docker. On examining the log files it appears that the process gets 'stuck'. Here is the tail of the log file:

[21:40:07.907][PowerShell     ][Info   ] Run script with parameters: -Create True -VhdPathOverride  -VhdSize 64424509440 -SwitchSubnetAddress 10.0.75.0 -SwitchSubnetMaskSize 24 -CPUs 2 -Memory 2048 -IsoFile C:\Program Files\Docker\Docker\Resources\docker-for-win.iso...
[21:40:07.907][HyperV         ][Info   ] Script started at 21:40:07.907
[21:40:07.907][HyperVGuids    ][Info   ] GUIDs installed
[21:40:07.929][HyperV         ][Info   ] Module loaded at 21:40:07.929
[21:40:07.929][Firewall       ][Info   ] All existing rules are removed.
[21:40:07.929][Firewall       ][Info   ] Opening ports for C:\Program Files\Docker\Docker\Resources\com.docker.proxy.exe...
[21:40:07.960][Firewall       ][Info   ] Opening ports for SMB...
[21:40:07.960][HyperV         ][Info   ] Creating Switch: DockerNAT...
[21:40:07.992][Firewall       ][Info   ] Ports are opened
[21:40:14.115][HyperV         ][Info   ] Switch created.
[21:40:23.431][HyperV         ][Info   ] Set IP address on switch
[21:40:24.387][HyperV         ][Info   ] Creating VM MobyLinuxVM...
[21:40:26.443][HyperV         ][Info   ] Setting CPUs to 2 and Memory to 2048 MB
[21:40:27.072][HyperV         ][Info   ] Attach VHD C:\Users\Public\Documents\Hyper-V\Virtual Hard Disks\MobyLinuxVM.vhdx

Any clues as to what is going on? Or how to resolve this issue?

Upvotes: 8

Views: 35026

Answers (6)

Moein Hasani
Moein Hasani

Reputation: 91

For me the issue was I was on a work computer and docker needed me to prove I'm the member of the organization. So instead of logging in with google I needed to login with the GitHub account associate with our company.

Upvotes: 0

Eliav Louski
Eliav Louski

Reputation: 5314

taken from here https://forums.docker.com/t/docker-for-windows-wont-launch/15725/14

restart the “Windows Management Instrumentation” service. This causes hyper-v to restart, once that’s all done just try to start Docker Desktop again.

in addition: search for docker in task manager and kill any process related to docker, and stop any service related to docker.

Upvotes: 0

Manish
Manish

Reputation: 79

In my scenario after the Windows 10 update (September 14, 2021—KB5005565 (OS Builds 19041.1237, 19042.1237, and 19043.1237)

Docker will not start. Even on right-click ==> Run as Admin, it will do nothing. Also, tried switching daemon.

The thing that worked for me is to right-click on the Docker Desktop icon and opt for 'Troubleshoot Compatibility' and choose 'Troubleshoot Program' and follow the instructions.

Troubleshoot Compatibility:

Troubleshoot Compatibility

Troubleshoot Program:

Troubleshoot Program

Upvotes: -1

H. Pauwelyn
H. Pauwelyn

Reputation: 14330

I'm answering this question because I didn't find a detailed answer. Like @alalinaci and @Omar said resetting Docker to the factory defaults works. This could be done by opening Docker desktop, go to troubleshoot menu (the bug icon above) and choose "Reset to factory defaults". A restart will be done automaticly.

A login must be done when done.

Upvotes: 8

Omar
Omar

Reputation: 1111

Go to troubleshoot in Docker Desktop App and force restart.

Upvotes: 1

alalinaci
alalinaci

Reputation: 31

Setting to factory, followed by a docker restart, did the trick for me.

Upvotes: 2

Related Questions