virtio-nvgpu Brings Shared NVIDIA GPU Access to Linux KVM Guests

Nestri’s experimental virtio-nvgpu project enables Linux KVM guests to access and share NVIDIA GPUs without traditional PCI passthrough.

Nestri Labs is developing virtio-nvgpu, an experimental project that lets Linux KVM guests access NVIDIA GPUs without traditional PCI passthrough. The goal is to allow multiple isolated gaming VMs to use the same NVIDIA GPU, render frames, encode them with NVENC, and stream the result to remote clients.

Instead of assigning an entire GPU to a single VM, virtio-nvgpu keeps the GPU on the Linux host and lets multiple guests share it. Nestri demonstrated four guests using a single GeForce RTX 3060 simultaneously.

The project works with KVM and a custom virtio device. Inside the guest, NVIDIA’s own user-space drivers remain unchanged, while a guest kernel driver forwards the necessary requests to the host NVIDIA driver.

Unlike approaches that translate Vulkan or OpenGL calls, virtio-nvgpu works at the NVIDIA kernel-driver ABI level. This keeps most GPU work inside the guest and reduces communication crossing the VM boundary.

According to Nestri’s benchmarks, performance is close to bare metal with about 2% overhead or less for typical frame workloads. The project also supports Vulkan rendering, Wayland presentation, NVENC encoding, and basic CUDA device enumeration.

The connection to Nestri is direct. Its nesbox project uses lightweight KVM-based microVMs for cloud game streaming. Intel and AMD GPUs already rely on existing virtio-gpu mechanisms, while virtio-nvgpu is being developed to provide similar support for NVIDIA hardware.

For now, virtio-nvgpu remains experimental. It does not provide the same isolation as VFIO passthrough, and support depends on NVIDIA driver ABI compatibility. Still, the project is already functional, with working Vulkan, Wayland, NVENC, and multi-guest GPU sharing.

For more details, see the project’s GitHub repo.

Bobby Borisov

Bobby Borisov

Bobby, an editor-in-chief at Linuxiac, is a Linux professional with over 20 years of experience. With a strong focus on Linux and open-source software, he has worked as a Senior Linux System Administrator, Software Developer, and DevOps Engineer for small and large multinational companies.

One comment

  1. Anonymous

    Looks nice on paper, as always.
    A video tutorial would be more usefull 😉

Leave a Reply

Your email address will not be published. Required fields are marked *