Can't run cuda with docker on WSL

Following is fail log

sudo docker run --gpus all nvcr.io/nvidia/k8s/cuda-sample:nbody nbody -gpu -benchmark
Unable to find image ‘nvcr.io/nvidia/k8s/cuda-sample:nbody’ locally
nbody: Pulling from nvidia/k8s/cuda-sample
11323ed2c653: Pull complete
b6166589502e: Pull complete
df6d4a51da82: Pull complete
a65da20ce53d: Pull complete
f02d6169d353: Pull complete
56e9fab00773: Pull complete
af3342639518: Pull complete
95e5f8cb48e9: Pull complete
ba0cb6713727: Pull complete
Digest: sha256:fa0c8b471d223df44b82795dee54a7bc36d372fc5a2c7197f8df89e30f2abf48
Status: Downloaded newer image for nvcr.io/nvidia/k8s/cuda-sample:nbody
docker: Error response from daemon: failed to create shim task: OCI runtime create failed: runc create failed: unable to start container process: error during container init: error running hook #0: error running hook: signal: segmentation fault, stdout: , stderr:: unknown.
ERRO[0022] error waiting for container: context canceled

nvidia-smi.exe
Mon Jun 6 17:04:34 2022
±----------------------------------------------------------------------------+
| NVIDIA-SMI 512.96 Driver Version: 512.96 CUDA Version: 11.6 |
|-------------------------------±---------------------±---------------------+
| GPU Name TCC/WDDM | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 NVIDIA GeForce … WDDM | 00000000:01:00.0 On | N/A |
| N/A 47C P8 14W / N/A | 970MiB / 6144MiB | 6% Default |
| | | N/A |
±------------------------------±---------------------±---------------------+

hardware is AMD R9 5900HX with RTX 3060 laptop GPU

1 Like

I found the reason: my windows 10 version is 21H1 not 21H2

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.