moby: hcsshim::ImportLayer failed after cygwin and vs2015 build tools installations
Description
I cannot install cygwin during docker build
anymore (but I still can install and use it during docker run).
Steps to reproduce the issue: Dockerfile:
FROM mcr.microsoft.com/windows/servercore:2004
RUN powershell -NoProfile -InputFormat None -ExecutionPolicy Bypass -Command "iex ((New-Object System.Net.WebClient).DownloadString('https://chocolatey.org/install.ps1'))"
RUN choco feature enable -n=allowGlobalConfirmation
RUN choco feature disable -n=showDownloadProgress
RUN cinst cygwin
docker build .
Describe the results you received:
...
Step 5/5 : RUN cinst cygwin
---> Running in b00fa2c610e1
Chocolatey v0.10.15
Installing the following packages:
cygwin
By installing you accept licenses for the packages.
chocolatey-core.extension v1.3.5.1 [Approved]
chocolatey-core.extension package files install completed. Performing other installation steps.
Installed/updated chocolatey-core extensions.
The install of chocolatey-core.extension was successful.
Software installed to 'C:\ProgramData\chocolatey\extensions\chocolatey-core'
Cygwin v3.1.5 [Approved]
cygwin package files install completed. Performing other installation steps.
Download site: http://mirrors.kernel.org/sourceware/cygwin/
Installing 64-bit Cygwin...
Cygwin has been installed.
Added C:\ProgramData\chocolatey\bin\Cygwin.exe shim pointed to 'c:\tools\cygwin\cygwin.bat'.
Copying cygwin package manager (setup) to C:\tools\cygwin
Environment Vars (like PATH) have changed. Close/reopen your shell to
see the changes (or in powershell/cmd.exe just type `refreshenv`).
ShimGen has successfully created a shim for setup-x86.exe
The install of cygwin was successful.
Software installed to 'C:\tools\cygwin'
Chocolatey installed 2/2 packages.
See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log).
Enjoy using Chocolatey? Explore more amazing features to take your
experience to the next level at
https://chocolatey.org/compare
re-exec error: exit status 1: output: time="2020-06-02T18:00:44+01:00" level=error msg="hcsshim::ImportLayer - failed failed in Win32: The system cannot find the path specified. (0x3)" error="hcsshim::ImportLayer - failed failed in Win32: The system cannot find the path specified. (0x3)" importFolderPath="D:\\Docker\\tmp\\hcs894249803" path="\\\\?\\D:\\Docker\\windowsfilter\\a0eea805d4dac2f148f2cb7f8a8620c96f22242d76a2ebb94d457745bdce7190"
hcsshim::ImportLayer - failed failed in Win32: The system cannot find the path specified. (0x3)
Describe the results you expected: Image created successfully, as it was happening for a long time.
Additional information you deem important (e.g. issue happens only occasionally):
Something changed in cygwin, as failure observed on hosts where it was installing successfully before and there were no changes in docker on these hosts. I see the same issue on docker 19.03.05, 19.03.08, 19.03.11 and master, on windows server 1903, windows server 2004 and windows 10 2004, using mcr.microsoft.com/windows:1903
, mcr.microsoft.com/windows:2004
and mcr.microsoft.com/windows/servercore:2004
base images - I could not install cygwin anywhere anymore.
Output of docker version
:
Client: Docker Engine - Community
Version: 19.03.8
API version: 1.40
Go version: go1.12.17
Git commit: afacb8b
Built: Wed Mar 11 01:23:10 2020
OS/Arch: windows/amd64
Experimental: true
Server: Docker Engine - Community
Engine:
Version: 19.03.8
API version: 1.40 (minimum version 1.24)
Go version: go1.12.17
Git commit: afacb8b
Built: Wed Mar 11 01:37:20 2020
OS/Arch: windows/amd64
Experimental: true
Output of docker info
:
Client:
Debug Mode: false
Server:
Containers: 7
Running: 0
Paused: 0
Stopped: 7
Images: 33
Server Version: 19.03.8
Storage Driver: windowsfilter (windows) lcow (linux)
Windows:
LCOW:
Logging Driver: json-file
Plugins:
Volume: local
Network: ics internal l2bridge l2tunnel nat null overlay private transparent
Log: awslogs etwlogs fluentd gcplogs gelf json-file local logentries splunk syslog
Swarm: inactive
Default Isolation: hyperv
Kernel Version: 10.0 19041 (19041.1.amd64fre.vb_release.191206-1406)
Operating System: Windows 10 Pro Version 2004 (OS Build 19041.264)
OSType: windows
Architecture: x86_64
CPUs: 12
Total Memory: 31.92GiB
Name: beta
ID: KDC4:AXBE:IEZA:QYBJ:RDPR:YGDB:U6NR:7DSX:VQRN:L3IK:L7YI:W5J7
Docker Root Dir: D:\Docker
Debug Mode: true
File Descriptors: -1
Goroutines: 28
System Time: 2020-06-02T18:03:58.8208563+01:00
EventsListeners: 1
Registry: https://index.docker.io/v1/
Labels:
Experimental: true
Insecure Registries:
127.0.0.0/8
Live Restore Enabled: false
Product License: Community Engine
Additional environment details (AWS, VirtualBox, physical, etc.): Physical machines and Proxmox VMs, Windows 10 and Windows Server (SAC)
About this issue
- Original URL
- State: open
- Created 4 years ago
- Comments: 33 (6 by maintainers)
Commits related to this issue
- try workaround from https://github.com/moby/moby/issues/41058#issuecomment-653865175 — committed to project-everest/everest-ci by tahina-pro 4 years ago
- cleanup Windows docker file test; and workaround issue with cygwin not working on latest docker (https://github.com/moby/moby/issues/41058#issuecomment-653865175) — committed to SophistSolutions/Stroika by LewisPringle 4 years ago
- disable cygwin until docker handles WSL symlinks Docker on Windows does have problems with WSL symlink created by Cygwin since version 3.1.5. See also https://github.com/moby/moby/issues/41058#issuec... — committed to haubi/gentoo-prefix-ci by haubi 4 years ago
- disable cygwin until docker handles WSL symlinks Docker on Windows does have problems with WSL symlink created by Cygwin since version 3.1.5. See also https://github.com/moby/moby/issues/41058#issuec... — committed to haubi/gentoo-prefix-ci by haubi 4 years ago
- Add patched setup to prevent WSL symlinks Use CYGWIN=winsymlinks:lnk and -B option to prevent additional elevation. See https://github.com/moby/moby/issues/41058. — committed to wildmichael/cygwin by deleted user 4 years ago
Cygwin workaround which is working for me - locations and names emulating
cinst cygwin
:So version from May 31st is ok, version from June 1st breaking docker.