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

时间:2016-08-02 23:57:03

标签: windows containers

我刚刚升级到Windows 10 Anniversary Update(1607,2016-08-02)并想尝试Windows容器。

我按照了我能找到的最新指南: Windows Containers on Windows 10 by Neil Peterson (可能会有变化!!)

但是当进入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
}
.

我没有在内部人员的构建上尝试这个。跑步时我应该发生什么? - 它应该启动Hyper-V机器(至少在检查Hyper-V管理器时不会发生这种情况)。

更新

通过答案链接中更新的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并在调试中运行守护程序,可以获得更多信息:

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中的网络接口可能存在问题。

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.\"}"

4 个答案:

答案 0 :(得分:11)

经过一些试验和错误,我终于进入了我的纳米服务器容器。

请阅读此Stack Overflow问题中的所有评论和答案,以获得完整的范围。

首先确保您使用https://github.com/Microsoft/Virtualization-Documentation/blob/live/virtualization/windowscontainers/quick_start/quick_start_windows_10.md中的最新Docker镜像,如此处的一个答案中所述。

如果您按照原始文档操作,只需使用以下两个命令更新dockerdockerd(请记得先stop-service dockerdockerd --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守护程序或将其注册为服务。

要清理可能产生问题的任何内容,我从开始运行DEVMGMT.MSC并删除任何Hyper-V网络适配器(请记住,如果您将Hyper-V用于其他VM,请不要删除它们。)< / p>

我启动了deamon:dockerd -D然后我创建了一个新的适配器:

docker network create -d nat MyNatNetwork

然后我停止了deamon并用dockerd -D --bridge "none"再次启动它,然后我就能启动我的纳米服务器了:

docker run -it nanoserver cmd

答案 1 :(得分:2)

处于完全相同的情况。但是,在升级Docker镜像后,我的错误更改为超时(与您的不同)。

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

答案 2 :(得分:0)

GitHub for Windows版本14372+上的updated documentation有下载更新版本的Docker守护程序和客户端的说明,它们可以在周年纪念更新中正常运行。

答案 3 :(得分:0)

megamorf,我不确定这是不是我的设置?你可能想要Poul's,因为他正在搞乱网络配置。我没有触摸设置,但是如果它有助于我的输出运行Get-NetNat | Format-List *, Get-VMSwitch | Format-List *, 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