You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Hyper-V isolation: starting a stopped container again fails with failed to add SCSI scratch VHD ... c:\mounts\scsi\m0 ... The directory is not empty #2973
With Hyper-V isolation and the io.containerd.runhcs.v1 runtime, a Windows container based on an ltsc2025 image runs once, then cannot be started again:
failed to create task for container: failed to create shim task: failed to mount container storage: failed to add SCSI scratch VHD: mount scsi controller 0 lun 1 at c:\mounts\scsi\m0: guest RPC failure: The directory is not empty.
With "debug": true, the dockerd log of the failed start contains:
onecore\vm\compute\management\orchestration\vmhostedcontainer\vmhostedcontainerstorage.cpp(418)\vmcomputeagent.exe!00007FF7D0883CEE: (caller: 00007FF7D0875C49) Exception(1) tid(3f4) 80070091 The directory is not empty.
docker run --name repro mcr.microsoft.com/windows/nanoserver:ltsc2025 cmd /c echo hello
docker start -a repro
hello
Error response from daemon: failed to create task for container: failed to create shim task: failed to mount container storage: failed to add SCSI scratch VHD: mount scsi controller 0 lun 1 at c:\mounts\scsi\m0: guest RPC failure: The directory is not empty.
A restart policy gets the same error:
docker run -d --name restart-policy--restart on-failure:3mcr.microsoft.com/windows/nanoserver:ltsc2025 cmd /c "echo run & exit 1"
docker inspect restart-policy--format '{{.State.Status}} {{.RestartCount}} {{.State.Error}}'
exited 1 failed to create task for container: failed to create shim task: failed to mount container storage: failed to add SCSI scratch VHD: mount scsi controller 0 lun 1 at c:\mounts\scsi\m0: guest RPC failure: The directory is not empty.
Results
Same steps (docker run then docker start -a) with the binaries listed below:
containerd-snapshotter
default-runtime
Image
Isolation
docker start
true
io.containerd.runhcs.v1
nanoserver:ltsc2025
hyperv
fails
true
io.containerd.runhcs.v1
nanoserver:ltsc2022
hyperv
works
true
io.containerd.runhcs.v1
nanoserver:ltsc2025
process
works
false
io.containerd.runhcs.v1
nanoserver:ltsc2025
hyperv
fails
false
com.docker.hcsshim.v1
nanoserver:ltsc2025
hyperv
works
Environment
Windows 11 Pro 26H2, OS build 26300.9711, default isolation hyperv
Activity