New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Docker for Windows Containers - HNS failed with error : The parameter is incorrect. #30280
Comments
I have run the CleanupContainerHostNetworking script with I also ran the debug container host script, here is the output:
|
Just upgraded to 1.13.0-beta38 (9805) and the issue persists. |
I have what appears to be the same issue, you are not alone. Any progress? I'm kinda new - is there any info I should post that might help? Edit: My apologies for vanishing, the issue is resolved on my end. A subsequent restart fixed the issue, I had rebooted once but there musta been a gremlin. |
Issue persists in 1.13.0-beta39 (9861) as well. |
Version 1.13.1-rc1-beta40 (9961) - Same |
ping @rneugeba PTAL |
The error says it's an issue with HNS (the networking for Windows Containers). Maybe @JMesser81 can help... |
The output from Debug Container Host script indicates that you are targeting the Linux Docker engine (running in Moby VM) rather than the Windows Docker engine. Please make sure your $ENV:DOCKER_HOST is pointing to the correct Docker engine (either Linux or Windows). Regarding the confusing HNS error, we are looking to improve our error messages soon - @viaror. This particular error seems to indicate that a NAT network may already exist on the system. If you can get the output from the above diagnostic script (update $ENV:DOCKER_HOST) that would be the best, otherwise, please run the following PoSh cmdlets and attach the output: PS> Get-VMSwitch |
Here is Debug Container Host with
Here is the PoSh cmdlets:
|
@caleblloyd when you use Docker for Windows you should not set |
@rneugeba this bug is triggered when I click on |
I'm guessing you can't switch to Windows Containers due to this error message: @rneugeba - what's the name of the Windows docker engine running on the local container host? Can we try and start this manually with -D option to see if problem repros? I'm guessing it will @caleblloyd - Let's try something different. Can you please update your C:\ProgramData\Docker\config\daemon.json file and add an an entry which states "bridge" : "none" e.g. Then try again |
The docker daemon executable is at @caleblloyd could exit the Docker for Windows app. After you quit, check with |
Running Is there a fix to repair the bridge so that it works without doing this hack? |
Here is a workaround for adding |
Hi, I have the exact same issue with Version 17.03.1-ce-rc1-win3 (10625) on Windows 10 Pro x64, except the {"bridgge":"none"} doesn't work for me no matter in a config.json/daemon.json for dockerd or in %appdata%\docker\settings.json as suggested in #473. When I run the dockerd with config.json from the elevated powershell, the process seemed running and waiting. Then as soon as I tried to start the Docker for Windows.exe (the system tray app), the dockerd process in the powershell window exited and I got the HNS failed with error: the parameter is incorrect. Running the cmdlets suggested by @JMesser81 returned similar results @caleblloyd showed in his feedback. The log has been submitted as 0C1F246A-14C2-4CA7-869B-1A7332A36927/2017-03-26_19-30-06 BTW, my computer has ESET Endpoint Security installed by the company's group policy. This product caused trouble when I tried to share drives. Not sure if it's guilty for this issue as well; can't turn it off to test. Edit - Managed to turn off the firewall, but the issue stays. |
I've broken docker, This is happening to me now, running docker 17.03.1-ce-win5. When you switch to windows containers it looks like the Virtual Switch isn't created? |
After banging my head against this issue for a day, I found this thread and my docker is also broken v17.03.1-ce-win5. The switches and networking is completely broken. |
Welcome to the club. Either reinstall Windows, try the In other news I ordered a new laptop today. I'll volunteer my old laptop that exhibits this issue for a 2 week loan to somebody on the Docker team if they want to take a stab at fixing this. |
I encountered the same problem. Two things may have been the culprit: I did play with the Ubuntu After a "factory reset" in Docker's Settings (which blew away the Ubuntu images I had pulled), the new NAT network was configured correctly and the Windows containers started running. Unfortunately, my previous NAT network's configuration no longer worked, but I simply switched my VMs to the new NAT network and now everything is groovy. |
Thanks @dscho. Unfortunately I didn't have same luck. I just upgraded to the new 17.04.0-ce-rc2-win6 (10840) version and it didn't work. Then I did a factory reset whilst the docker is still in the failed Windows mode (red whale), and it's still no luck. Crash report - 0C1F246A-14C2-4CA7-869B-1A7332A36927/2017-04-03_14-49-22 |
Update: Removing and re-installing the new version 17.03.1 CE made things work again for me. |
Update: PS C:\WINDOWS\system32> docker version Server: Hope this may help. |
Update: |
Met this issue. Get fixed with https://github.com/docker/for-win/issues/711 net stop hns; and restart docker for windows with administrator permission. |
Is someone have solution's for this, I still have problem with it. |
2019 here. And the same thing. Trying to run docker and docker compose from WSL with the daemon on windows. Versions as seen from wsl:
Versions as seen from windows
Same behaviour on both sides: |
If pa-gateway fails to start, then run resmon.exe, select "Listening ports", sort the port numbers, and verify that the PA Workspace ports (80 and 443 by default if nothing specified in /config/paw.ps1) are not used by something else. Also if there is some firewall, then verify these ports are not blocked. If there is an antivirus, then exclude these folders (and subfolders) and applications from being scanned: Open Powershell in elevated mode (right-click "Run as administrator"), run these commands delete all containers (but not the volumes/databases that contain books and users, nor the images) : Now remove the Docker NAT network informations (some backup commands have been added, so that to be able to restore the previous configuration if necessary): If one of these commands is failing, then there is a Microsoft/Docker issue that IBM cannot resolve. In that case please refer to this doc: Now we can restart Host Network Service (HNS) and docker service : Because we deleted the Docker network, we have to check if the Get-NetIPInterface still shows correct Interface Metric Numbers for each ipv4 network adapter. Run this in Powershell : ifIndex InterfaceAlias AddressFamily NlMtu(Bytes) InterfaceMetric Dhcp ConnectionState PolicyStore 6 Ethernet0 IPv4 1500 15 Disabled Connected ActiveStore ifIndex InterfaceAlias AddressFamily NlMtu(Bytes) InterfaceMetric Dhcp ConnectionState PolicyStore 6 Ethernet0 IPv4 1500 15 Disabled Connected ActiveStore Now stop PA Workspace again because docker has automatically restarted some containers that may not have been deleted yet: Now we can try to run the admintool again : |
Closing this as it appears to be a solved (or at least not consistently reproduced) Docker Desktop issue. |
This issue is being opened upstream to docker engine from docker/for-win#396
Expected behavior
In Docker for Windows Beta, click on "Switch to Windows Containers" and Docker for Windows Containers works.
Actual behavior
Error on switching to windows containers every time. Linux containers work fine.
Information
Crash report ID: E958D2D3-3554-427C-92CD-47C9FA318338/2017-01-18_09-50-22
Things I have tried:
No matter what I do, I can't get docker for windows containers to work. It did work for a few days when I first installed it, but obviously there is now something triggering this error that prevents it from working at all.
Full log:
The text was updated successfully, but these errors were encountered: