我看到了几个关于这个主题的问答,并尝试了这两种方法。任何关于如何继续任何一条路线的建议表示赞赏: $docker run --gpus all nvcr.io/nvidia/k8s/cuda-sample:nbody nbody -gpu -benchmark Status: Downloaded newer image for nvcr.io/nvidia/k8s/cuda-sample:nbody docker: Error response from daemon: OCI runtime create failed: container_linux.go:370: starting container process caused: process_linux.go:459: container init caused: Running hook #0:: error running hook: exit status 1, stdout: , stderr: nvidia-container-cli: initialization error: nvml error: driver not loaded: unknown. ERRO[0065] error waiting for container: context canceled
nvidia-docker $ 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 ... docker: Error response from daemon: could not select device driver "" with capabilities: [[gpu]]. 有关于如何修复它的提示 here ,但这完全是关于在 Linux 中运行的 docker。哪个不起作用(见上文)。 此外,从 ubuntu 中删除 docker 后,我仍然可以从 Ubuntu20.04 或运行时运行 docker wsl 来自 Powershell: $ which docker /mnt/c/ProgramData/DockerDesktop/version-bin/docker $ docker The command 'docker' could not be found in this WSL 2 distro. We recommend to activate the WSL integration in Docker Desktop settings. See https://docs./docker-for-windows/wsl/ for details. 我已经在 Docker 设置的两个不同选项卡中为 Ubuntu 20.04 启用了基于 WSL2 的引擎和集成。 系统 Windows 10 WSL 2 Ubuntu 20.04 within WSL2 Windows Docker with WSL2-based engine and integration enabled 非常感谢如何进一步诊断它的任何帮助 最佳答案 我认为在 WSL2 上运行 nVidia GPU (CUDA) 的最佳方法是遵循 nVidia 文档中的教程 CUDA on WSL .您需要按顺序正确执行三件事:
This error usually indicates that the right Microsoft Windows Insider Preview Builds, WSL 2, NVIDIA drivers and NVIDIA Container Toolkit may not be installed correctly. 关于docker - 在 Windows 10 + WSL2 上运行 nvidia-docker,我们在Stack Overflow上找到一个类似的问题: https:///questions/65295415/ |
|