proxmox:gpu_passthrough:configure_proxmox
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
proxmox:gpu_passthrough:configure_proxmox [2021/06/07 10:28] – created peter | proxmox:gpu_passthrough:configure_proxmox [2021/07/14 09:41] (current) – [Restart] peter | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Proxmox - GPU Passthrough - Configure Proxmox ====== | ====== Proxmox - GPU Passthrough - Configure Proxmox ====== | ||
+ | |||
+ | ===== Update Grub ===== | ||
+ | |||
+ | SSH directly into the Proxmox server. | ||
+ | |||
+ | Edit / | ||
+ | |||
+ | Change the line: | ||
+ | |||
+ | <file bash / | ||
+ | GRUB_CMDLINE_LINUX_DEFAULT=" | ||
+ | </ | ||
+ | |||
+ | ==== For an Intel CPU ==== | ||
+ | |||
+ | <file bash / | ||
+ | GRUB_CMDLINE_LINUX_DEFAULT=" | ||
+ | </ | ||
+ | |||
+ | ==== For an AMD CPU ==== | ||
+ | |||
+ | |||
+ | <file bash / | ||
+ | GRUB_CMDLINE_LINUX_DEFAULT=" | ||
+ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | |||
+ | For example: | ||
+ | |||
+ | < | ||
+ | GRUB_CMDLINE_LINUX_DEFAULT=" | ||
+ | </ | ||
+ | |||
+ | * Disabling the Framebuffer: | ||
+ | * ACS Override for IOMMU groups: | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | When editing is finished run this command: | ||
+ | |||
+ | <code bash> | ||
+ | update-grub | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== VFIO Modules ===== | ||
+ | |||
+ | Add a few VFIO (Virtual Function I/O) modules to your Proxmox system. | ||
+ | |||
+ | Add the following to the / | ||
+ | |||
+ | <file bash / | ||
+ | vfio | ||
+ | vfio_iommu_type1 | ||
+ | vfio_pci | ||
+ | vfio_virqfd | ||
+ | </ | ||
+ | |||
+ | Save and exit. | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== IOMMU interrupt remapping ===== | ||
+ | |||
+ | Run the following commands: | ||
+ | |||
+ | <code bash> | ||
+ | echo " | ||
+ | echo " | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Blacklist Drivers ===== | ||
+ | |||
+ | To prevent the Proxmox host system utilizing the GPU(s), some drivers need to be blacklisted. | ||
+ | |||
+ | <code bash> | ||
+ | echo " | ||
+ | echo " | ||
+ | echo " | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Adding GPU to VFIO ===== | ||
+ | |||
+ | ==== Determine the GPU ==== | ||
+ | |||
+ | <code bash> | ||
+ | lspci -v | ||
+ | </ | ||
+ | |||
+ | returns: | ||
+ | |||
+ | <code bash> | ||
+ | 01:00.0 VGA compatible controller: NVIDIA Corporation GP104 [GeForce GTX 1070] (rev a1) (prog-if 00 [VGA controller]) | ||
+ | 01:00.1 Audio device: NVIDIA Corporation GP104 High Definition Audio Controller (rev a1) | ||
+ | </ | ||
+ | |||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | |||
+ | Make note of the first set of numbers (e.g. 01:00.0 and 01:00.1). | ||
+ | |||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ==== Determine the GPU Vendor IDs ==== | ||
+ | |||
+ | Run the command below. | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | </ | ||
+ | |||
+ | |||
+ | <code bash> | ||
+ | lspci -n -s 01:00 | ||
+ | </ | ||
+ | |||
+ | returns: | ||
+ | |||
+ | <code bash> | ||
+ | 01:00.0 0000: 10de:1b81 (rev a1) | ||
+ | 01:00.1 0000: 10de:10f0 (rev a1) | ||
+ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | |||
+ | Make a note of the vendor id codes: 10de:1b81 and 10de:10f0. | ||
+ | |||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | | ||
+ | ==== Add the GPU Vendor IDs to the VFIO ==== | ||
+ | |||
+ | <code bash> | ||
+ | echo " | ||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Update images ===== | ||
+ | |||
+ | <code bash> | ||
+ | update-initramfs -u | ||
+ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | |||
+ | * It lives in RAM, and it provides **just** enough tools and instructions to tell the kernel how to set up the real filesystem, mount the HDD read/write, and start loading all the system services. | ||
+ | * It includes the stub of init, PID #1. | ||
+ | * If your initramfs is broken, your boot fails. | ||
+ | |||
+ | **update-initramfs** is a script that updates initramfs to work with a new kernel. | ||
+ | |||
+ | Updating the initramfs prevents some modules from being loaded. | ||
+ | |||
+ | </ | ||
+ | |||
+ | ---- | ||
+ | |||
+ | ===== Restart ===== | ||
+ | |||
+ | <code bash> | ||
+ | sudo reboot | ||
+ | </ | ||
+ | |||
+ | <WRAP info> | ||
+ | **NOTE: | ||
+ | </ | ||
+ | |||
proxmox/gpu_passthrough/configure_proxmox.1623061702.txt.gz · Last modified: 2021/06/07 10:28 by peter