Return to

Play games in Windows on Linux! PCI passthrough quick guide


Have any idea how? I’ve been researching and I cant find anything that makes sense to me or doesn’t have the high possibility of crashing my entire OS. Side question how did you learn all of this and where should I start? I cant believe how many threads I’ve seen you in



Try disabling apparmor completely temporarily with `sudo systemctl stop apparmor´ then try starting the vm. You can re-enable later with systemctl start or by rebooting.

I learned about this by trying to setup a passthrough vm, running into a roadblock, reasearching it, fixing it, and repeating. And also lots of reading of various blog and forum posts, also watching some(mostly l1t) videos.

1 Like



I’m just setting up a VM at the moment. I have a 3TB games HDD. Can I pass through the partition or do I need to borrow another 3TB HDD to copy everything off, then format my one to use a virtual disk?

(Context: I have a pfsense router at my place but my current residence has some really weird internet / router issues, and Windows doesn’t play well with OpenVPN by not routing everything through it properly - by putting Windows inside of Linux and Linux VPN’ing to my pfsense box, Windows is completely unaware of any VPN and should work fine. I’ve also been meaning to set up hardware passthrough for a while anyway.)




I have thought of a potential answer to my own question here, although I’m not sure if it would work…
Samba share? Would Steam / Uplay play well with it?



You could potentially use a Samba share, however, it likely would not perform very well, and you can indeed pass a partition to a VM, you would just need to go through virt-manager, add a new storage device and select “select or create custom storage”, and input the device ID in the field, you could use /dev/sdXY, however, I recommend using /dev/disk/by-uuid/, either will work well, but the UUID should be constant.



Maybe this guide needs an update for forgoing the ACS patch for the GPUs and using 2 of the same GPU, and using a shell script in the initial RAM disk:



intel®Xeon ® E3 - 1200/1500 v5/6th GEN intel® core ™ GAUSSIAN MIXTURE MODEL -1911 GPU==NVDIA Geforce GTX 1050 & GeForce GTX 960

This will work ??? plz reply

1 Like



i have a problem i have set up a vm with kvm and gpu passthrough. through this guide. This now runs fine with the settings I also see that he uses my graphics card (GEFORCE GTX 1080). But as soon as I start a game with directx 12 (in this case Fifa 19) a program is started but this screen remains black.

Is there perhaps someone who knows a solution to this problem.

Thanks in advance,



Did you setup the hack so the GeForce experience doesn’t know its in a VM?



According to Me, the hack is the first line change to

<domain type='kvm' xmlns:qemu=''>

and at the end these three lines

    <qemu:arg value='-cpu'/>
    <qemu:arg value='host,hv_time,kvm=off,hv_vendor_id=null'/>

if yes then i have done this.



Hmm that is weird. Are you running it though looking glass or is it directly plugged to a monitor?



I have an HDMI cable that goes from my motherboard (MSI Z370 gaming pro carbon ac) to my monitor. I also have displayport cable from my graphic card to the same monitor.
The host runs Ubuntu 19.04 from here I start a vm windows 10 then I switch to the display port and then windows 10 runs here.



Is it only that game?



I think it has something to do with DirectX.
I also Football tried Football Manager 2019 and it works (it could be that it would also work on a normal VM).



Is QXL video driver still installed? If you open Device Manager in windows and go to display adapters make sure only the Nvidia one is listed. That ought to fix it. And by listed I mean remove/uninstall + delete the QXL driver. You’ll probably have to reboot the VM after as well.



I’ll have a look tonight or tomorrow. cannot access my computer now. I’ll let you know how it went.



I have looked and With display adapters only nvidia 1080 is indicated. It was weird a few days ago I had it working via proxmox (debian). now i used exactly the same guide as a few days ago to run it on proxmox again but it doesn’t work there anymore either.



Hey guys, I need some help (pretty please?). I might have skipped some steps here and there (I’m using Manjaro), but here’s my problem:
I configured the Windows VM, but when I power it on, my CPU fan starts ramping up, I can see CPU usage in Virt-Manager, but when I switch the input of my TV to my GPU, there’s a black screen. I passed through a GT1030, a PCI-E USB expansion card and the Sata controller. I had Windows installed long before I decided to virtualize it, it’s on a Sata SSD and I have Linux on an M.2 drive (glorious Adata SX8200 Pro that Wendell reviewed).

I’m not sure what I should post, my VM config xml? Or anything else that can help us debug this issue? Booting into Windows works fine. Any ideas?

Edit: I usually Force Off the VM from Virt-Manager, but it seems Windows Event Viewer doesn’t report anything. No boot, no “unclean” shutdown, nothing. It seems my problem lies in booting this, but I have no idea where to start looking. The <disk> part is set to /dev/sda (yes, that is the drive) and just as it is in the guide, but ‘sata’ instead of ‘virtio’. I could post the VM xml if I have too.



Since you are using Manjaro, I would recommend using this guide to setup passthrough

For passthrough, use a guide for the distro or distro family you are using and ideally one for the exact version of your distro. So for Arch based distros, use the Wiki page since it is maintained and up to date.

Read that page, then make a new thread if you have problems.



pasting the xml would be handy, using the summary bit will stop it being super long :slight_smile:

you could alternatively try without using the existing drive, just setting up a storage pool, and seing if you can install a fresh copy of windows (don’t bother with the key yet)
It might be drivers causing an issue.