none
hcsshim::ImportLayer - Win32 API call returned error RRS feed

  • Question

  • Tried sample @ https://github.com/Microsoft/Virtualization-Documentation/tree/master/windows-server-container-samples/iis-10.0 and got this error.

    hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=91f411b4c51305fa53003ee4bfc763401cf3d1cfc5817dc8fd5540479293b692 flavour=1 folder=C:\ProgramData\Docker\windowsfilter\91f411b4c51305fa53003ee4bfc763401cf3d1cfc5817dc8fd5540479293b692-394142580

    This https://msdn.microsoft.com/virtualization/windowscontainers/about/work_in_progress link talks of a zero day patch.  Dead End ??

    Thanks

    Thursday, August 20, 2015 10:53 AM

Answers

  • Hi Madusudanan,

    Thank you for the extensive testing and validation here... I am able to repro this behavior and we are investigating. Sorry about that!

    I'll let you know if there is an update on this.

    Lars

    PS: can you please try running docker pull microsoft/iis? This should download an IIS image from the repository for you.


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.

    Monday, August 24, 2015 6:57 PM

All replies

  • Hi Madusudanan,

    Just to confirm whether the ZDP is installed: Can you please run wmic qfe list?

    This should return something like:

    Caption                                     CSName           Description  FixComments  HotFixID   InstallDate  InstalledBy  InstalledOn  Name  ServicePackInEffect  Status
    http://support.microsoft.com/?kbid=3081439  WIN-H8EARSF0AA7  Update                    KB3081439                            8/14/2015

    How did you set up your environment?

    Thank you,

    Lars


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.

    Thursday, August 20, 2015 3:57 PM
  • Hi Lars,

    Thanks for the response.  The environment was setup in azure, image was from the azure gallery.  Not sure if the image had the ZDP - I couldn't locate it online, so I didn't explicitly run the patch.  

    Sorry, I took down the environment - so can't get you the details you need.  Think it was an A2 instance - with the image from the gallery and the PS script from the container samples in github.

    Thanks,

    Madusudanan 

    Thursday, August 20, 2015 4:23 PM
  • Hi Madusudanan,

    Thank you for following up. Just to confirm: You tried the Windows Server Container Preview image that is in the Azure Gallery?

    https://portal.azure.com/#gallery/Microsoft.WindowsServer2016TechnicalPreviewwithContainers

    Cheers,

    Lars


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.

    Thursday, August 20, 2015 5:10 PM
  • Hi Lars,

    I didn't use the URL to pick the image.  This is what i used

    Friday, August 21, 2015 5:33 AM
  • Hi, I'm having the same issue :

    PS C:\Users\mmisztal> docker run "microsoft/iis" -d

    Error response from daemon: Cannot start container

    1ce6774defcee02dea1d56d3d535ed0290a529fe1559f64236f2dde6a00a7a4a:

    HCSShim::CreateProcessInComputeSystem - Win32 API call returned error

    r1=2147942402 err=The system cannot find the file specified.

    id=1ce6774defcee02dea1d56d3d535ed0290a529fe1559f64236f2dde6a00a7a4a

    params={ -d  map[] false [0 0]}


    PS C:\Users\mmisztal> docker run "microsoft/redis" -d

    Unable to find image 'microsoft/redis:latest' locallylatest:

    Pulling from microsoft/rediseeceaafa5f5b: Pull complete31f73dd1cc4e:

    Pull complete09e875ef688a: Pull completeDigest:

    sha256:f11c13e5147112b4dd419b845d9464c1d18b6a1060f4b8b4332eb606d1d28f33Status:

    Downloaded newer image for microsoft/redis:latestError response from daemon:

    Cannot start container 1b5fc97e004462590a9a0337c7e090479678d9bc3cbdbd297f579ddaea3f733e:

    HCSShim::CreateProcessInComputeSystem - Win32 API call returned error

    r1=2147942402 err=The system cannot find the file specified.

    id=1b5fc97e004462590a9a0337c7e090479678d9bc3cbdbd297f579ddaea3f733e params={ -d  map[] false [0 0]}


    PS C:\Users\mmisztal> wmic qfe list

    No Instance(s) Available.


    I'm attempting to run this in a VM, I've setup the Containers feature using :

    wget -uri http://aka.ms/setupcontainers -OutFile ContainerSetup.ps1

    ./ContainerSetup.ps1

    It seems that unable to run anything :/

    /Maciej


    Maciek

    Friday, August 21, 2015 7:26 AM
  • Trying to setup a local VM manually with container support docker and the container images based on the New-ContainerHost.ps1 script.  Am unable to locate the ZDP, http://aka.ms/containerzdp (http://10.137.119.43/Windows10.0-KB3081439-x64.cab),  referred in the script.  Where can I find it ?

    Thanks

    Sunday, August 23, 2015 10:52 AM
  • Hi Madusudanan,

    The aka.ms redirection seems to be not pointing to the correct location. Sorry for that! I am trying to get this fixed.

    You can download the ZDP from the Windows Update Catalog in the meantime:

    https://catalog.update.microsoft.com/v7/site/Search.aspx?q=KB3081439

    Update:

    Just set up a new host using the New-ContainerHost.ps1 script. If you simply follow the steps on the documentation page, the ZDP is already integrated and does not need to be downloaded. Still trying to fix the redirection.

    Hope this helps,

    Lars


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.


    Sunday, August 23, 2015 6:37 PM
  • Hi Maciek,

    What happens when you simply run a docker run -it --rm windowsservercore cmd?

    Regarding the other images: The ContainerSetup.ps1 on its own currently does not download the ZDP - I am currently checking if we can improve that  for the current TP3 release. 

    Can you please try the following: (sorry for the manual steps here)

    1. Download KB3081439 from the Windows Update catalog: https://catalog.update.microsoft.com/v7/site/Search.aspx?q=KB3081439
    2. This will give you an MSU file with a long file name (AMD64-all-windows10.0-kb3081439-x64_21d6fa119f58889cb6ef43c4be2868fd75208365.msu) - copy this file to C:\zdp on the Container host
    3. Run wusa C:\zdp\AMD64-all-windows10.0-kb3081439-x64_21d6fa119f58889cb6ef43c4be2868fd75208365.msu /quiet /norestart on the Container host

    Does wmic qfe list return the update now?

    Thank you!
    Lars


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.

    Sunday, August 23, 2015 7:03 PM
  • Hi Lars,

    Executing the ...

    docker run -it --rm -h my-container windowsservercore cmd

    ... from the PS window, turned the window black and I was presented with the CMD interface. I'm assuming that it worked as expected.

    In a separate window, I've executed ...

    docker ps

    ... and saw a list containing a single container instance with "COMMAND" equal to "cmd" - so that went ok.

    The hostname however didn't change as expected saying it was "angry_bartik" or something like that.

    I'll try getting the 

    wmic qfe list

    to work next.


    Maciek

    Monday, August 24, 2015 11:33 AM
  • Hey again,

    It's not possible to download that KB using Edge, nor the IE that's present on my VM (the page doesn't recognize either of those browsers). Can you make sure that the KB is present in the Microsoft Download Center so that I can access it with Edge please?


    Maciek

    Monday, August 24, 2015 11:50 AM
  • Hi Lars,

    Thanks for the link.  Have installed the ZDP on the environment setup manully in a local VM (didn't run the NewContainerHost.ps1 script as I didn't want to download another 6+GB file - I already had the 10514.0.150808-1529.TH2_RELEASE_SERVER_OEMRET_X64FRE_EN-US.ISO and the CBaseOs_th2_release_10514.0.150808-1529_amd64fre_ServerDatacenterCore_en-us.wim - followed the scripts and got everything setup).  

    Was able to run the windowsservercore container with cmd as the command fine. Other docker commands seem to work fine too.  

    Now trying to run docker build from samples @ https://github.com/Microsoft/Virtualization-Documentation/tree/master/windows-server-container-samples/iis-10.0.  But get same error - here's a dump.

    ------------------------

    C:\Users\Administrator>docker images
    REPOSITORY          TAG                 IMAGE ID            CREATED             VIRTUAL SIZE
    windowsservercore   10.0.10514.0        0d53944cb84d        10 days ago         9.697 GB
    windowsservercore   latest              0d53944cb84d        10 days ago         9.697 GB

    C:\Users\Administrator>cd \

    C:\>docker build -t iis:10.0.10514 c:\build\iis
    Sending build context to Docker daemon  5.12 kB
    Step 0 : FROM windowsservercore
     ---> 0d53944cb84d
    Step 1 : ADD HybridInstaller.ps1 /Windows/Temp/HybridInstaller.ps1
     ---> f5b53275386d
    Removing intermediate container 9e838f99f091
    Step 2 : RUN powershell -executionpolicy bypass C:\Windows\Temp\HybridInstaller.ps1 -RunNative
     ---> Running in f4e4e8fe2d62
    Running natively (or inside a Container) - simply executing the script block
    [container] Running installer: Add-WindowsFeature Web-Server

    Success Restart Needed Exit Code      Feature Result
    ------- -------------- ---------      --------------
    False   No             Failed         {}
    [container] Running installer a second time: Add-WindowsFeature Web-Server
    True    No             Success        {Common HTTP Features, Default Documen...


    hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=96e142d01d233c9871fe9571e37864a01ec9de65587ae752533d42516dddb9b3 flavour=1 folder=C:\ProgramData\docker\windowsfilter\96e142d01d233c9871fe9571e37864a01ec9de65587ae752533d42516dddb9b3-1799959884

    C:\>docker images
    REPOSITORY          TAG                 IMAGE ID            CREATED             VIRTUAL SIZE
    <none>              <none>              f5b53275386d        11 minutes ago      9.697 GB
    windowsservercore   10.0.10514.0        0d53944cb84d        10 days ago         9.697 GB
    windowsservercore   latest              0d53944cb84d        10 days ago         9.697 GB


    C:\>docker ps -a
    CONTAINER ID        IMAGE               COMMAND                  CREATED             STATUS                     PORTS               NAMES
    f4e4e8fe2d62        f5b53275386d        "cmd '/S /C' 'powersh"   12 minutes ago      Exited (0) 7 minutes ago                       evil_colden

    C:\>docker rmi f5b5
    Error response from daemon: Conflict, cannot delete f5b53275386d because the container f4e4e8fe2d62 is using it, use -f to force
    Error: failed to remove images: [f5b5]

    C:\>docker rmi -f f5b5
    Deleted: f5b53275386d68ea89016611e190efb34a1ca892d0c26e14a682f72a0acf69f9

    C:\>wmic qfe list
    Caption                                     CSName          Description  FixComments  HotFixID   InstallDate  InstalledBy          InstalledOn  Name  ServicePackInEffect  Status
    http://support.microsoft.com/?kbid=3081439  WIN2016CONHOST  Update                    KB3081439               NT AUTHORITY\SYSTEM  8/23/2015
    ------------------------

    Desktop Experience is installed in the host, is that an issue?

    Monday, August 24, 2015 5:08 PM
  • Just noticed this in the setup eventlog

    Windows update  could not be installed because of error 2359302 "" (Command line: "wusa  c:\AMD64-all-windows10.0-kb3081439-x64_21d6fa119f58889cb6ef43c4be2868fd75208365.msu /quiet /norestart")

    Wondering how it them listed in wmic qfe list.  Will try running the patch again.

    Monday, August 24, 2015 5:15 PM
  • Uninstalled the patch and installed again, this time in interactive mode.  After a restart, saw a success entry for the patch in the event log.

    Ran the container build again.  Unfortunately error again.

    -------

    C:\Users\Administrator>docker build -t iis:10.0.10514 C:\build\iis
    Sending build context to Docker daemon  5.12 kB
    Step 0 : FROM windowsservercore
     ---> 0d53944cb84d
    Step 1 : ADD HybridInstaller.ps1 /Windows/Temp/HybridInstaller.ps1
     ---> 355e5aefe090
    Removing intermediate container 53f56599fb00
    Step 2 : RUN powershell -executionpolicy bypass C:\Windows\Temp\HybridInstaller.ps1 -RunNative
     ---> Running in 59590b6f5f51
    Running natively (or inside a Container) - simply executing the script block
    [container] Running installer: Add-WindowsFeature Web-Server

    Success Restart Needed Exit Code      Feature Result
    ------- -------------- ---------      --------------
    False   No             Failed         {}
    [container] Running installer a second time: Add-WindowsFeature Web-Server
    True    No             Success        {Common HTTP Features, Default Documen...


    hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=f0788cc32aca202a8b7520efc75358aa9f0ec15b82551b42effa65939d98624e flavour=1 folder=C:\ProgramData\docker\windowsfilter\f0788cc32aca202a8b7520efc75358aa9f0ec15b82551b42effa65939d98624e-3479927360

    --------------------------

    Now trying to run HybridInstaller.ps1 from within the container.

    Monday, August 24, 2015 5:46 PM
  • HybridInstaller.ps1 ran fine from within the container. Exited the container and tried to commit the image to the repository.  Got the same error.

    C:\Users\Administrator>docker commit loving_cray iis:10.0.10514
    Error response from daemon: hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=9e91cbcc133409e6d3013d8d3d243f559a435904c5c791f07c93c82173fca7e1 flavour=1 folder=C:\ProgramData\docker\windowsfilter\9e91cbcc133409e6d3013d8d3d243f559a435904c5c791f07c93c82173fca7e1-3775919086


    Monday, August 24, 2015 6:01 PM
  • Hi Madusudanan,

    Thank you for the extensive testing and validation here... I am able to repro this behavior and we are investigating. Sorry about that!

    I'll let you know if there is an update on this.

    Lars

    PS: can you please try running docker pull microsoft/iis? This should download an IIS image from the repository for you.


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.

    Monday, August 24, 2015 6:57 PM
  • Hi Lars,

    Thanks for the response.  I don't see microsoft/iis in docker hub (https://hub.docker.com/u/microsoft/).  Is this a private image?

    Madusudanan

    Tuesday, August 25, 2015 8:23 AM
  • currently windows container images are not stored in docker  hub.

    Please use following docker command 'docker search anything'. This will list the images hosted by microsoft. I am not sure what is the url of the registry which docker host is connected. 

    This will list iis, redis and few other images. Pull images as per your need. 

    BTW it has very less image only.

    regards,

    ilan

    Tuesday, August 25, 2015 8:56 AM
  • Thanks ilan, Lars,

    I was able to pull down the microsoft/iis image and run it fine.

    Regards,

    Madusudanan

    Wednesday, August 26, 2015 1:39 AM
  • Was able to access the 'web' container from within the container host after disabling firewall on the host.  

    Also tried running another container and accessed the 'web' container from within the 2nd container - while it pinged fine, could not access the 'web' server in the first container - telnet <1st container ip> 80 failed.  Do I have to disable firewall, add rules in the 2nd container?  New-NetFirewallRule, Get-NetFirewallRule failed on both containers.

    Tried running the 2nd container with the link option, expected to see nslookup web working fine, but didn't.

    Also docker port web didn't return anything.

    regards,

    Madusudanan


    Wednesday, August 26, 2015 2:00 AM
  • Hi Madusudanan,

    You currently have to open the firewall on the Container host.

    Please see this part of our documentation.

    Hope this helps,

    Lars


    This posting is provided AS IS with no warranties, and confers no rights. You assume all risk for your use.


    Wednesday, August 26, 2015 2:04 AM
  • Lars,

    If you see my post, I WAS able to access the web server inside the container from the container host - I did see that part of documentation and made the changes.

    My question was more about accessing the container from a 2nd (peer) container.

    regards,

    Madusudanan

    Wednesday, August 26, 2015 3:28 AM
  • BTW earlier i tried this piece of code inside container and it returned error. 

    I guess by default port 80 is enabled for ingress communication inside container. Earlier i tried with Nginx running inside container and I was able to access nginx from Docker host, by this i assume port 80 is allowed for ingress.

    I am not sure for other PORTs. What is the default behavior of container. When we create container with with windows core as base image, Is Firewall is disabled and all the ingress and egress for ports are allowed by default ? 

    Please let us know the behavior. 

    Wednesday, August 26, 2015 3:48 AM
  • I'm having a similar error when running 'docker commit' command on a container based on windowsservercore image:

    Error response from daemon: hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=ff5fe6244aefe590b5deae195ebcd5c8c51646e37c6515eb77d60b2f69a0d15e flavour=1 folder=C:\ProgramData\docker\windowsfilter\ff5fe6244aefe590b5deae195ebcd5c8c51646e37c6515eb77d60b2f69a0d15e-2048652266

    Wednesday, September 16, 2015 10:54 AM
  • Tried sample @ https://github.com/Microsoft/Virtualization-Documentation/tree/master/windows-server-container-samples/iis-10.0 and got this error.

    hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=91f411b4c51305fa53003ee4bfc763401cf3d1cfc5817dc8fd5540479293b692 flavour=1 folder=C:\ProgramData\Docker\windowsfilter\91f411b4c51305fa53003ee4bfc763401cf3d1cfc5817dc8fd5540479293b692-394142580

    This https://msdn.microsoft.com/virtualization/windowscontainers/about/work_in_progress link talks of a zero day patch.  Dead End ??

    Thanks

    I am also getting this error using the iis container sample and building Native.  I have KB3093236 installed on the host.

    hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=1bc1e09be38754af96a48b36410b5f9f48998eb0c2eeda74e43ae90fd6f4bedc flavour=1 folder=C:\ProgramData\docker\windowsfilter\1bc1e09be38754af96a48b36410b5f9f48998eb0c2eeda74e43ae90fd6f4bedc-4107607773

    thanks


    Tuesday, September 29, 2015 10:07 AM
  • Hi wadsd,

    Please start a new thread on this... Just to make sure we're not mixing the issues where the KB was missing.

    Cheers,

    Lars

    Monday, October 12, 2015 6:06 PM
  • I have a similar situation, the above command lists the update

     wmic qfe list
    Caption                                     CSName    Description      FixComments  HotFixID   InstallDate  InstalledBy          InstalledOn  Name  ServicePackInEffect  Status
    http://support.microsoft.com/?kbid=3081439  SRIKSWSC  Update                        KB3081439                                    8/29/2015
    http://support.microsoft.com/?kbid=3093236  SRIKSWSC  Security Update               KB3093236               NT AUTHORITY\SYSTEM  11/9/2015
    http://support.microsoft.com/?kbid=3097627  SRIKSWSC  Security Update               KB3097627               NT AUTHORITY\SYSTEM  11/9/2015

    But when I run  docker run "microsoft/iis" -d, it downloads the package and fails while extracting with below message

    Unable to find image 'microsoft/iis:latest' locally
    latest: Pulling from microsoft/iis
    9aaec35b61af: Extracting [=================================================> ] 40.04 MB/40.25 MB
    hcsshim::ImportLayer - Win32 API call returned error r1=2147549183 err=Catastrophic failure layerId=9aaec35b61af119fd39e787ff6c8b7241b4851f0a721984f3ff75ded6e6e15c9 flavour=1 folder=C:\ProgramData\Docker\windowsfilter\9aaec35b61af119fd39e787ff6c8b7241b4851f0a721984f3ff75ded6e6e15c9-2242182006

    I still have this machine up and running, can you please help on this? I've tried installing Nginx but faced the same issue. 

    Tuesday, November 10, 2015 6:58 AM