Skip to content

Instantly share code, notes, and snippets.

@Ethorbit
Created August 6, 2023 02:42
Show Gist options
  • Save Ethorbit/5dc77c969cf79d205a1dc961cc854bdd to your computer and use it in GitHub Desktop.
Save Ethorbit/5dc77c969cf79d205a1dc961cc854bdd to your computer and use it in GitHub Desktop.
Unbinds my NVIDIA GPU from the VFIO drivers and binds them to the nvidia drivers so the GPU can be used normally on the host again.
#!/bin/bash
virsh nodedev-reattach pci_0000_26_00_0
virsh nodedev-reattach pci_0000_26_00_1
modprobe nvidia
modprobe nvidia_modeset
modprobe nvidia_uvm
modprobe nvidia_drm
systemctl start nfancurve.service
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment