Skip to content
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

Lab - Multi-Container Applicationns - not going through #196

Closed
eliassal opened this issue Nov 2, 2016 · 44 comments
Closed

Lab - Multi-Container Applicationns - not going through #196

eliassal opened this issue Nov 2, 2016 · 44 comments

Comments

@eliassal
Copy link

eliassal commented Nov 2, 2016

I am trying to follow the lab at
https://github.com/docker/labs/blob/master/windows/windows-containers/MultiContainerApp.md

I have a physical win laptop with windows container enabled as well as HyperV
Whenever I issue the command

docker-compose -f .\docker-compose.windows.yml build

docker get stuck on step 8/13 and sends back

Step 8/13 : RUN dotnet restore --no-cache .\samples\MusicStore.Standalone
 ---> Running in 47c4a247e602
log  : Restoring packages for C:\MusicStore\samples\MusicStore.Standalone\project.json...
error: Unable to load the service index for source https://dotnet.myget.org/F/aspnetcore-ci-dev/api/v3/index.json.
error:   An error occurred while sending the request.
error:   The server name or address could not be resolved

Thanks for your help

@friism
Copy link

friism commented Nov 6, 2016

@eliassal can you check whether you have network access from within containers? Eg. try running docker run microsoft/nanoserver ping google.com

@eliassal
Copy link
Author

eliassal commented Nov 6, 2016

no, this is the output
PS E:\Salam\Scripts> docker run microsoft/nanoserver ping google.com
Ping request could not find host google.com. Please check the name and try again.

@friism
Copy link

friism commented Nov 7, 2016

Pining @kallie-b and @JMesser81 - are there generalized networking troubleshooting steps on Windows 10?

@kallie-b
Copy link

kallie-b commented Nov 8, 2016

I believe we do have some--double checking with the team on the best steps for this, and will return with an answer as soon as possible.

@kallie-b
Copy link

@eliassal -- I apologize for the delayed reply.

Could you please run the following commands and share the results? They should help us get the details on your connectivity issue.

From your container host:

Get-VMSwitch
Get-netnat
Get-netnatstaticmapping
Ipconfig /allcompartments /all

From inside the container:
Ipconfig /all

@eliassal
Copy link
Author

Hi, here is the outcome fo
Get-VMSwitch:

Name SwitchType NetAdapterInterfaceDescription


External External Realtek USB GbE Family Controller
nat Internal
Windows Phone Emulator Internal Switch Internal
New HNS Switch Private

Get-netnat
Name : Hff909283-0245-4a82-a407-a37fbc872fbb
ExternalIPInterfaceAddressPrefix :
InternalIPInterfaceAddressPrefix : 172.31.0.1/20
IcmpQueryTimeout : 30
TcpEstablishedConnectionTimeout : 1800
TcpTransientConnectionTimeout : 120
TcpFilteringBehavior : AddressDependentFiltering
UdpFilteringBehavior : AddressDependentFiltering
UdpIdleSessionTimeout : 120
UdpInboundRefresh : False
Store : Local
Active : True

Get-netnatstaticmapping : Gives nothing

Ipconfig /allcompartments /all

Network Information for Compartment 1 (ACTIVE)

Host Name . . . . . . . . . . . . : sierac
Primary Dns Suffix . . . . . . . : mydomain.net
Node Type . . . . . . . . . . . . : Hybrid
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No
DNS Suffix Search List. . . . . . : mydomain.net

Ethernet adapter vEthernet (Internal Ethernet Port Windows Phone Emu

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Hyper-V Virtual Ethernet Adap
Physical Address. . . . . . . . . : 00-15-5D-01-05-01
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::7484:69da:cc9:6fb5%27(P
IPv4 Address. . . . . . . . . . . : 169.254.80.80(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :
DHCPv6 IAID . . . . . . . . . . . : 838866269
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-1F-17-AE-A7-AC-2B
DNS Servers . . . . . . . . . . . : fec0:0:0:ffff::1%1
fec0:0:0:ffff::2%1
fec0:0:0:ffff::3%1
NetBIOS over Tcpip. . . . . . . . : Enabled

Ethernet adapter vEthernet (HNS Internal NIC):

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Hyper-V Virtual Ethernet Adap
Physical Address. . . . . . . . . : 00-15-5D-93-34-27
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::35bd:68e:7969:d172%30(P
IPv4 Address. . . . . . . . . . . : 172.31.0.1(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.240.0
Default Gateway . . . . . . . . . :
DHCPv6 IAID . . . . . . . . . . . : 922752349
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-1F-17-AE-A7-AC-2B
DNS Servers . . . . . . . . . . . : fec0:0:0:ffff::1%1
fec0:0:0:ffff::2%1
fec0:0:0:ffff::3%1
NetBIOS over Tcpip. . . . . . . . : Enabled

Tunnel adapter Local Area Connection:

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : BlackBerry Virtual Private Ne
Physical Address. . . . . . . . . : 02-30-A3-E3-D9-01
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
IPv6 Address. . . . . . . . . . . : fd10:a825:fdeb:ad90:1209:65f5
Link-local IPv6 Address . . . . . : fe80::21db:8272:bc2d:2e6b%10(
Autoconfiguration IPv4 Address. . : 169.254.46.107(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.0.0
Default Gateway . . . . . . . . . :
DHCPv6 IAID . . . . . . . . . . . : 721608779
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-1F-17-AE-A7-AC-2B
NetBIOS over Tcpip. . . . . . . . : Enabled

Ethernet adapter vEthernet (External):

Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Hyper-V Virtual Ethernet Adap
Physical Address. . . . . . . . . : A0-CE-C8-1E-96-F3
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes
Link-local IPv6 Address . . . . . : fe80::1985:278e:2a3:ea24%17(P
IPv4 Address. . . . . . . . . . . : 192.168.1.5(Preferred)
Subnet Mask . . . . . . . . . . . : 255.255.255.0
Lease Obtained. . . . . . . . . . : mercredi 9 novembre 2016 19:1
Lease Expires . . . . . . . . . . : dimanche 13 novembre 2016 18:
Default Gateway . . . . . . . . . : 192.168.1.1
DHCP Server . . . . . . . . . . . : 192.168.1.1
DHCPv6 IAID . . . . . . . . . . . : 530632392
DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-1F-17-AE-A7-AC-2B
DNS Servers . . . . . . . . . . . : 192.168.1.13
NetBIOS over Tcpip. . . . . . . . : Enabled

Wireless LAN adapter Local Area Connection* 2:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft Wi-Fi Direct Virtua
Physical Address. . . . . . . . . : AC-2B-6E-AA-E2-B9
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes

Ethernet adapter Bluetooth Network Connection:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Bluetooth Device (Personal Ar
Physical Address. . . . . . . . . : AC-2B-6E-AA-E2-BC
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes

Wireless LAN adapter Wi-Fi:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Intel(R) Dual Band Wireless-A
Physical Address. . . . . . . . . : AC-2B-6E-AA-E2-B8
DHCP Enabled. . . . . . . . . . . : Yes
Autoconfiguration Enabled . . . . : Yes

Tunnel adapter isatap.{E02DE864-01BC-4A8F-92BB-D886C127F16B}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter #2
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes

Tunnel adapter isatap.{9E78FE32-D979-401B-A592-B7F858221B86}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter #3
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes

Tunnel adapter isatap.{FFECA9A8-0CDF-447C-B32C-F7133FA7A4D1}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter #4
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes

Tunnel adapter isatap.{8DEB2D62-D552-41AD-A06C-40D48C6D6D3E}:

Media State . . . . . . . . . . . : Media disconnected
Connection-specific DNS Suffix . :
Description . . . . . . . . . . . : Microsoft ISATAP Adapter #6
Physical Address. . . . . . . . . : 00-00-00-00-00-00-00-E0
DHCP Enabled. . . . . . . . . . . : No
Autoconfiguration Enabled . . . . : Yes

@kallie-b
Copy link

So we need to explore what's going on with your switches, to make sure your container has proper access to the nat network to get external connectivity.

First, run these from the container host:

Get-ContainerNetwork
Get-NetNatExternalAddress

Next, run any container (for example, you could run a NanoServer image in interactive mode with docker run -it nanoserver cmd) and from inside the container, run:
ipconfig /all

@eliassal
Copy link
Author

Get-ContainerNetwork

Name Id Subnets Mode SourceMac DNSServers DNSSuffix


nat ff909283-0245-4a82-a407-a37fbc872fbb {172.31.0.0/20} NAT
External 52ba3cec-f2a4-41d8-af88-21cd9086ebde Transparent
New HNS Switch 54557ca5-f471-4b99-a42b-2e47c41b6070 Transparent

Get-NetNatExternalAddress

ExternalAddressID : 0
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.6.245
PortStart : 1286
PortEnd : 1295
Active : True

ExternalAddressID : 1
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.6.245
PortStart : 47853
PortEnd : 47862
Active : True

ExternalAddressID : 2
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.80.80
PortStart : 3846
PortEnd : 3855
Active : True

ExternalAddressID : 3
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.80.80
PortStart : 50413
PortEnd : 50422
Active : True

ExternalAddressID : 1000000
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 0.0.0.0
PortStart : 0
PortEnd : 65535
Active : True

ExternalAddressID : 1000001
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.170.31
PortStart : 7174
PortEnd : 7183
Active : True

ExternalAddressID : 1000002
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.170.31
PortStart : 54253
PortEnd : 54262
Active : True

ExternalAddressID : 1000007
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 192.168.2.13
PortStart : 21510
PortEnd : 21519
Active : True

ExternalAddressID : 1000008
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 192.168.2.13
PortStart : 63939
PortEnd : 63948
Active : True

ExternalAddressID : 1000009
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 192.168.1.5
PortStart : 24326
PortEnd : 24335
Active : True

ExternalAddressID : 1000010
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 192.168.1.5
PortStart : 62969
PortEnd : 62978
Active : True

ExternalAddressID : 1000011
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.131.17
PortStart : 38662
PortEnd : 38671
Active : True

ExternalAddressID : 1000012
NatName : Hff909283-0245-4a82-a407-a37fbc872fbb
IPAddress : 169.254.131.17
PortStart : 30145
PortEnd : 30154
Active : True

Then I ran
docker run -it microsoft/nanoserver cmd and did
ipconfig /all

Windows IP Configuration

Host Name . . . . . . . . . . . . : 89514939f2b7
Primary Dns Suffix . . . . . . . :
Node Type . . . . . . . . . . . . : Hybrid
IP Routing Enabled. . . . . . . . : No
WINS Proxy Enabled. . . . . . . . : No

@kallie-b
Copy link

kallie-b commented Nov 14, 2016

Apologies for the delay, and for the inconvenience of this error. Next we'd like to get your HNS and Docker Daemon logs, and they should give us a better idea of what's happening. Please run each of the following commands on your host machine:

Stop-Service docker
C:\Windows\System32\dockerd.exe -D

New-NetEventSession NetCap2 -CaptureMode SaveToFile -LocalFilePath C:\HNS.etl
Add-NetEventProvider "{0c885e0d-6eb6-476c-a048-2457eed3a5c1}" -Level 5 -SessionName NetCap2
Add-NetEventProvider "{80CE50DE-D264-4581-950D-ABADEEE0D340}" -Level 5 -SessionName NetCap2
Add-NetEventProvider "{D0E4BC17-34C7-43fc-9A72-D89A59D6979A}" -Level 5 -SessionName NetCap2
Add-NetEventProvider "{93f693dc-9163-4dee-af64-d855218af242}" -Level 5 -SessionName NetCap2
Start-NetEventSession NetCap2

Now reproduce the actions you've taken to get the connection error (so, 'docker-compose ... build,' I believe).

Now stop the event session:
Stop-NetEventSession NetCap2

Once you've completed these steps please provide:

  1. The Docker daemon logs--the output of 'C:\Windows\System32\dockerd.exe -D'
  2. The HNS logs (C:\HNS.etl)

@eliassal
Copy link
Author

1st of all, dockerd is not in C:\Windows\System32
it is in
C:\Program Files\docker\dockerd.exe -D

I followed all steps (HNS.etl included herewith), but I have no log file where Dockerd is found.

Now when I ran
`docker-compose -f .\docker-compose.windows.yml build

`I am getting a very strange error as follows

db uses an image, skipping
Building web
Traceback (most recent call last):
File "", line 3, in
File "compose\cli\main.py", line 65, in main
File "compose\cli\main.py", line 117, in perform_command
File "compose\cli\main.py", line 223, in build
File "compose\project.py", line 300, in build
File "compose\service.py", line 741, in build
File "site-packages\docker\api\build.py", line 105, in build
File "site-packages\docker\utils\decorators.py", line 47, in inner
File "site-packages\docker\client.py", line 135, in _post
File "site-packages\requests\sessions.py", line 522, in post
File "site-packages\requests\sessions.py", line 475, in request
File "site-packages\requests\sessions.py", line 596, in send
File "site-packages\requests\adapters.py", line 423, in send
File "site-packages\requests\packages\urllib3\connectionpool.py", line 595, in urlopen
File "site-packages\requests\packages\urllib3\connectionpool.py", line 363, in _make_request
File "httplib.py", line 1057, in request
File "httplib.py", line 1097, in _send_request
File "httplib.py", line 1053, in endheaders
File "httplib.py", line 897, in _send_output
File "httplib.py", line 859, in send
File "site-packages\docker\transport\npipeconn.py", line 31, in connect
File "site-packages\docker\transport\npipesocket.py", line 22, in wrapped
File "site-packages\docker\transport\npipesocket.py", line 49, in connect
pywintypes.error: (2, 'WaitNamedPipe', 'The system cannot find the file specified.')
docker-compose returned -1

@eliassal
Copy link
Author

I dont the HNS file attached, I tired several times but it is not getting attached

@kallie-b
Copy link

@eliassal--could you email me at kallie.bracken@outlook.com? That might be an easier way for you to share the logs.

Also, the Docker daemon log will not be saved as a file--we're looking for the output of the command, C:\Program Files\docker\dockerd.exe -D, which should be sent to stdout. If you're not getting anything from stdout, double check that you're performing these steps from an elevated command prompt (i.e. run cmd or PowerShell as an Administrator).

Also, ensure that you're stopping the docker service before running any of the above commands (Stop-Service docker).

@eliassal
Copy link
Author

I shared the file by email.
No nothing came out. I might have done an error, should I open 2 powershell windows, 1 for running your suggested command and a 2nd for the running composer?

@kallie-b
Copy link

No, as long as you're running the command from an elevated session ("Run as Administrator"), there shouldn't be any difference running between one or two sessions. I received your file--let me check with my team and see where we should go next.

@eliassal
Copy link
Author

sorry, please ignore the 1st file I sent, I have sent 2 new files dockerd full output, new hns.etl, both have now muche more data. Also, I provided a snapshot of the error and the dockerd output

@kallie-b
Copy link

kallie-b commented Nov 16, 2016

@eliassal

Can you try/report the following:

  • Are you able to ping https://dotnet.myget.org from your container host machine?
  • If you replace the hostname (dotnet.myget.org) with the site's IP in your compose file, do you get different results? We would like to see if this issue is related to DNS resolution.
  • Last, can you run the following (where <LOG FILE PATH/NAME> is replaced with whichever path and file name you would like for the log file) and send me the resulting log file?

netsh trace start globallevel=6 provider={0c885e0d-6eb6-476c-a048-2457eed3a5c1} provider={80CE50DE-D264-4581-950D-ABADEEE0D340} provider={D0E4BC17-34C7-43fc-9A72-D89A59D6979A} provider={93f693dc-9163-4dee-af64-d855218af242} provider={564368D6-577B-4af5-AD84-1C54464848E6} scenario=Virtualization provider=Microsoft-Windows-Hyper-V-VfpExt capture=no report=disabled traceFile=<LOG FILE PATH/NAME>

Now reproduce the steps you took to get the error (run docker-compose...)

netsh trace stop

@eliassal
Copy link
Author

Hi, here is a ping to from host dotnet.myget.org

ping dotnet.myget.org
Pinging myget-www-prod-us-west.cloudapp.net [138.91.194.104] with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.

2nd, dotnet.myget.org is in the NuGet.config, I replaced

<add key="AspNetCore" value="https://dotnet.myget.org/F/aspnetcore-ci-dev/api/v3/index.json" />
by

<add key="AspNetCore" value="https://138.91.194.104/F/aspnetcore-ci-dev/api/v3/index.json" />
Running the compose command I got the same error

Step 8/13 : RUN dotnet restore --no-cache .\samples\MusicStore.Standalone
---> Running in 9f4a7674878d
log : Restoring packages for C:\MusicStore\samples\MusicStore.Standalone\project.json...
error: Unable to load the service index for source https://138.91.194.104/F/aspnetcore-ci-dev/api/v3/index.json.
error: An error occurred while sending the request.
error: A connection with the server could not be established
ERROR: Service 'web' failed to build: The command 'powershell -Command $ErrorActionPreference = 'Stop'; dotnet restore -
-no-cache .\samples\MusicStore.Standalone' returned a non-zero code: 1

@eliassal
Copy link
Author

when I run
netsh trace start globallevel=6 provider......................................

I get

netsh.exe : The command parameter was already specified.
At line:1 char:1

  • netsh trace start globallevel=6 provider={0c885e0d-6eb6-476c-a048-245 ...
  • - CategoryInfo          : InvalidArgument: (:) [], ParameterBindingException
    - FullyQualifiedErrorId : ParameterSpecifiedAlready
    

@kallie-b
Copy link

Alright, so the ping to dotnet.myget.org may be being blocked for some reason, so it may not be a good test. Try this:
Invoke-WebRequest -Method GET -UseBasicParsing -Uri https://dotnet.myget.org/F/aspnetcore-ci-dev/api/v3/index.json -OutFile test.out

(The JSON file you're downloading will be saved as test.out)

That works on my system, and if that works for you we'll know that the issue isn't related to your host having problems with external connectivity.

@eliassal
Copy link
Author

Hi Kali, any feedback on this ?

Regards,

Salam

From: Kallie [mailto:notifications@github.com]
Sent: jeudi 10 novembre 2016 23:05
To: docker/for-win for-win@noreply.github.com
Cc: eliassal salamadmin@free.fr; Mention mention@noreply.github.com
Subject: Re: [docker/for-win] Lab - Multi-Container Applicationns - not going through (#196)

So we need to explore what's going on with your switches, to make sure your container has proper access to the nat network to get external connectivity.

First, run these from the container host:

Get-ContainerNetwork
Get-NetNatExternalAddress

Next, run any container (for example, you could run a NanoServer image in interactive mode with docker run -it nanoserver cmd) and from inside the container, run:
ipconfig /all


You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub #196 (comment) , or mute the thread https://github.com/notifications/unsubscribe-auth/AIDneIGE32q3eOicb5x1DzB4QWvEjSmbks5q85UhgaJpZM4Knmx8 . https://github.com/notifications/beacon/AIDneCnOrmxPtIBYsW3ZafBIYFCShrc2ks5q85UhgaJpZM4Knmx8.gif

@kallie-b
Copy link

Hi--Were you able to do this?

Alright, so the ping to dotnet.myget.org may be being blocked for some reason, so it may not be a good test. Try this:
Invoke-WebRequest -Method GET -UseBasicParsing -Uri https://dotnet.myget.org/F/aspnetcore-ci-dev/api/v3/index.json -OutFile test.out

(The JSON file you're downloading will be saved as test.out)

That works on my system, and if that works for you we'll know that the issue isn't related to your host having problems with external connectivity.

@eliassal
Copy link
Author

Yes I was able to do and even sent you the the test.out by email. However, I have some good news, after installing the updates KB3200970 (as indicated oiin the thread I opened for win2k16 box at https://social.msdn.microsoft.com/Forums/en-US/e1962669-2359-4343-a179-8e434be8356d/docker-is-not-able-to-pull-images-on-win2k16?forum=windowscontainers).

Thanks for your help

@eliassal
Copy link
Author

Sorry Kali, I responded very quickly, it is still not working and giving the same exact error. The command

docker run -it microsoft/nanoserver cmd

was already working fine

@eliassal
Copy link
Author

Hi Kali, any feedback so far?

@kallie-b
Copy link

Hi--apologies for the delay. I don't have feedback yet, but I'll get it to you as soon as possible.

@kallie-b
Copy link

Salam--I've sent you an email regarding the next step we should take to sort this out.

@kallie-b
Copy link

kallie-b commented Dec 1, 2016

It seems that the problem here was that the "bridge=none" option was enabled in eliassal's docker deamon file. This was preventing container endpoints from gaining external connectivity because they were not being connected to the default nat network that is automatically created by Docker and Windows.

The lab that eliassal is using here follows similar steps to those described in this blog post, which was recently published by my team. The post explains some of the details behind the basics of compose and container networking on Windows, so it may be helpful to anyone running into issues in this area.

@rn
Copy link
Contributor

rn commented Dec 2, 2016

@kallie-b thanks for helping to debug this. Can this issue be closed?

@kallie-b
Copy link

kallie-b commented Dec 2, 2016

Yes it can, thank you :)

@rn rn closed this as completed Dec 2, 2016
@eliassal
Copy link
Author

eliassal commented Dec 2, 2016

So many thanks for the team who spent more than hour debugging and unearth the root cause of the issues, special thanks to Kali and Vikrant. I wish all support team for other software can provide such freindly support. IN fact I used a daemon.json file with parameteres that were not needed and one of them which caused the network issue was "bridge=none" which is specific to linux machines

@mfaizanse
Copy link

mfaizanse commented Dec 22, 2016

Mine deamon.json file does not have any line for bridge but I am still facing the exact same issue. What should I do to resolve? @kallie-b @rneugeba

@kallie-b
Copy link

kallie-b commented Dec 22, 2016

@mfaizanse

Okay, so you don't have external connectivity from your containers? Do you mind copying and pasting the contents of your daemon.json file? Also, will you do the following and report the results back to me?

  • Get-ContainerNetwork
  • Get-NetNatExternalAddress
  • Run any two containers in interactive mode (e.g. docker run -it microsoft/nanoserver powershell)
  • Ping one container from the other (you can get the IP address of the container you're pinging by running ipconfig from within the container--it is the "IPv4 Address" entry)
  • Now, from either of the containers, ping www.google.com

This info should help me assist you with troubleshooting!

@eliassal
Copy link
Author

Hi Kali, I presume that this response is for mfaizance.

I still have the issue #27911 with docker on win2k16 box where I can not run a basic command.box Vikrant tried to help when we were in the skype session. I did not see any response from Patrick since you responded following our session.
Thanks

@kallie-b
Copy link

Right, yes it is--thank you. I forgot to @ mention him. I'll take a look at your other issue and see if I can get someone's attention about it. Happy Holidays!

@mfaizanse
Copy link

mfaizanse commented Dec 23, 2016

Thank you @kallie-b for your response. I have shared the details below:

My environment:
Windows 10 Enterprise x64
version 1607
OS build 14393.576

Docker version:
Client:
Version: 1.13.0-rc4
API version: 1.25
Go version: go1.7.3
Git commit: 88862e7
Built: Sat Dec 17 01:34:17 2016
OS/Arch: windows/amd64

Server:
Version: 1.13.0-rc4
API version: 1.25 (minimum version 1.24)
Go version: go1.7.3
Git commit: 88862e7
Built: Sat Dec 17 01:34:17 2016
OS/Arch: windows/amd64
Experimental: true

Docker daemon.json
{}

My Daemon settings are:
dae

Get-ContainerNetwork
I am running this on host OS.

Name Id                                   Subnets            Mode SourceMac DNSServers DNSSuffix
---- --                                   -------            ---- --------- ---------- ---------
nat  47dd5a04-b508-404a-ba43-bc3404151789 {192.168.160.0/20} NAT

Get-NetNatExternalAddress
I am running this on host OS.

ExternalAddressID : 2
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 10.200.0.243
PortStart         : 248
PortEnd           : 257
Active            : True

ExternalAddressID : 3
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 10.200.0.243
PortStart         : 22764
PortEnd           : 22773
Active            : True

ExternalAddressID : 4
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 169.254.85.72
PortStart         : 2808
PortEnd           : 2817
Active            : True

ExternalAddressID : 5
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 169.254.85.72
PortStart         : 25324
PortEnd           : 25333
Active            : True

ExternalAddressID : 8
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 10.0.75.1
PortStart         : 7928
PortEnd           : 7937
Active            : True

ExternalAddressID : 9
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 10.0.75.1
PortStart         : 30444
PortEnd           : 30453
Active            : True

ExternalAddressID : 1000000
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 0.0.0.0
PortStart         : 0
PortEnd           : 65535
Active            : True

ExternalAddressID : 1000003
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 10.200.0.203
PortStart         : 19167
PortEnd           : 19176
Active            : True

ExternalAddressID : 1000004
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 10.200.0.203
PortStart         : 58871
PortEnd           : 58880
Active            : True

ExternalAddressID : 1000009
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 169.254.31.148
PortStart         : 52963
PortEnd           : 52972
Active            : True

ExternalAddressID : 1000010
NatName           : H47dd5a04-b508-404a-ba43-bc3404151789
IPAddress         : 169.254.31.148
PortStart         : 22213
PortEnd           : 22222
Active            : True

I have run two containers using docker run -it microsoft/nanoserver powershell
and ping one from the the other one, its working.
dae22

If I run a container docker run -it microsoft/nanoserver powershell
and ping 8.8.8.8

Pinging 8.8.8.8 with 32 bytes of data:
Reply from 8.8.8.8: bytes=32 time=195ms TTL=49
Reply from 8.8.8.8: bytes=32 time=191ms TTL=49
Reply from 8.8.8.8: bytes=32 time=199ms TTL=49
Reply from 8.8.8.8: bytes=32 time=177ms TTL=49

Ping statistics for 8.8.8.8:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 177ms, Maximum = 199ms, Average = 190ms

But if I ping www.google.com
Ping request could not find host www.google.com. Please check the name and try again.

ipconfig /all from insode the container

Windows IP Configuration

   Host Name . . . . . . . . . . . . : 6fd05785cb6e
   Primary Dns Suffix  . . . . . . . :
   Node Type . . . . . . . . . . . . : Hybrid
   IP Routing Enabled. . . . . . . . : No
   WINS Proxy Enabled. . . . . . . . : No

Ethernet adapter Ethernet:

   Connection-specific DNS Suffix  . :
   Description . . . . . . . . . . . : Microsoft Hyper-V Network Adapter
   Physical Address. . . . . . . . . : 00-15-5D-5C-BD-74
   DHCP Enabled. . . . . . . . . . . : Yes
   Autoconfiguration Enabled . . . . : Yes
   Link-local IPv6 Address . . . . . : fe80::c46d:527:358d:f973%4(Preferred)
   IPv4 Address. . . . . . . . . . . : 192.168.162.18(Preferred)
   Subnet Mask . . . . . . . . . . . : 255.255.240.0
   Default Gateway . . . . . . . . . : 192.168.160.1
   DHCPv6 IAID . . . . . . . . . . . : 67114333
   DHCPv6 Client DUID. . . . . . . . : 00-01-00-01-1F-EE-66-4C-00-15-5D-5C-BD-74
   DNS Servers . . . . . . . . . . . : 192.168.160.1
   NetBIOS over Tcpip. . . . . . . . : Disabled

@kallie-b
Copy link

kallie-b commented Dec 29, 2016

@mfaizanse

We need to see if you have DNS configured on your host--it looks like you don't have external DNS configured on the containers. Please run the following from your host and report back the results:

ipconfig /all

@eliassal
Copy link
Author

eliassal commented Dec 29, 2016 via email

@eliassal
Copy link
Author

Sorry, was this for me or for mfaizanse? I responded quickly as I thought you were chasing the issue of not being able to pull on the other machine with win2K16

@kallie-b
Copy link

Apologies, this was for mfaizanse. I will remember to mention him from now on to avoid ambiguity!

@mfaizanse
Copy link

Thanks @kallie-b for your time. I somehow got the issue resolved. I don't know the exact solution but I hit and tried some settings of default nat adapter and then reinstalling the docker resolved the issue..:)

@kallie-b
Copy link

Good to hear, I'm glad you got it resolved. If you figure out exactly what was going wrong do let me know :)

@rlyders
Copy link

rlyders commented Jan 15, 2017

Hoping someone else might benefit from my lesson learned:

I was seeing the same "WaitNamedPipe" error while trying to run through the Eventuate.io demo after having just installed native Docker for Windows on Windows 10 Pro 64-bit. The problem was solved by a restart. I was setting up a new laptop and had completed numerous installs. I guess after all the restarts, I hadn't noticed that the Docker installer didn't force me to do a restart. Once restarted, the normal Docker startup messages appeared and everything worked as expected.

Best of luck.

@justinhillsjohnson
Copy link

@rlyders Thanks for the tip. I'm also on Windows 10 Pro 64-bit and a restart worked for me.

@docker-robott
Copy link
Collaborator

Closed issues are locked after 30 days of inactivity.
This helps our team focus on active issues.

If you have found a problem that seems similar to this, please open a new issue.

Send feedback to Docker Community Slack channels #docker-for-mac or #docker-for-windows.
/lifecycle locked

@docker docker locked and limited conversation to collaborators Jun 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

9 participants