Docker socket becomes unreachable - SSH tunnel dies silently (VZ + macOS)

Author: eramellaCreated Feb 3, 2026Updated Sep 11, 2026
Labelskind/bug

Actual Behavior

Environment

  • Rancher Desktop version: 1.22.0 (also reproduced on 1.21.0)
  • macOS version: 26.2 (Build 25C56)
  • Machine: Apple M3 Pro (ARM64)
  • VM type: VZ (Virtualization.framework)
  • Mount type: virtiofs
  • Rosetta: enabled
  • Container engine: moby

Describe the bug The Docker socket at ~/.rd/docker.sock becomes unreachable after periods of inactivity (30-90 minutes), even though the Lima VM continues running normally. The SSH tunnel that forwards the Docker socket from the guest to the host dies silently without any error in the logs.

Steps to Reproduce

  • Start Rancher Desktop with VZ virtualization
  • Verify Docker works: docker ps
  • Leave machine idle for 60-90 minutes (e.g., during a meeting, screen locked)
  • Attempt to use Docker: docker ps

Result

Actual behavior

bash
$ docker ps
Cannot connect to the Docker daemon at unix:///Users/username/.rd/docker.sock. Is the docker daemon running?

Meanwhile, the VM is still running:

bash
$ LIMA_HOME=~/Library/Application\ Support/rancher-desktop/lima \
  /Applications/Rancher\ Desktop.app/Contents/Resources/resources/darwin/lima/bin/limactl list
NAME    STATUS     SSH                VMTYPE    ARCH       CPUS    MEMORY    DISK
0       Running    127.0.0.1:50845    vz        aarch64    6       16GiB     100GiB

The SSH forwarding process is gone:

bash
$ ps aux | grep -E "ssh.*lima.*docker" | grep -v grep
(no output)

Logs The ha.stderr.log shows the tunnel being established at startup but no error when it dies - it simply stops silently.

Frequency This has occurred consistently across multiple days:

  • Reproduced on v1.21.0 (Jan 21, Jan 30)
  • Reproduced on v1.22.0 (Feb 3)

The tunnel typically survives 1-2 hours of active use but dies during idle periods.

Workaround The only recovery is rdctl shutdown && rdctl start, which makes all existing clusters unreachable.

ha.stderr.log

Expected Behavior

Docker socket should remain accessible as long as the VM is running.

Additional Information

  • Switching to QEMU is not viable because we need Rosetta for x86 container images
  • The issue appears related to macOS sleep/idle states affecting the SSH ControlMaster connection
  • The socket file ~/.rd/docker.sock remains but is stale

Rancher Desktop Version

1.22.0

Rancher Desktop K8s Version

n/a

Which container engine are you using?

moby (docker cli)

What operating system are you using?

macOS

Operating System / Build Version

Build 25C56

What CPU architecture are you using?

arm64 (Apple Silicon)

Linux only: what package format did you use to install Rancher Desktop?

None

Windows User Only

No response

Source: rancher-sandbox/rancher-desktop