On an Ubuntu 18.04 system with two NVIDIA GPUs only the change to Grub below was necessary, I did not need to mess with modprobe or initramfs. In addition, I needed to set the PCI bus for the correct nvidia xconfig to the non-blacklisted GPU following these steps
sudo nvidia-xconfig
This will create a new xorg config at /etc/X11/xorg.conf.
Then add the BusID
line in the following part of the file /etc/X11/xorg.conf:
Section "Device"
Identifier "Device0"
Driver "nvidia"
VendorName "NVIDIA Corporation"
BusID "PCI:9:0:0"
EndSection
Source: https://askubuntu.com/questions/787030/setting-the-default-gpu
https://www.reddit.com/r/JDM_WAAAT/comments/8zgkfj/server_build_nas_killer_v_20_the_terminator_dual/ 2x X5650 from this thread Aside from that build guide, a generic USB3 card and an AMD R9-200
Modify /etc/default/grub and add vfio-pci.ids=dead:beef video=efifb:off
to GRUB_CMDLINE_LINUX_DEFAULT (use the PCI vid/pid of your primary GPU, not dead:beef)
# My actual
GRUB_CMDLINE_LINUX_DEFAULT="maybe-ubiquity intel_iommu=on vfio-pci.ids=1002:67b0 video=efifb:off"
Run update-grub
See source for additional details if needed.
sudo apt-get install libvirt-bin bridge-utils virt-manager qemu-kvm ovmf
Then reboot so that the libvirtd
service is started. Then run virt-manager
.