Issue:
Failed to run any docker container with error “Insufficient system resources exist to complete the requested service”
Symptoms
- Container failed to start with error message:
C:\Program Files\Docker\docker.exe: Error response from daemon: hcsshim::CreateComputeSystem bd73ec29a3e3760f8d7be943afb56fb46350d253f50ca685f760a245c1a7df10: Insufficient system resources exist to complete the requested service.
- Issue is also observed with New Containers. Containers failed to start with same error
- Inspect network configuration of Container, IP address configuration missing
Cause
When container starts NET_LUID index for an NDIS loopback interface is allocated from registry key
HKLM\SYSTEM\ControlSet001\Services\NDIS\IfTypes\24\IfUsedNetLuidIndices
and when container stops it will be released. But if you restart computer where multiple containers are running then those values will not be released
Example: If we have multiple automatically starting containers or scheduled restarts then eventually that registry key value will run out of free indexes
And we will not be able to start containers anymore.
Solution
- Navigated to following Windows Registry:
HKLM\SYSTEM\ControlSet001\Services\NDIS\IfTypes\24\
- Deleted following REG_BINARY: IfUsedNetLuidIndices
- Created a new REG_BINARY with same name: IfUsedNetLuidIndices
- Stated affected Containers
Additional Information
Investigations show container fails to start while trying to allocate a NET_LUID index for an NDIS loopback interface
container!container::NetworkProvider::SetupCompartment call (in vmcompute.exe) is failing in NDIS!ndisIfAllocateAndVerifyNetLuidIndex
In the registry , we can see that all indexes are allocated and not available
HKLM: “\REGISTRY\MACHINE\SYSTEM\ControlSet001\Services\ndis\IfTypes\24”
REG_DWORD IfType 18
REG_BINARY IfUsedNetLuidIndices 0xffffdc0877cedbd4
ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff …..