"DockerNAT": Instance MSFT_NetIPAddress already exists

Expected behavior

Having an operation docker instance

Actual behavior

Docker is complaining with the following error: “DockerNAT”: Instance MSFT_NetIPAddress already exists

Information

[18:21:24.446][HyperV ][Info ] Enabled workaround for Build 10586 VMSwitch issue
[18:21:30.712][HyperV ][Info ] Creating Switch: DockerNAT…
[18:21:32.738][HyperV ][Info ] Deleted old IP address
[18:21:32.754][HyperV ][Info ] Switch created.
[18:21:33.239][NamedPipeServer][Error ] Unable to executeStart: Failed to create Switch “DockerNAT”: Instance MSFT_NetIPAddress already exists

[18:21:33.254][NamedPipeClient][Error ] Unable to sending Start: Failed to create Switch “DockerNAT”: Instance MSFT_NetIPAddress already exists

[18:21:33.254][Notifications ][Error ] Error: Failed to create Switch “DockerNAT”: Instance MSFT_NetIPAddress already exists

[18:21:44.969][Program ][Info ] Sending Bugsnag report b546638e-b093-4993-a6eb-6cd13ac0a270 …

Steps to reproduce the behavior

Simply try to run docker.

I encounterd the same problem. After running the Docker executable and recieving the error, exitting Docker and retrying it again solved it for me.

Check out what I’ve just written in my thread: Failed to create Switch “DockerNAT” with comments and ideas

Yep, we’re hitting the same issue. I’ve tried re-installing docker without luck.

If you edit the C:\Program Files\Docker\Docker\Resource\MobyLinux.ps1 script, around line 175 is a line that reads:

$networkAdapter = Get-NetAdapter "vEthernet ($SwitchName)"

If you add an asterisk:

$networkAdapter = Get-NetAdapter "vEthernet ($SwitchName)*"

it’ll get past this error. However, that means that the switch is not as expected name-wise - and so far, for me, I’ve failed to get DHCP assigning an IP to the MobyLinux VM when it boots up. I still don’t clearly understand how the IP is assigned/where DHCP runs, so… This may or may not help :confused:

I was getting the same error in windows 10 , i have resolved this issue by disabling unused DockerNAT in Network Connections.

Hi @injoygiving

you should only have one switch called vEthernet (DockerNAT). If you stop Docker for Windows and then delete the switches as described on the trouble shoot page, on the next restart one will get recreated and you should be fine

Rolf

Thanks for the info … now i am getting some other error when trying to connect with docker repositories.

glad you made progress. are you using a http proxy by any chance? This is not yet supported on Docker for Windows but we are working on it.
Rolf

I ran into this the other day.
I ended up uninstalling Hyper-V feature (by unselect the feature).
Restart the computer, do not let Docker enable HyperV yet.
Delete the different ghost Network adapters I had. To delete them go to the Device Manager and find them under “Network Adapters”, right click -> uninstall. Looks like disabling them is not enough.
Then restart Docker and let it initialize Hyper-V. You should be good after a restart.

1 Like

@nicotexas 's solution worked but I had to Reset Docker to Factory settings too. Thanks for the tip!