Problem VFIO GPU

Drthrax74

Active Member
Apr 22, 2019
34
4
28
34
Hello,
I would like some help to realize the VFIO on my small machine.
When starting Windows, the machine starts, I see the graphic card via the manager. When installing graphics drivers, the driver refuses to install

Is there a method of circumvention to make the Nvidia driver believe that he is not in a virtualized environment?



Information Hardware:
Code:
VivoMini VM65N
#03:00.0 3D controller [0302]: NVIDIA Corporation GM108M [GeForce 930M] [10de:1346] (rev a2)

Information Software:
pveversion -v
proxmox-ve: 6.0-2 (running kernel: 5.0.15-1-pve)
pve-manager: 6.0-4 (running version: 6.0-4/2a719255)
pve-kernel-5.0: 6.0-5
pve-kernel-helper: 6.0-5
pve-kernel-5.0.15-1-pve: 5.0.15-1
ceph-fuse: 12.2.11+dfsg1-2.1+b1
corosync: 3.0.2-pve2
criu: 3.11-3
glusterfs-client: 5.5-3
ksm-control-daemon: 1.3-1
libjs-extjs: 6.0.1-10
libknet1: 1.10-pve1
libpve-access-control: 6.0-2
libpve-apiclient-perl: 3.0-2
libpve-common-perl: 6.0-2
libpve-guest-common-perl: 3.0-1
libpve-http-server-perl: 3.0-2
libpve-storage-perl: 6.0-5
libqb0: 1.0.5-1
lvm2: 2.03.02-pve3
lxc-pve: 3.1.0-61
lxcfs: 3.0.3-pve60
novnc-pve: 1.0.0-60
proxmox-mini-journalreader: 1.1-1
proxmox-widget-toolkit: 2.0-5
pve-cluster: 6.0-4
pve-container: 3.0-3
pve-docs: 6.0-4
pve-edk2-firmware: 2.20190614-1
pve-firewall: 4.0-5
pve-firmware: 3.0-2
pve-ha-manager: 3.0-2
pve-i18n: 2.0-2
pve-qemu-kvm: 4.0.0-3
pve-xtermjs: 3.13.2-1
qemu-server: 6.0-5
smartmontools: 7.0-pve2
spiceterm: 3.1-1
vncterm: 1.6-1
zfsutils-linux: 0.8.1-pve1
root@proxmox:/etc/pve/qemu-server# ^C
root@proxmox:/etc/pve/qemu-server# pveversion -v
proxmox-ve: 6.0-2 (running kernel: 5.0.15-1-pve)
pve-manager: 6.0-4 (running version: 6.0-4/2a719255)
pve-kernel-5.0: 6.0-5
pve-kernel-helper: 6.0-5
pve-kernel-5.0.15-1-pve: 5.0.15-1
ceph-fuse: 12.2.11+dfsg1-2.1+b1
corosync: 3.0.2-pve2
criu: 3.11-3
glusterfs-client: 5.5-3
ksm-control-daemon: 1.3-1
libjs-extjs: 6.0.1-10
libknet1: 1.10-pve1
libpve-access-control: 6.0-2
libpve-apiclient-perl: 3.0-2
libpve-common-perl: 6.0-2
libpve-guest-common-perl: 3.0-1
libpve-http-server-perl: 3.0-2
libpve-storage-perl: 6.0-5
libqb0: 1.0.5-1
lvm2: 2.03.02-pve3
lxc-pve: 3.1.0-61
lxcfs: 3.0.3-pve60
novnc-pve: 1.0.0-60
proxmox-mini-journalreader: 1.1-1
proxmox-widget-toolkit: 2.0-5
pve-cluster: 6.0-4
pve-container: 3.0-3
pve-docs: 6.0-4
pve-edk2-firmware: 2.20190614-1
pve-firewall: 4.0-5
pve-firmware: 3.0-2
pve-ha-manager: 3.0-2
pve-i18n: 2.0-2
pve-qemu-kvm: 4.0.0-3
pve-xtermjs: 3.13.2-1
qemu-server: 6.0-5
smartmontools: 7.0-pve2
spiceterm: 3.1-1
vncterm: 1.6-1
zfsutils-linux: 0.8.1-pve1

IOMMU :
Code:
File edit : /etc/default/grub
Line edit : GRUB_CMDLINE_LINUX_DEFAULT="quiet intel_iommu=on"
Command to apply the configuration: update-grub


The Modules:
Code:
File edit : /etc/modules
vfio
vfio_iommu_type1
vfio_pci
vfio_virqfd

Command to apply the configuration:  update-initramfs -u
IOMMU interrupt remapping: echo "options vfio_iommu_type1 allow_unsafe_interrupts=1" > /etc/modprobe.d/iommu_unsafe_interrupts.conf
Nvidia: echo "options kvm ignore_msrs=1" > /etc/modprobe.d/kvm.conf


Group IOMMU:
Code:
Command   : find /sys/kernel/iommu_groups/ -type l
Group 14 (/sys/kernel/iommu_groups/14/devices/0000:03:00.0


VFIO.conf:
Code:
File edit: /etc/modprobe.d/vfio.conf

##################################################
# PCI SLOT: 03:00.0
# HARDWARE: NVIDIA Corporation GM108M [GeForce 930M]
# DEV & VEN : 10de:1346 (REV: a2)
##################################################

options vfio-pci ids=10de:1346 disable_vga=1


Blacklist Driver:
Code:
File Edit: /etc/modprobe.d/pve-blacklist.conf

blacklist nvidiafb
blacklist nvidia
blacklist nouveau


VM Configuration:
agent: 1
balloon: 0
bios: ovmf
bootdisk: sata0
cores: 1
cpu: host
efidisk0: DISQUE:104/vm-104-disk-1.qcow2,size=128K
hostpci0: 03:00.0,pcie=1,x-vga=1
ide2: ISO:iso/virtio-win-0.1.171.iso,media=cdrom,size=363020K
machine: q35
memory: 2048
name: VFIO
net0: e1000=5E:09:BE:4E:27:CD,bridge=vmbr0
numa: 0
ostype: win10
sata0: DISQUE:104/vm-104-disk-0.qcow2,backup=0,replicate=0,size=32G,ssd=1
scsihw: virtio-scsi-pci
smbios1: uuid=9bc62ea3-d7ee-4248-9905-b4d7656e6f65
sockets: 4
vga: none
vmgenid: c30bc4f1-b232-4778-92d8-d7507d1f540c

#qm monitor 104
# info pci


# Bus 1, device 0, function 0:
# 3D controller: PCI device 10de:1346
# PCI subsystem 0000:0000
# IRQ 10.
# BAR0: 32 bit memory at 0xc0000000 [0xc0ffffff].
# BAR1: 64 bit prefetchable memory at 0x800000000 [0x80fffffff].
# BAR3: 64 bit prefetchable memory at 0x810000000 [0x811ffffff].
# BAR5: I/O at 0xd000 [0xd07f].
# BAR6: 32 bit memory at 0xffffffffffffffff [0x0007fffe].
# id "hostpci0"


##################################################


03:00.0 3D controller: NVIDIA Corporation GM108M [GeForce 930M] (rev a2)
Kernel driver in use: vfio-pci
Kernel modules: nvidiafb, nouveau

/sys/kernel/iommu_groups/0/devices/0000:00:00.0
/sys/kernel/iommu_groups/1/devices/0000:00:02.0
/sys/kernel/iommu_groups/2/devices/0000:00:08.0
/sys/kernel/iommu_groups/3/devices/0000:00:14.2
/sys/kernel/iommu_groups/3/devices/0000:00:14.0
/sys/kernel/iommu_groups/4/devices/0000:00:15.1
/sys/kernel/iommu_groups/4/devices/0000:00:15.0
/sys/kernel/iommu_groups/5/devices/0000:00:16.0
/sys/kernel/iommu_groups/6/devices/0000:00:17.0
/sys/kernel/iommu_groups/7/devices/0000:00:1c.0
/sys/kernel/iommu_groups/8/devices/0000:00:1c.2
/sys/kernel/iommu_groups/9/devices/0000:00:1c.4
/sys/kernel/iommu_groups/10/devices/0000:00:1d.0
/sys/kernel/iommu_groups/11/devices/0000:00:1d.1
/sys/kernel/iommu_groups/12/devices/0000:00:1f.2
/sys/kernel/iommu_groups/12/devices/0000:00:1f.0
/sys/kernel/iommu_groups/12/devices/0000:00:1f.3
/sys/kernel/iommu_groups/12/devices/0000:00:1f.4
/sys/kernel/iommu_groups/13/devices/0000:02:00.0
/sys/kernel/iommu_groups/14/devices/0000:03:00.0
/sys/kernel/iommu_groups/15/devices/0000:04:00.0
/sys/kernel/iommu_groups/16/devices/0000:05:00.0

dmesg | grep -e DMAR -e IOMMU
[ 0.011900] ACPI: DMAR 0x0000000070ABA5C8 0000F0 (v01 INTEL KBL 00000001 INTL 00000001)
[ 0.059965] DMAR: IOMMU enabled
[ 0.108506] DMAR: Host address width 39
[ 0.108507] DMAR: DRHD base: 0x000000fed90000 flags: 0x0
[ 0.108512] DMAR: dmar0: reg_base_addr fed90000 ver 1:0 cap 1c0000c40660462 ecap 19e2ff0505e
[ 0.108513] DMAR: DRHD base: 0x000000fed91000 flags: 0x1
[ 0.108516] DMAR: dmar1: reg_base_addr fed91000 ver 1:0 cap d2008c40660462 ecap f050da
[ 0.108517] DMAR: RMRR base: 0x000000796d0000 end: 0x000000796effff
[ 0.108518] DMAR: RMRR base: 0x0000007b800000 end: 0x0000007fffffff
[ 0.108519] DMAR: ANDD device: 1 name: \_SB.PCI0.I2C0
[ 0.108519] DMAR: ANDD device: 2 name: \_SB.PCI0.I2C1
[ 0.108521] DMAR-IR: IOAPIC id 2 under DRHD base 0xfed91000 IOMMU 1
[ 0.108521] DMAR-IR: HPET id 0 under DRHD base 0xfed91000
[ 0.108522] DMAR-IR: Queued invalidation will be enabled to support x2apic and Intr-remapping.
[ 0.110143] DMAR-IR: Enabled IRQ remapping in x2apic mode
[ 0.967949] DMAR: ACPI device "device:71" under DMAR at fed91000 as 00:15.0
[ 0.967952] DMAR: ACPI device "device:72" under DMAR at fed91000 as 00:15.1
[ 0.967963] DMAR: No ATSR found
[ 0.967994] DMAR: dmar0: Using Queued invalidation
[ 0.967996] DMAR: dmar1: Using Queued invalidation
[ 0.968010] DMAR: Setting RMRR:
[ 0.968047] DMAR: Setting identity map for device 0000:00:02.0 [0x7b800000 - 0x7fffffff]
[ 0.968084] DMAR: Setting identity map for device 0000:00:14.0 [0x796d0000 - 0x796effff]
[ 0.968091] DMAR: Prepare 0-16MiB unity mapping for LPC
[ 0.968115] DMAR: Setting identity map for device 0000:00:1f.0 [0x0 - 0xffffff]
[ 0.968124] DMAR: Intel(R) Virtualization Technology for Directed I/O

dmesg | grep ecap
[ 0.108512] DMAR: dmar0: reg_base_addr fed90000 ver 1:0 cap 1c0000c40660462 ecap 19e2ff0505e
[ 0.108516] DMAR: dmar1: reg_base_addr fed91000 ver 1:0 cap d2008c40660462 ecap f050da
[ 198.860700] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 198.860716] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 452.008703] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 452.008721] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 773.960701] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 773.960716] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 1485.100720] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 1485.100736] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 1883.240712] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 1883.240726] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 2449.484709] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 2449.484725] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 5229.512788] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 5229.512803] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 5408.456808] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 5408.456822] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900
[ 5581.768806] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x1e@0x258
[ 5581.768821] vfio_ecap_init: 0000:03:00.0 hiding ecap 0x19@0x900

dmesg | grep ecap | awk '{print $NF}'
19e2ff0505e
f050da
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900
0x1e@0x258
0x19@0x900

---

dmesg | grep ecap | wc -l
20

Note:
https://forum.ubuntu-fr.org/viewtopic.php?id=2028872
 
Last edited:
looks mostly ok, there is a bad default with qemu 4.0 which you can circumvent with

'machine: pc-q35-3.1'

and try again. if that does not work, please try a linux guest and see if it works there, if yes, this is most certainly a windows/driver problem
 
Hello,
I'm going to install Geforce experience if it happens to install the driver, because under the utility "snappy driver", it does not find my graphic card.

In HWINFO, he gives me the reference.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!