NVIDIA GPU monitoring on Linux and Docker

SkyView reads NVIDIA GPU utilization through nvidia-smi. When SkyView runs in Docker, the NVIDIA driver, GPU devices, matching driver libraries, and nvidia-smi must be exposed by the Docker host. They cannot be provided reliably by installing packages only inside the SkyView container.

If the System Monitor Server tab shows SkyView GPU – N/A, complete the host and Compose setup below.

Requirements

  • A supported NVIDIA GPU and NVIDIA driver on the Linux host
  • Docker Engine and Docker Compose
  • NVIDIA Container Toolkit installed and configured on the host
  • docker-compose.yml and docker-compose.nvidia.yml from the same SkyView release

The normal SkyView image already requests the NVIDIA utility capability used by nvidia-smi. The NVIDIA overlay requests the GPU from Docker. It does not install the host driver or NVIDIA Container Toolkit.

1. Verify the host driver

Run this on the Docker host:

nvidia-smi

Do not continue until this command displays the GPU and driver information. If it fails, install or repair the NVIDIA driver for the host operating system first.

2. Install NVIDIA Container Toolkit on the host

Follow NVIDIA's Container Toolkit installation guide to add the repository and install the package for your Linux distribution.

On Debian or Ubuntu, after adding NVIDIA's package repository, install and configure the toolkit with:

sudo apt-get update
sudo apt-get install -y nvidia-container-toolkit
sudo nvidia-ctk runtime configure --runtime=docker
sudo systemctl restart docker

The nvidia-ctk command updates Docker's host configuration. Restarting Docker activates the NVIDIA runtime.

3. Verify GPU access from Docker

Run NVIDIA's sample container test:

docker run --rm --runtime=nvidia --gpus all ubuntu nvidia-smi

This command must display the GPU. If Docker reports that it cannot select the NVIDIA device driver, verify the toolkit installation, rerun nvidia-ctk runtime configure, and restart Docker.

4. Start SkyView with the NVIDIA overlay

Keep both Compose files in the installation directory, then run:

docker compose -f docker-compose.yml -f docker-compose.nvidia.yml up -d

The second file is a Compose overlay. It adds the NVIDIA GPU device request and driver capabilities to the SkyView service. Do not replace docker-compose.yml with it; both files are required.

To make the overlay selection persistent, add this line to the installation .env file:

COMPOSE_FILE=docker-compose.yml:docker-compose.nvidia.yml

After that, the normal command uses both files:

docker compose up -d

For a SkyView .deb installation, edit /etc/sky-view/sky-view.env instead:

COMPOSE_FILE=docker-compose.yml:docker-compose.nvidia.yml

Then restart the service:

sudo systemctl restart sky-view

5. Verify SkyView

Confirm that nvidia-smi is available inside the running container:

docker exec skyview nvidia-smi

Then open System Monitor → Server in SkyView. After the next monitoring sample, the GPU utilization and SkyView GPU values should be numeric. A value of 0% is valid when the GPU or SkyView process is idle; N/A indicates that monitoring is still unavailable.

Troubleshooting

nvidia-smi fails on the host

The host driver is missing, incompatible, or not loaded. Fix the host driver before troubleshooting Docker.

Docker cannot select the NVIDIA driver

NVIDIA Container Toolkit is missing or is not configured for Docker. Run:

sudo nvidia-ctk runtime configure --runtime=docker
sudo systemctl restart docker

Then repeat the sample container test.

nvidia-smi works on the host but not in SkyView

Recreate SkyView with the overlay so Docker adds the GPU request:

docker compose -f docker-compose.yml -f docker-compose.nvidia.yml up -d --force-recreate

Also confirm that both Compose files came from the same SkyView release.

Installing NVIDIA packages inside SkyView does not help

The NVIDIA kernel driver and GPU device access belong to the host. NVIDIA Container Toolkit performs the required device and driver-library injection when Docker creates the container. Installing the toolkit or a standalone nvidia-smi package inside the application container does not grant GPU access.

Intel or AMD host

Do not enable docker-compose.nvidia.yml. Intel and AMD GPU monitoring uses /dev/dri, the monitoring utilities in the SkyView image, and the permissions in the base docker-compose.yml.