在Windows 10周年更新无法正常工作的Windows容器

我刚刚升级到Windows 10周年更新,并想尝试Windows容器

我遵循最新的指南,我可以find: 在Windows 10的Windows容器由尼尔·彼得森(可能会改变!!)

但是当进入docker运行时,它不能启动容器。

C:\WINDOWS\system32>docker run -it nanoserver cmd docker: Error response from daemon: container a39ea9f033493807343489ac180b4469f910db22f93f9364271a6d1aeb077e7b encountered an error during CreateContainer failed in Win32: A connection could not be established with the Virtual Machine hosting the Container. (0xc0370108) extra info: { "SystemType": "Container", "Name": "a39ea9f033493807343489ac180b4469f910db22f93f9364271a6d1aeb077e7b", "Owner": "docker", "IsDummy": false, "VolumePath": "", "IgnoreFlushesDuringBoot": true, "LayerFolderPath": "C:\\ProgramData\\Docker\\windowsfilter\\a39ea9f033493807343489ac180b4469f910db22f93f9364271a6d1aeb077e7b", "Layers": [ { "ID": "db459b08-938e-562d-8408-eec0e6df9871", "Path": "C:\\ProgramData\\Docker\\windowsfilter\\261aeaeac3268a5dbb10dd77a9a91344d9192377fdf69e9f208561927d56a185" } ], "HostName": "a39ea9f03349", "MappedDirectories": [], "SandboxPath": "C:\\ProgramData\\Docker\\windowsfilter", "HvPartition": true, "EndpointList": [ "7cde146d-dc65-44da-8a6e-6d72c58ec44c" ], "HvRuntime": { "ImagePath": "C:\\ProgramData\\Docker\\windowsfilter\\261aeaeac3268a5dbb10dd77a9a91344d9192377fdf69e9f208561927d56a185\\UtilityVM" }, "Servicing": false } . 

我没有去尝试这个内部人build设。 运行时应该发生什么? – 它应该启动一个hyper v机器(这在hyper vpipe理器atleast中不会发生)。

更新

随着更新的deamon和客户从答案中的链接我有一个新的错误:

 C:\WINDOWS\system32>docker run -it nanoserver cmd docker: Error response from daemon: container 48465da53f47156755cc6a7c7bd48a0f5a76db9fb9c6c77d52a481ffb9412d10 encountered an error during Start failed in Win32: The system cannot find the path specified. (0x3): Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type. 

更新2

使用更新的docker(d).exe并在debugging中运行守护程序,可以获得更多信息:

 time="2016-08-04T22:52:59.797745800+02:00" level=debug msg="Calling POST /v1.25/containers/create" time="2016-08-04T22:52:59.798769400+02:00" level=debug msg="form data: {\"AttachStderr\":true,\"AttachStdin\":true,\"AttachStdout\":true,\"Cmd\":[\"cmd\"],\"Domainname\":\"\",\"Entrypoint\":null,\"Env\":[],\"HostConfig\":{\"AutoRemove\":false,\"Binds\":null,\"BlkioDeviceReadBps\":null,\"BlkioDeviceReadIOps\":null,\"BlkioDeviceWriteBps\":null,\"BlkioDeviceWriteIOps\":null,\"BlkioWeight\":0,\"BlkioWeightDevice\":null,\"CapAdd\":null,\"CapDrop\":null,\"Cgroup\":\"\",\"CgroupParent\":\"\",\"ConsoleSize\":[50,120],\"ContainerIDFile\":\"\",\"CpuCount\":0,\"CpuPercent\":0,\"CpuPeriod\":0,\"CpuQuota\":0,\"CpuShares\":0,\"CpusetCpus\":\"\",\"CpusetMems\":\"\",\"Devices\":[],\"DiskQuota\":0,\"Dns\":[],\"DnsOptions\":[],\"DnsSearch\":[],\"ExtraHosts\":null,\"GroupAdd\":null,\"IOMaximumBandwidth\":0,\"IOMaximumIOps\":0,\"IpcMode\":\"\",\"Isolation\":\"\",\"KernelMemory\":0,\"Links\":null,\"LogConfig\":{\"Config\":{},\"Type\":\"\"},\"Memory\":0,\"MemoryReservation\":0,\"MemorySwap\":0,\"MemorySwappiness\":-1,\"NetworkMode\":\"default\",\"OomKillDisable\":false,\"OomScoreAdj\":0,\"PidMode\":\"\",\"PidsLimit\":0,\"PortBindings\":{},\"Privileged\":false,\"PublishAllPorts\":false,\"ReadonlyRootfs\":false,\"RestartPolicy\":{\"MaximumRetryCount\":0,\"Name\":\"no\"},\"SecurityOpt\":null,\"ShmSize\":0,\"UTSMode\":\"\",\"Ulimits\":null,\"UsernsMode\":\"\",\"VolumeDriver\":\"\",\"VolumesFrom\":null},\"Hostname\":\"\",\"Image\":\"nanoserver\",\"Labels\":{},\"NetworkingConfig\":{\"EndpointsConfig\":{}},\"OnBuild\":null,\"OpenStdin\":true,\"StdinOnce\":true,\"Tty\":true,\"User\":\"\",\"Volumes\":{},\"WorkingDir\":\"\"}" time="2016-08-04T22:52:59.803744400+02:00" level=debug msg="hcsshim::GetLayerMountPath Flavour 1 ID eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.803744400+02:00" level=debug msg="Calling proc (1)" time="2016-08-04T22:52:59.805747000+02:00" level=debug msg="Calling proc (2)" time="2016-08-04T22:52:59.805747000+02:00" level=debug msg="hcsshim::GetLayerMountPath succeeded flavour=1 id=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028 path=C:\\ProgramData\\docker\\windowsfilter\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.806784800+02:00" level=debug msg="hcsshim::CreateLayer Flavour 1 ID 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init parent eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.807742100+02:00" level=debug msg="hcsshim::CreateLayer - succeeded id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init parent=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028 flavour=1" time="2016-08-04T22:52:59.808789000+02:00" level=debug msg="WindowsGraphDriver Get() id 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init mountLabel " time="2016-08-04T22:52:59.808789000+02:00" level=debug msg="hcsshim::ActivateLayer Flavour 1 ID 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.810743400+02:00" level=debug msg="hcsshim::ActivateLayer - succeeded id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init flavour=1" time="2016-08-04T22:52:59.820779900+02:00" level=debug msg="hcsshim::PrepareLayer flavour 1 layerId 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.820779900+02:00" level=debug msg="hcsshim::NameToGuid Name eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.822782500+02:00" level=debug msg="hcsshim::PrepareLayer succeeded flavour=1 layerId=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.822782500+02:00" level=debug msg="hcsshim::GetLayerMountPath Flavour 1 ID 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.823748800+02:00" level=debug msg="Calling proc (1)" time="2016-08-04T22:52:59.824805600+02:00" level=debug msg="Calling proc (2)" time="2016-08-04T22:52:59.824805600+02:00" level=debug msg="hcsshim::GetLayerMountPath succeeded flavour=1 id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init path=C:\\ProgramData\\docker\\windowsfilter\\991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.825745400+02:00" level=debug msg="WindowsGraphDriver Put() id 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.825745400+02:00" level=debug msg="hcsshim::UnprepareLayer flavour 1 layerId 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.826743000+02:00" level=debug msg="hcsshim::UnprepareLayer succeeded flavour 1 layerId=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.826743000+02:00" level=debug msg="hcsshim::DeactivateLayer Flavour 1 ID 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.827742100+02:00" level=debug msg="hcsshim::DeactivateLayer succeeded flavour=1 id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.827742100+02:00" level=debug msg="hcsshim::GetLayerMountPath Flavour 1 ID 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.827742100+02:00" level=debug msg="Calling proc (1)" time="2016-08-04T22:52:59.828742000+02:00" level=debug msg="Calling proc (2)" time="2016-08-04T22:52:59.828742000+02:00" level=debug msg="hcsshim::GetLayerMountPath succeeded flavour=1 id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init path=C:\\ProgramData\\docker\\windowsfilter\\991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d-init" time="2016-08-04T22:52:59.829741100+02:00" level=debug msg="hcsshim::CreateSandboxLayer layerId 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d parentId C:\\ProgramData\\docker\\windowsfilter\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.839745200+02:00" level=debug msg="hcsshim::NameToGuid Name eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.850753600+02:00" level=debug msg="hcsshim::CreateSandboxLayer - succeeded layerId=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d parentId=C:\\ProgramData\\docker\\windowsfilter\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:52:59.919412900+02:00" level=debug msg="Calling POST /v1.25/containers/991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d/attach?stderr=1&stdin=1&stdout=1&stream=1" time="2016-08-04T22:52:59.919412900+02:00" level=debug msg="attach: stdin: begin" time="2016-08-04T22:52:59.920414800+02:00" level=debug msg="attach: stdout: begin" time="2016-08-04T22:52:59.920414800+02:00" level=debug msg="attach: stderr: begin" time="2016-08-04T22:52:59.925413100+02:00" level=debug msg="Calling POST /v1.25/containers/991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d/start" time="2016-08-04T22:52:59.935412900+02:00" level=debug msg="Assigning addresses for endpoint determined_cori's interface on network nat" time="2016-08-04T22:52:59.939416500+02:00" level=debug msg="RequestAddress(172.16.0.0/12, <nil>, map[])" time="2016-08-04T22:52:59.955490000+02:00" level=debug msg="Network Response : { \"ComputedPolicies\" : [ { \"ACL\" : [ { \"Type\" : \"ACL\" } ] } ], \"CreateProcessingStartTime\" : 131148175799534514, \"DNSServerList\" : \"192.168.1.1\", \"GatewayAddress\" : \"172.16.0.1\", \"ID\" : \"d9d1a429-a5e1-42ab-80f4-750ac39e0085\", \"IPAddress\" : \"172.21.185.228\", \"MacAddress\" : \"00-15-5D-AA-98-9B\", \"Name\" : \"New HNS Endpoint\", \"Policies\" : [ { \"Type\" : \"ACL\" } ], \"PrefixLength\" : 12, \"Type\" : \"nat\", \"Version\" : 4294967297, \"VirtualNetwork\" : \"09f8ccf4-f4b9-49c5-8af3-451f4d3b6241\", \"VirtualNetworkName\" : \"nat\" }" time="2016-08-04T22:52:59.956487100+02:00" level=debug msg="Assigning addresses for endpoint determined_cori's interface on network nat" time="2016-08-04T22:53:00.041390200+02:00" level=debug msg="WindowsGraphDriver Get() id eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028 mountLabel " time="2016-08-04T22:53:00.041390200+02:00" level=debug msg="hcsshim::ActivateLayer Flavour 1 ID eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.044393800+02:00" level=debug msg="hcsshim::ActivateLayer - succeeded id=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028 flavour=1" time="2016-08-04T22:53:00.045358600+02:00" level=debug msg="hcsshim::PrepareLayer flavour 1 layerId eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.046369900+02:00" level=debug msg="hcsshim::PrepareLayer succeeded flavour=1 layerId=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.046369900+02:00" level=debug msg="hcsshim::GetLayerMountPath Flavour 1 ID eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.047370600+02:00" level=debug msg="Calling proc (1)" time="2016-08-04T22:53:00.048361400+02:00" level=debug msg="Calling proc (2)" time="2016-08-04T22:53:00.048361400+02:00" level=debug msg="hcsshim::GetLayerMountPath succeeded flavour=1 id=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028 path=C:\\ProgramData\\docker\\windowsfilter\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.048361400+02:00" level=debug msg="WindowsGraphDriver Put() id eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.049362900+02:00" level=debug msg="hcsshim::UnprepareLayer flavour 1 layerId eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.049362900+02:00" level=debug msg="hcsshim::UnprepareLayer succeeded flavour 1 layerId=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.050363600+02:00" level=debug msg="hcsshim::DeactivateLayer Flavour 1 ID eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.050363600+02:00" level=debug msg="hcsshim::DeactivateLayer succeeded flavour=1 id=eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.051361500+02:00" level=debug msg="libcontainerd: client.Create() with spec {{0.3.0 (Windows) {windows amd64 10.0.14300} {true [50 120] {} [cmd] [] C:\\} { false} 991cfcfd8913 []} {0xc082367f40 0xc082367f20 true C:\\ProgramData\\docker\\windowsfilter\\991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d [C:\\ProgramData\\docker\\windowsfilter\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028] 0xc08246a270}}" time="2016-08-04T22:53:00.051361500+02:00" level=debug msg="hcsshim::NameToGuid Name eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028" time="2016-08-04T22:53:00.051361500+02:00" level=debug msg="HCSShim::CreateContainer id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d config={\"SystemType\":\"Container\",\"Name\":\"991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d\",\"Owner\":\"docker\",\"IsDummy\":false,\"VolumePath\":\"\",\"IgnoreFlushesDuringBoot\":true,\"LayerFolderPath\":\"C:\\\\ProgramData\\\\docker\\\\windowsfilter\\\\991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d\",\"Layers\":[{\"ID\":\"555536ae-3dc2-5751-90ce-0a62b0e6f1eb\",\"Path\":\"C:\\\\ProgramData\\\\docker\\\\windowsfilter\\\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028\"}],\"HostName\":\"991cfcfd8913\",\"MappedDirectories\":[],\"SandboxPath\":\"C:\\\\ProgramData\\\\docker\\\\windowsfilter\",\"HvPartition\":true,\"EndpointList\":[\"d9d1a429-a5e1-42ab-80f4-750ac39e0085\"],\"HvRuntime\":{\"ImagePath\":\"C:\\\\ProgramData\\\\docker\\\\windowsfilter\\\\eb86ef45aec4a9564e29aadc351548926ce5cba2a057e2eb618fff531fd3f028\\\\UtilityVM\",\"SkipTemplate\":true},\"Servicing\":false}" time="2016-08-04T22:53:02.859064500+02:00" level=debug msg="HCSShim::CreateContainer succeeded id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d handle=45552032" time="2016-08-04T22:53:02.859064500+02:00" level=debug msg="libcontainerd: Create() id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d, Calling start()" time="2016-08-04T22:53:02.864062800+02:00" level=debug msg="libcontainerd: starting container 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d" time="2016-08-04T22:53:02.864566900+02:00" level=debug msg="HCSShim::Container::Start id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d" time="2016-08-04T22:53:03.402144600+02:00" level=debug msg="Result: {\"Error\":-2147024893,\"ErrorEvents\":[{\"Data\":[{\"Type\":\"String\",\"Value\":\"991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d\"},{\"Type\":\"String\",\"Value\":\"%%2147942403\"},{\"Type\":\"String\",\"Value\":\"0x80070003\"},{\"Type\":\"Guid\",\"Value\":\"D9D1A429-A5E1-42AB-80F4-750AC39E0085\"}],\"EventId\":12105,\"Message\":\"Failed to create network adapter for Container '991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d', network endpoint ID '{D9D1A429-A5E1-42AB-80F4-750AC39E0085}': The system cannot find the path specified. (0x80070003).\",\"Provider\":\"17103e3f-3c6e-4677-bb17-3b267eb5be57\"}],\"ErrorMessage\":\"The system cannot find the path specified.\"}" time="2016-08-04T22:53:03.403140900+02:00" level=error msg="container 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d encountered an error during Start failed in Win32: The system cannot find the path specified. (0x3)" time="2016-08-04T22:53:03.409141900+02:00" level=error msg="libcontainerd: failed to start container: container 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d encountered an error during Start failed in Win32: The system cannot find the path specified. (0x3)" time="2016-08-04T22:53:03.409141900+02:00" level=debug msg="HCSShim::Container::Terminate id=991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d" time="2016-08-04T22:53:03.410151700+02:00" level=debug msg="libcontainerd: cleaned up after failed Start by calling Terminate" time="2016-08-04T22:53:03.410151700+02:00" level=error msg="Create container failed with error: container 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d encountered an error during Start failed in Win32: The system cannot find the path specified. (0x3)" time="2016-08-04T22:53:03.411149600+02:00" level=debug msg="attach: stdout: end" time="2016-08-04T22:53:03.412147600+02:00" level=debug msg="attach: stdin: end" time="2016-08-04T22:53:03.413142700+02:00" level=debug msg="attach: stderr: end" time="2016-08-04T22:53:03.481751900+02:00" level=debug msg="Releasing addresses for endpoint determined_cori's interface on network nat" time="2016-08-04T22:53:03.481751900+02:00" level=debug msg="ReleaseAddress(172.16.0.0/12, 172.21.185.228)" time="2016-08-04T22:53:03.501524300+02:00" level=error msg="Handler for POST /v1.25/containers/991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d/start returned error: container 991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d encountered an error during Start failed in Win32: The system cannot find the path specified. (0x3): Are you trying to mount a directory onto a file (or vice-versa)? Check if the specified host path exists and is the expected type" time="2016-08-04T22:53:03.503496900+02:00" level=debug msg="Closing buffered stdin pipe" 

正如其中一个常见的表示,hyperv中的networking接口可能存在问题。

 time="2016-08-04T22:53:03.402144600+02:00" level=debug msg="Result: {\"Error\":-2147024893,\"ErrorEvents\":[{\"Data\":[{\"Type\":\"String\",\"Value\":\"991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d\"},{\"Type\":\"String\",\"Value\":\"%%2147942403\"},{\"Type\":\"String\",\"Value\":\"0x80070003\"},{\"Type\":\"Guid\",\"Value\":\"D9D1A429-A5E1-42AB-80F4-750AC39E0085\"}],\"EventId\":12105,\"Message\":\"Failed to create network adapter for Container '991cfcfd8913196b488479944dd44104b707fc325cebef7382c21d82eacf305d', network endpoint ID '{D9D1A429-A5E1-42AB-80F4-750AC39E0085}': The system cannot find the path specified. (0x80070003).\",\"Provider\":\"17103e3f-3c6e-4677-bb17-3b267eb5be57\"}],\"ErrorMessage\":\"The system cannot find the path specified.\"}" 

Solutions Collecting From Web of "在Windows 10周年更新无法正常工作的Windows容器"

经过一些试验后,我终于进入了我的nanoserver容器。

请仔细阅读本SO问题中的所有评论和答案,以获取全部内容。

首先要做的是确保您使用https://github.com/Microsoft/Virtualization-Documentation/blob/live/virtualization/windowscontainers/quick_start/quick_start_windows_10.md中最新的docker,如其中一个答案所述&#x3002;

如果你遵循原来的文档,你可以简单地用以下两个命令来更新你的docker和dockerd。 (记得先做stop-service docker和dockerd –unregister-serice)。

 Invoke-WebRequest https://master.dockerproject.org/windows/x86_64/dockerd.exe -OutFile $env:ProgramFiles\docker\dockerd.exe Invoke-WebRequest https://master.dockerproject.org/windows/x86_64/docker.exe -OutFile $env:ProgramFiles\docker\docker.exe 

你现在应该有

 PS C:\WINDOWS\system32> docker --version Docker version 1.13.0-dev, build 979d48b 

或更晚。

不要启动docker deamon或将其注册为服务。

要清理任何可能会产生问题的东西,我从开始运行DEVMGMT.MSC并删除了任何hyper-v网络适配器。 (记住,如果你使用hyper v的其他虚拟机,不要删除这些)。

我开始了deamon: dockerd -D然后我创建了一个新的适配器: docker network create -d nat MyNatNetwork

然后,我停止了deamon,并用dockerd -D --bridge "none"重新启动,然后我就可以启动我的nanoserver docker docker run -it nanoserver cmd

情况完全一样。 但是,升级泊坞窗图像后,我的错误更改为超时(与您的不同)。

 docker: Error response from daemon: container 219aa480b05d7c7f8110b734dee75e3c2e1a66e230ca066f5e463f0976092476 encountered an error during CreateProcess failed in Win32: The remote procedure call failed. (0x6be) extra info: {"ApplicationName":"","CommandLine":"cmd","WorkingDirectory":"C:\\","Environment":{},"EmulateConsole":true,"CreateStdInPipe":true,"CreateStdOutPipe":true,"CreateStdErrPipe":false,"ConsoleSize":[40,100]}. 

然后,我申请了注册表黑客的说明,说这是技术预览的一个已知问题所必需的。 我认为这是正式版本不再需要,但显然这是因为我现在可以连接到容器。 尝试:

 Set-ItemProperty -Path 'HKLM:SOFTWARE\Microsoft\Windows NT\CurrentVersion\Virtualization\Containers' -Name VSmbDisableOplocks -Type DWord -Value 1 -Force 

GitHub for Windows版本更新的文档 14372+有指示可以下载更新版本的Docker守护进程和客户机,这些更新版本可以在周年纪念更新中正常工作。

megamorf,不知道这是我以后的设置吗? 你可能想要的是Poul的,因为这是他搞乱网络配置。 我没有触及设置,但是如果有帮助,这里是我运行Get-NetNat |的输出 Format-List *,Get-VMSwitch | 格式列表*,Get-NetAdapter | Format-List * Store : Local TcpFilteringBehavior : AddressDependentFiltering UdpFilteringBehavior : AddressDependentFiltering UdpInboundRefresh : False Active : True Caption : Description : ElementName : InstanceID : H77edae10-e10d-41e1-ada2-8592df522752;0 ExternalIPInterfaceAddressPrefix : IcmpQueryTimeout : 30 InternalIPInterfaceAddressPrefix : 172.16.0.1/12 InternalRoutingDomainId : {00000000-0000-0000-0000-000000000000} Name : H77edae10-e10d-41e1-ada2-8592df522752 TcpEstablishedConnectionTimeout : 1800 TcpTransientConnectionTimeout : 120 UdpIdleSessionTimeout : 120 PSComputerName : CimClass : root/StandardCimv2:MSFT_NetNat CimInstanceProperties: {Caption, Description, ElementName, InstanceID...} CimSystemProperties: Microsoft.Management.Infrastructure.CimSystemProperties