NVIDIA / nvidia-docker

Build and run Docker containers leveraging NVIDIA GPUs
Apache License 2.0
17.19k stars 2.03k forks source link

Unknown runtime testing nvidia-docker 2 #501

Closed dvenza closed 6 years ago

dvenza commented 6 years ago

I'm trying to test nvidia-docker 2.0 (we start containers via the Docker API and we cannot use 1.0), but I am getting this error:

$ sudo docker run --runtime=nvidia --rm nvidia/cuda nvidia-smi
docker: Error response from daemon: Unknown runtime specified nvidia.
See 'docker run --help'.

Nothing in the Docker daemon logs (not even with debug enabled).

Installed packages:

$ dpkg -l | grep -E '(nvidia|docker)'
ii  docker-ce                          17.09.0~ce-0~ubuntu                        amd64        Docker: the open-source application container engine
ii  libnvidia-container-tools          1.0.0~alpha.1-1                            amd64        NVIDIA container runtime library (command-line tools)
ii  libnvidia-container1:amd64         1.0.0~alpha.1-1                            amd64        NVIDIA container runtime library
ii  nvidia-384                         384.81-0ubuntu1                            amd64        NVIDIA binary driver - version 384.81
ii  nvidia-container-runtime           1.0.0+docker17.09.0-1                      amd64        NVIDIA container tools
ii  nvidia-docker2                     2.0.0+docker17.09.0-1                      all          nvidia-docker CLI wrapper
ii  nvidia-modprobe                    384.81-0ubuntu1                            amd64        Load the NVIDIA kernel driver and create device files
ii  nvidia-opencl-icd-384              384.81-0ubuntu1                            amd64        NVIDIA OpenCL ICD

I could not find anything that tells me where Docker looks for runtimes and how they should be named, either.

3XX0 commented 6 years ago

What's the content of your /etc/docker/daemon.json ?

dvenza commented 6 years ago
{
  "dns": ["192.168.46.1"],
  "dns-search": ["bigfoot.eurecom.fr"],
  "hosts": ["tcp://deepfoot1.containers.bigfoot.eurecom.fr:2375", "unix:///var/run/docker.sock"],
  "cluster-store": "zk://bf1:2181,bf5:2181,bf11:2181/docker",
  "cluster-advertise": "eno2:2375",
  "tlsverify": true,
  "tlscacert": "/mnt/cert-authority/demoCA/cacert.pem",
  "tlscert": "/mnt/cert-authority/deepfoot1/cert.pem",
  "tlskey": "/mnt/cert-authority/deepfoot1/key.pem"
}
3XX0 commented 6 years ago

See #490, the package should have told you that the file conflicted

dvenza commented 6 years ago

Ok, sorry I didn't find it. I merged the config and now it works!