Installing NVIDIA drivers
Applications deployed on VMs utilize CUDA for GPU acceleration, with GPU access provided by the NVIDIA driver. You can either use an image with pre-installed drivers or install the drivers manually either when creating an image or from within an existing VM.
Note
Compute Cloud performs health checks and recommends installing only LTS versions of drivers
Select a driver on the NVIDIA website
On the official NVIDIA website, select a driver compatible with your VM's GPU and OS.
- Go to the search page
. - Under Product Category, select
Data Center / Tesla. - In the Product Series field, select
V-Series. - Under Product field, select
Tesla V100. - In the Operating System field, select the OS installed on your VM.
- Specify the remaining settings to match your OS and driver requirements.
- Click Find.
- Navigate to the driver page. The CUDA Toolkit field displays the maximum CUDA version supported by this driver.
- Go to the search page
. - Under Product Category, select
Data Center / Tesla. - In the Product Series field, select
A-Series. - Under Product field, select
NVIDIA A100. - In the Operating System field, select the OS installed on your VM.
- Specify the remaining settings to match your OS and driver requirements.
- Click Find.
- Navigate to the driver page. The CUDA Toolkit field displays the maximum CUDA version supported by this driver.
Install the driver
For NVIDIA® Ampere® A100, you can install the driver directly from the official repository. Connect to the VM over SSH and run:
sudo apt update
sudo apt install -y nvidia-driver-<driver_version>-server
Where <driver_version> is the major driver version from the NVIDIA website. For example, version 580.178.04 maps to the nvidia-driver-580-server package name.
NVIDIA® Tesla® V100 utilizes an older architecture that is incompatible with some driver versions. If a compatible package is missing from your connected repositories or if errors occur, install the driver from the NVIDIA website.
To install the driver manually:
- Connect to the VM over SSH.
- Copy the direct link to the installer file from the driver page.
- Download the installer using
wget, then follow the NVIDIA Ubuntu installation guide .
If you fail to download the installer from the VM, save it to your local computer and copy it to the VM via SCP.
Test the driver and CUDA version
After completing the driver installation, run the following command on the VM:
nvidia-smi
If the driver works correctly and the GPU is available, the command will output a table with GPU info. The Driver Version field indicates the driver version, and the CUDA Version field shows the maximum CUDA release it supports.
On a multi-GPU VM, check the status of NVLink connections:
nvidia-smi nvlink -s
To find out the installed CUDA Toolkit version, run this command:
nvcc --version
The version is specified in the Cuda compilation tools, release ... output string and must be compatible with the installed driver. For more information on installing and configuring CUDA Toolkit, refer to this NVIDIA guide