Skip to content

Latest commit

 

History

History
36 lines (29 loc) · 1.43 KB

nvidia-container-toolkit.md

File metadata and controls

36 lines (29 loc) · 1.43 KB

Description

Instructions to install nvidia-container-toolkit in Ubuntu host machines

Following instructions here

curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg \
  && curl -s -L https://nvidia.github.io/libnvidia-container/stable/deb/nvidia-container-toolkit.list | \
    sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
    sudo tee /etc/apt/sources.list.d/nvidia-container-toolkit.list
sudo apt-get update && sudo apt-get install -y nvidia-container-toolkit
sudo nvidia-ctk runtime configure --runtime=docker
sudo systemctl restart docker

Instructions to install cuDNN inside the docker container

  • First download the tar file of cuDNN from the Nvidia website here or the archive here
  • Copy the .tar file to the scratchpad directory in the host machine
  • Run install cudnn library script present in the scratchpad inside the docker container's terminal
    • The script basically moves the tar file to /usr/local and unzips it like so
    sudo mv cudnn* /usr/local 
    cd  /usr/local 
    tar -xzvf cudnn* 
    sudo ldconfig