docker / for-win

Bug reports for Docker Desktop for Windows
https://www.docker.com/products/docker#/windows
1.86k stars 290 forks source link

docker 4.14.0 Error response from daemon: open \\.\pipe\docker_engine_windows: The system cannot find the file specified #13075

Open cybersymphony opened 1 year ago

cybersymphony commented 1 year ago

when you install docker 4.14.0, after switching to windows containers mode, basic docker commands (even sample docker container command) fails with Error response from daemon: open \.\pipe\docker_engine_windows: The system cannot find the file specified but if you install docker 4.11.0, switch to windows containers mode, run "Enable-WindowsOptionalFeature -Online -FeatureName $("Microsoft-Hyper-V", "Containers") -All" and update to 4.14.0 it works fine.

I am not sure which one is the solution whether running "Enable-WindowsOptionalFeature -Online -FeatureName $("Microsoft-Hyper-V", "Containers") -All" or updating from 4.11 to 4.14.

ss from a turkish os docker

bredar commented 1 year ago

Having the same issue. Noticed, Version 4.14.0 didn't complained about to install container services:

Enable-WindowsOptionalFeature -Online -FeatureName $("Microsoft-Hyper-V", "Containers") -All

monban commented 1 year ago

Also having this issue:

os: Microsoft Windows 10 Enterprise 10.0.19042 (build 19042)
Docker:  4.14.1 (91661)

Linux containers work fine, but attempting to run docker info after switching to Windows containers yields the following error:

PowerShell 7.3.0
~⚡ docker info
Client:
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc., v0.9.1)
  compose: Docker Compose (Docker Inc., v2.12.2)
  dev: Docker Dev Environments (Docker Inc., v0.0.3)
  extension: Manages Docker extensions (Docker Inc., v0.2.13)
  sbom: View the packaged-based Software Bill Of Materials (SBOM) for an image (Anchore Inc., 0.6.0)
  scan: Docker Scan (Docker Inc., v0.21.0)

Server:
ERROR: Error response from daemon: open \\.\pipe\docker_engine_windows: The system cannot find the file specified.
errors pretty printing info

Installing Microsoft-Hyper-V and Containers features had no effect, as they were already installed. I have confirmed that downgrading to Docker v4.13.1 fixes the problem, so it's definitely something in the v4.14 branch.

rhyscooper commented 1 year ago

I had the same issue, enabling windows optional features resolved this for me.

MolotovCherry commented 1 year ago

Same issue. Only happened after installing the latest version.

Previously docker worked 100%. I already have required features installed

4.13.1 works perfectly. For now, I recommend to either downgrade or don't upgrade.

tnabil commented 1 year ago

I also had to upgrade from 4.14.1 to 4.13.1 to get over this issue!

ebwinters commented 1 year ago

can confirm @rhyscooper's solution works

forderud commented 1 year ago

Same here. Manually enabling the Windows "Containers" feature fixed the problem for me: image

It would be appreciated if Docker could either clearly inform about this or automatically enable the "Containers" feature during installation.

mk185147 commented 1 year ago

The issue is still even on 4.15. I tried reinstalling Docker Desktop and removing and adding back windows features, it didn't help. Windows Containers were working to me on 4.13.1.

Output of com.docker.diagnose.exe check:

[2022-12-05T12:37:48.645114800Z][com.docker.diagnose.exe][I] set path configuration to OnHost
Starting diagnostics

[PASS] DD0027: is there available disk space on the host?
[PASS] DD0028: is there available VM disk space?
[PASS] DD0002: does the bootloader have virtualization enabled?
[SKIP] DD0018: does the host support virtualization?
[PASS] DD0001: is the application running?
[PASS] DD0022: is the Virtual Machine Platform Windows Feature enabled?
[PASS] DD0021: is the WSL 2 Windows Feature enabled?
[PASS] DD0024: is WSL installed?
[PASS] DD0025: are WSL distros installed?
[PASS] DD0026: is the WSL LxssManager service running?
[PASS] DD0029: is the WSL 2 Linux filesystem corrupt?
[PASS] DD0035: is the VM time synchronized?
[PASS] DD0017: can a VM be started?
[PASS] DD0016: is the LinuxKit VM running?
[PASS] DD0011: are the LinuxKit services running?
[PASS] DD0004: is the Docker engine running?
[PASS] DD0015: are the binary symlinks installed?
[PASS] DD0031: does the Docker API work?
[PASS] DD0013: is the $PATH ok?
Error response from daemon: open \\.\pipe\docker_engine_windows: The system cannot find the file specified.
[FAIL] DD0003: is the Docker CLI working? exit status 1
[PASS] DD0005: is the user in the docker-users group?
[PASS] DD0014: are the backend processes running?
[PASS] DD0007: is the backend responding?
[PASS] DD0008: is the native API responding?
[PASS] DD0009: is the vpnkit API responding?
[PASS] DD0010: is the Docker API proxy responding?
[PASS] DD0006: is the Docker Desktop Service responding?
[PASS] DD0012: is the VM networking working?
[SKIP] DD0030: is the image access management authorized?
[PASS] DD0033: does the host have Internet access?
[PASS] DD0002: does the bootloader have virtualization enabled?
[PASS] DD0018: does the host support virtualization?
[PASS] DD0001: is the application running?
[PASS] DD0022: is the Virtual Machine Platform Windows Feature enabled?
[PASS] DD0021: is the WSL 2 Windows Feature enabled?
[PASS] DD0024: is WSL installed?
[PASS] DD0025: are WSL distros installed?
[PASS] DD0026: is the WSL LxssManager service running?
[PASS] DD0029: is the WSL 2 Linux filesystem corrupt?
[PASS] DD0035: is the VM time synchronized?
[PASS] DD0017: can a VM be started?
[PASS] DD0016: is the LinuxKit VM running?
[PASS] DD0011: are the LinuxKit services running?
[PASS] DD0004: is the Docker engine running?
[PASS] DD0015: are the binary symlinks installed?
[PASS] DD0031: does the Docker API work?
[PASS] DD0032: do Docker networks overlap with host IPs?

Please investigate the following 1 issue:

1 : The test: is the Docker CLI working?
    Failed with: exit status 1

The Docker CLI is needed to build, share and run applications.
diman82 commented 1 year ago

The issue is present on 4.15.0 Currently, the only option is to either downgrade or switch to Hyper-V backend.

vlisovych commented 1 year ago

I'm on v4.15.0 and had the same issue. Running Enable-WindowsOptionalFeatur didn't help me.

To fix the issue I've installed and started Docker Engine service:

cd 'C:\Program Files\Docker\Docker\resources\';
.\dockerd.exe -G docker-users --config-file c:\programdata\docker\config\daemon.json --register-service;
Start-Service docker;

Solution from this blog

Elektronenvolt commented 1 year ago

We found the root cause for it on our machines together with Docker Support:

Docker Desktop versions higher than 4.13.1 fail because the registry key HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Policies\Microsoft\FVE exists but FDVDenyWriteAccess is not present. The workaround is to create a DWORD registry key FDVDenyWriteAccess with value set to 0 in HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Policies\Microsoft\FVE

image

Khodashenas commented 1 year ago

Same here. Manually enabling the Windows "Containers" feature fixed the problem for me: image

It would be appreciated if Docker could either clearly inform about this or automatically enable the "Containers" feature during installation.

This solution worked for me, thank you

zoranmax commented 1 year ago

After setting up manually the registry keys (the whole section \Microsoft\FVE was missing) it worked

Elektronenvolt commented 1 year ago

Docker support told me that editing the registry key is a workaround. They are aware of this issue and trying to get out a fix for this. We'll use 4.13.1 until this issue is fixed.

bzuillsmith commented 1 year ago

Docker support told me that editing the registry key is a workaround. They are aware of this issue and trying to get out a fix for this. We'll use 4.13.1 until this issue is fixed.

Hey @Elektronenvolt, did you also need the Container feature of Hyper-V? I added the key but don't have those features installed (only WSL) and it doesn't work for me

Elektronenvolt commented 1 year ago

@bzuillsmith This is an issue with Windows container - you don't need Hyper-V or WSL for it, but "Containers" enabled in your Windows features. I'm not sure which feature you talk about with: Container feature of Hyper-V

If Windows container fail on your machine with 4.13.1 you have another issue - this should point you in the right direction:
C:\Program Files\Docker\Docker\resources\com.docker.diagnose.exe check

jikuja commented 1 year ago

I'm on v4.15.0 and had the same issue. Running Enable-WindowsOptionalFeatur didn't help me.

Solution from this blog

Same blog worked for me. I had to create c:\programdata\docker\config\daemon.json manually.

Docker desktop seriously should warn about missing Container feature.

Elektronenvolt commented 1 year ago

@jikuja - this ticket popped up Nov 2022 as Windows containers started to fail with versions higher than 4.13.1 because HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Policies\Microsoft\FVE exists in the Windows registry but key FDVDenyWriteAccess is not present - (set by group policies on company machines).

In the link you've posted from Jeremy Davis blog - he comes to the same workaround as posted here already. And writes about that the issue is supposed to be fixed with Docker Desktop 4.17 in few weeks.

We stay on Docker Desktop 4.13.1 until 4.17.x will fix this issue, no need to create a daemon.json config manually. As a workaround creating this registry key is enough.

Elektronenvolt commented 1 year ago

Yesterday's 4.17.0 release is fixing this issue on our machines. https://docs.docker.com/desktop/release-notes/#4170

docker-robot[bot] commented 1 year ago

There hasn't been any activity on this issue for a long time. If the problem is still relevant, mark the issue as fresh with a /remove-lifecycle stale comment. If not, this issue will be closed in 30 days.

Prevent issues from auto-closing with a /lifecycle frozen comment.

/lifecycle stale