Setting up windows gaming VM with dedicated graphics card passthrough using VFIO driver
I’m fairly familiar with how to do this on non immutable distributions, as I used to daily drive fedora workstation 36 all the way up to fedora 40. However I am at a bit of a loss as to how to handle setting it up on Bazzite. Is there a different process to modify grub to handoff the GPU to the vfio driver? I am trying to passthrough an Nvidia RTX 2080 super, while the bazzite OS will run on AMD 7900xtx.
20 Replies
@HikariKnight
exactly the same just different way to handle initramfs and grub, we automated most of it with
ujust setup-virtualization
, everything in there expects that you installed libvirt and virt-manager through this too.
Enable virtualization --> enable vfio drivers (and follow instructions on how to bind your gpu to vfio-pci through grub using rpm-ostree
) --> enable kvmfr module (if you are going to use looking-glass)
then everything else you have to do in virt-manager as usual.
process is slow as it will layer libvirt and virt-manager, then it has to rebuild initramfs on both the vfio step and kvmfr step. so if you think it is taking a long time, it is expected as rpm-ostree shows no progress bars.
It just is not an advertised feature because we dont want to become "the vfio" system when it is something that is considered experimental and highly niche (and lets not mention the giant pile of unsupported configs)
but we do recognize that some people (like me) like playing some games through a VM rather than dual boot.On fedora 40 I used a custom compiled version of qemu with patches to hide virtualization, how would I go about using that? I’m assuming I can’t just make install right?
For context this is what I was using:
GitHub
GitHub - zhaodice/qemu-anti-detection: A patch to hide qemu itself,...
A patch to hide qemu itself, bypass mhyprot,EAC,nProtect / VMProtect,VProtect, Themida, Enigma Protector,Safegine Shielden - zhaodice/qemu-anti-detection
if its an rpm or in copr, you can just layer that and just replicate what we do in the
Enable virtualization
step
you can get the source for the ujust with ujust --show setup-virtualization
i would recommend looking into adding it to copr if you havent already, that way you can easily have it update and you can easily add it to an rpm-ostree based system in the future
if you got any more questions i will answer them after work todayThanks
heading to work in a bit and i got 7 hours of meetings 😵
Oof 😅 that’s rough
end of season work for me, planning for stuff after summer
I am following along with this as well as the guide posted on the Bazzite site and I seem to have hit a snag after compiling. it opens in the terminal and I get two errors that say "Invalid value provided to the option: app:shmFile
Error: Invalid path to the ivshmem file specified
Valid values are:
* /dev/kvmfr0
"
you havent told it where to find kvmfr0
looking-glass-client --help
also make sure you have enabled the kvmfr module through ujust setup-virtualization
Thank you! I will have to play around with the first part of this. I do have kvmfr active already
make sure
/dev/kvmfr0
exists then. we have had someone who managed to get an invisible character into the modprobe config which then made the module not loadI ran ls and I can see it in the list
then try
looking-glass-client -f /dev/kvmfr0
Progress! It opened! Now saying that the host application is not running or the virtual machine is still starting up
thats all thats needed
add this to
~/.config/looking-glass/client.ini
that will make it so you do not need to do -f /dev/kvmfr0
Looks like it's happy with that!
for anyone else who has this issue:
GitHub
Install on fedora ublue distributions · Issue #81 · zhaodice/qemu-...
How would I go about using this patch with something like fedora bazzite?