docker / for-win

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

WSL Integration doesn't work and causes WSL to hang #13774

Open cbruce80 opened 12 months ago

cbruce80 commented 12 months ago

Description

WSL integration on my Ubuntu WSL2 distro does not work.

I have reinstalled Docker Desktop countless times and used clean new WSL Ubuntu images but integration doesn't seem to work ever.

When I check 'Enable integration with my default WSL distro' and Ubuntu is my default WSL distro, Docker desktop won't start and becomes unresponsive.

When I select Ubuntu under 'Enable integration with additional distros', my distro generally becomes unresponsive. If I restart WSL, I get errors when running docker or even running cd /mnt

It should be noted that I am on a corporate machine and have programs like BeyondTrust running for privilege management, however I can run Linux containers just fine.

Reproduce

  1. Make your WSL default by running wsl --set-default Ubuntu
  2. Start Docker Desktop
  3. Docker Engine will fail to start and spin indefinitely.

Expected behavior

I should be able to run docker and use it in my WSL distro.

docker version

Client:
 Cloud integration: v1.0.35+desktop.5
 Version:           24.0.6
 API version:       1.43
 Go version:        go1.20.7
 Git commit:        ed223bc
 Built:             Mon Sep  4 12:32:48 2023
 OS/Arch:           windows/amd64
 Context:           default

Server: Docker Desktop 4.25.0 (126437)
 Engine:
  Version:          24.0.6
  API version:      1.43 (minimum version 1.12)
  Go version:       go1.20.7
  Git commit:       1a79695
  Built:            Mon Sep  4 12:32:16 2023
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          1.6.22
  GitCommit:        8165feabfdfe38c65b599c4993d227328c231fca
 runc:
  Version:          1.1.8
  GitCommit:        v1.1.8-0-g82f18fe
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

docker info

Client:
 Version:    24.0.6
 Context:    default
 Debug Mode: false
 Plugins:
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.11.2-desktop.5
    Path:     C:\Program Files\Docker\cli-plugins\docker-buildx.exe
  compose: Docker Compose (Docker Inc.)
    Version:  v2.23.0-desktop.1
    Path:     C:\Program Files\Docker\cli-plugins\docker-compose.exe
  dev: Docker Dev Environments (Docker Inc.)
    Version:  v0.1.0
    Path:     C:\Program Files\Docker\cli-plugins\docker-dev.exe
  extension: Manages Docker extensions (Docker Inc.)
    Version:  v0.2.20
    Path:     C:\Program Files\Docker\cli-plugins\docker-extension.exe
  init: Creates Docker-related starter files for your project (Docker Inc.)
    Version:  v0.1.0-beta.9
    Path:     C:\Program Files\Docker\cli-plugins\docker-init.exe
  sbom: View the packaged-based Software Bill Of Materials (SBOM) for an image (Anchore Inc.)
    Version:  0.6.0
    Path:     C:\Program Files\Docker\cli-plugins\docker-sbom.exe
  scan: Docker Scan (Docker Inc.)
    Version:  v0.26.0
    Path:     C:\Program Files\Docker\cli-plugins\docker-scan.exe
  scout: Docker Scout (Docker Inc.)
    Version:  v1.0.9
    Path:     C:\Program Files\Docker\cli-plugins\docker-scout.exe

Server:
 Containers: 0
  Running: 0
  Paused: 0
  Stopped: 0
 Images: 1
 Server Version: 24.0.6
 Storage Driver: overlay2
  Backing Filesystem: extfs
  Supports d_type: true
  Using metacopy: false
  Native Overlay Diff: true
  userxattr: false
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 1
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local logentries splunk syslog
 Swarm: inactive
 Runtimes: io.containerd.runc.v2 runc
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 8165feabfdfe38c65b599c4993d227328c231fca
 runc version: v1.1.8-0-g82f18fe
 init version: de40ad0
 Security Options:
  seccomp
   Profile: unconfined
 Kernel Version: 5.15.90.1-microsoft-standard-WSL2
 Operating System: Docker Desktop
 OSType: linux
 Architecture: x86_64
 CPUs: 20
 Total Memory: 15.46GiB
 Name: SEA-CBRUCE4
 ID: af94473e-54d1-46c8-8450-6d2da9e22199
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 HTTP Proxy: http.docker.internal:3128
 HTTPS Proxy: http.docker.internal:3128
 No Proxy: hubproxy.docker.internal
 Experimental: false
 Insecure Registries:
  hubproxy.docker.internal:5555
  127.0.0.0/8
 Live Restore Enabled: false

WARNING: No blkio throttle.read_bps_device support
WARNING: No blkio throttle.write_bps_device support
WARNING: No blkio throttle.read_iops_device support
WARNING: No blkio throttle.write_iops_device support
WARNING: daemon is not using the default seccomp profile

Diagnostics ID

43BE94C0-97D6-40C5-B39A-2494F11773D9/20231101180613

Additional Info

com.docker.wsl-distro-proxy.exe.log

[2023-10-31T22:22:07.809549500Z][com.docker.wsl-distro-proxy.exe][I] start wsl integration for distro Ubuntu
[2023-10-31T22:22:07.876765700Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e sh -c mkdir -p ~/.docker/run
[2023-10-31T22:22:08.674843500Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e sh -c cat ~/.docker/config.json
[2023-10-31T22:22:09.318677400Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e sh -c cat - > ~/.docker/config.json
[2023-10-31T22:22:10.062535000Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e sh -c mkdir -p ~/.docker/scan
[2023-10-31T22:22:10.733380300Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e sh -c cat ~/.docker/scan/config.json
[2023-10-31T22:22:11.387742700Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e sh -c cat - > ~/.docker/scan/config.json
[2023-10-31T22:22:12.068250400Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e whoami
[2023-10-31T22:22:12.695394000Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -u root -e sh -c ( addgroup docker || true ) && addgroup "cbruce" docker
[2023-10-31T22:22:13.384548000Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e cat /etc/wsl.conf
[2023-10-31T22:22:14.143206200Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e cat /etc/wsl.conf
[2023-10-31T22:22:14.905720100Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e /mnt/wsl/docker-desktop/docker-desktop-user-distro sync-context-store /mnt/c/Users/cbruce/.docker/contexts
[2023-10-31T22:22:15.717089000Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e cat /etc/wsl.conf
[2023-10-31T22:22:16.440288100Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e cat /etc/wsl.conf
[2023-10-31T22:22:17.125125900Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -e /mnt/wsl/docker-desktop/docker-desktop-user-distro sync-home-subdir /mnt/c/Users/cbruce/.aws
-------------------------------------------------------------------------------->8
-------------------------------------------------------------------------------->8
[2023-10-31T23:00:39.776347300Z][com.docker.wsl-distro-proxy.exe][I] kill integration processes for distro Ubuntu
-------------------------------------------------------------------------------->8
-------------------------------------------------------------------------------->8
[2023-10-31T23:04:32.744840200Z][com.docker.wsl-distro-proxy.exe][I] kill leaked integration processes for distro Ubuntu
[2023-10-31T23:04:32.803541700Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -u root -e sh -c ps aux
-------------------------------------------------------------------------------->8
-------------------------------------------------------------------------------->8
[2023-11-01T17:50:44.481366300Z][com.docker.wsl-distro-proxy.exe][I] kill leaked integration processes for distro Ubuntu
[2023-11-01T17:50:44.497373500Z][com.docker.wsl-distro-proxy.exe.linuxworkspaces][I] wsl.exe -d Ubuntu -u root -e sh -c ps aux
bsousaa commented 12 months ago

is this a duplicate of https://github.com/docker/for-win/issues/13764 ?

cbruce80 commented 12 months ago

Unfortunately downgrading did not fix my issue. My distro hangs when running docker or cd /mnt