Skip to content
View in the app

A better way to browse. Learn more.

Unraid

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Nvidia GTX 1060 VM passthrough issues.

Featured Replies

Hey team,

 

I'm having issues creating a gaming VM, I have followed this guide here https://forums.serverbuilds.net/t/guide-remote-gaming-on-unraid/4248/301.

I am able to get the VM up and running with just the virtual GPU, access by RDP and Anydesk is available.

When I try to passthrough my 1060 the VM starts but the monitor I have connected to the GPU shows no signal and one of the CPU's assign to the VM is pinned at 100%.

I have tried looking at most, if not all of space invader ones videos on VM's, looking on forums, other websites, tried the different BIOS and machine types and even different vBIOS for my GPU to no avail. Anyone have a fix?

Screenshot 2024-04-05 011645.png

Screenshot 2024-04-05 011724.png

Screenshot 2024-04-05 011754.png

  

On 4/2/2024 at 12:26 AM, bmartino1 said:

you will not be able to use the unraid nvdia driver if you have it bound.

the card will need to be bound via iommu to use in a vm properly.

you will need to edit the xml config to fix thr graphic and audio of the g card.

see space invaders video

*this is the secret sauce fix... ^ Thank you Space Invader 

 

You will need to edit the xml near the bottom and fix your audio to be the next function and to stay on the correct bus.


Optional but helpful edits:
#################################

 

Main > flash drive > to add to your grub option:
video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off

 

We want to make sure the 1060 is fully set to vfio in use driver and that nothing touch it's FB to passit for full use in the VM. We also don't want unraid to control the power setting to it, the vm will handle that. This is why the advance eidt options...


example grub config that i run for my unraid same gpu:

Current Grub boot command:

kernel /bzimage
append initrd=/bzroot nvme_core.default_ps_max_latency_us=5500 default_hugepagesz=1G hugepagesz=1G pcie_acs_override=downstream,multifunction transparent_hugepage=always video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off

 

I also recommend adding this to your vfio modprobe to assist with the GPU passing.
tools > system drivers > inuse drop down set to all

scroll to vfio.conf hit the pencil at the right and add this for your system:

*don't forget to save it at the right...
 

we want to edit this config and rebuild the modules and rebuild:

/etc/modprobe.d/vfio.conf

 

softdep nouveau pre: vfio-pci
softdep nvidia pre: vfio-pci
softdep nvidiafb pre: vfio-pci
softdep nvidia_drm pre: vfio-pci
softdep drm pre: vfio-pci

options vfio-pci ids=(your vifds here...) disable_idle_d3=1 enable_sriov disable_denylist disable_vga=1

 

reboot
#########################


lspci -v will tell you what in use drivers there are running in you want to see vfio under the 3090 and audio device.
Fix your xml edits to add mutifunciton to the video portion of the Gcard and fix the bus to match the gcard audio function.

 

On 4/4/2024 at 11:16 AM, bmartino1 said:

Verifying IOMMU parameters

 

dmesg | grep -e DMAR -e IOMMU


Intel will show something similar:

image.png.811138c5b4308713bdd3eddee1bbd471.png

 

There should be a line that looks like "DMAR: IOMMU enabled".

If there is no output, something is wrong.

 

Verify IOMMU interrupt remapping is enabled

 

It is not possible to use PCI passthrough without interrupt remapping. Device assignment will fail with 'Failed to assign device "[device name]": Operation not permitted' or 'Interrupt Remapping hardware not found, passing devices to unprivileged domains is insecure.'.

All systems using an Intel processor and chipset that have support for Intel Virtualization Technology for Directed I/O (VT-d), but do not have support for interrupt remapping will see such an error. Interrupt remapping support is provided in newer processors and chipsets (both AMD and Intel).

To identify if your system has support for interrupt remapping:

 

dmesg | grep 'remapping'

 

If you see one of the following lines:

AMD-Vi: Interrupt remapping enabled

DMAR-IR: Enabled IRQ remapping in x2apic mode ('x2apic' can be different on old CPUs, but should still work)

then remapping is supported.

If your system doesn't support interrupt remapping, you can allow unsafe interrupts
^enabled under unraid VM settings...

image.png.e7e44d62d49c51c603a819d864b16deb.png

Edited by bmartino1

  

On 4/3/2024 at 4:10 PM, bmartino1 said:

 


image.thumb.png.fa330ad3908c425be9bffd19d042a53d.png

I run amd and stubed my 6600xt.
My friend runs a amd and stubed his 3060.

we have stubbed and used a 3090 in testing an know that this works.


step 1: confirm iommu and hvm:

Dashboard top right info:

image.png.889c11adb8225f3e4b63aa13e425cf53.png

next step verify stubed GPU:


/Tools/SysDevs

Tools > system devices

?iommu slot 1?
confirm with 2 green dots by gcard and view vfio bind log:
image.thumb.png.d91ddbfe429e877c9c02daa424f1cfa3.png

 

step 2 vm tab.
confirm gui settings:
image.thumb.png.5e5b4de0ade80fa4b7e5ed56bcc368eb.png

 

add vm> linux 
confirm machine type:

image.png.375844f8c59a32ef90c80cc9545b2d0a.png

must be q35 (can work with ifx but issues. must be version 7 or above.)

 

confirm graphic options:

image.png.cff83751098353fa6e5d178e1639e398.png

 

gui must be set before xml edits!
in my case its a amd card.

image.png.f3c0cccaa37c684d53cc99f40d4ad0bf.png

 

create vm. edit xml
find keybaord and set proper xml edits.

at end of gcard add mutifunction

next one is audi/hdmi driver.
set to same buss and add function 1...

^this is the bare minimum. other optional are side fixes, enhancements and checks to stop error and ease g-card for transition to use in vm.

 

 

image.png

image.png

 

Please post your entire XML code to verify your options and settings.
 

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.