Skip to main content
Once the GPU is attached to your VPS, the system needs the NVIDIA drivers to use it. This page gives the commands to run for your operating system.
Prerequisites
  • A High Performance VPS with a GPU attached from your instance’s GPU tab, in the console
  • Root SSH access to your server (How to connect)

Check that the GPU is visible

The GPU shows up in the system from the restart that follows the attachment, even before the drivers are installed:
The command prints an NVIDIA Corporation line. If it prints nothing, restart the VPS from the console and run it again.

Install the drivers

Update the system first: the drivers are built for the newest kernel, the one the VPS restarts on.
The drivers come from NVIDIA’s CUDA repository. Branch 595 is NVIDIA’s production branch; pinning it keeps apt from moving to another branch on its own:
The restart takes your VPS offline for a few moments. See Restart for details.

Check the installation

After the restart, nvidia-smi shows the GPU, the driver version, the memory in use and the temperature:
To keep the driver loaded between jobs, which makes them start faster, turn on persistence mode:

Install CUDA (optional)

PyTorch, TensorFlow, Ollama and vLLM bundle the CUDA libraries they need: the driver is enough. To compile your own CUDA code with nvcc, install the CUDA Toolkit:
After a kernel update, restart the VPS: on Debian, Rocky Linux and AlmaLinux, DKMS rebuilds the NVIDIA module for the new kernel, and on Ubuntu the prebuilt modules follow the kernel.