Skip to content

Instantly share code, notes, and snippets.

View AntraXClown's full-sized avatar

AntraX AntraXClown

  • /usr/local/Bostil
  • 10:20 (UTC -03:00)
View GitHub Profile
@AntraXClown
AntraXClown / kvm-gpu-passthrough-on-debian-buster.md
Last active May 27, 2024 12:08 — forked from nephest/kvm-gpu-passthrough-on-debian-buster.md
Setting up KVM with GPU passthrough in Debian Buster

Here's how to set up a Windows 11 virtual machine in KVM with PCI passthrough. The VM will have access to an NVIDIA graphics card while the host machine (running Debian Buster) uses Intel integrated graphics. This is mostly for my own reference so I don't forget how I did it.

Hardware

  • AMD Ryzen 7 7700 (16) with integrated graphics: this will be used as the graphics card for the host machine running Arch Linux
  • Gigabyte NVIDIA Geforce RTX40601070: this will be used as the graphics card for the Windows 11 VM

Step 1: Enable IOMMU

In order to do hardware passthrough with KVM at all, you need to enable the Intel Vt-d virtualization extensions. Edit /etc/default/grub and edit the GRUB_CMDLINE_LINUX_DEFAULT line so that it reads like: