[SOLVED] Windows VM gives me Code 43 Nvidia GPU


Amanhem

Recommended Posts

I Made a new Windows 10 VM and refollowed all the steps and now it suddenly works.

 

Windows VM gives me Code 43 in device manager. My resolution is locked and downloading Nvidia Drivers does not help, I followed SpaceInvaderOne's guide on how to setup a Windows VM and created a rom for the GPU 

 

So now I can see my Windows VM but there are spots across the screen and I get Code 43. Trying disabling GPU and re enabling, also tried to create another Windows VM following SpaceInvaderOne's tutorials. I also tried re seating the GPU and tried another slot on the MOBO. Have also tried the other method using an AMD GPU as primary GPU. 

1940875392_Devicemanager.PNG.56a551a8b2edd8240e2054ef7e16a168.PNG

80064278_971834523184670_3837216308726857728_n.thumb.jpg.7f2a0287612efadfed276e51ae0be993.jpg

The VM Logs gives me this: 

ErrorWarningSystemArrayLogin


2019-12-24T00:15:14.288366Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dce8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288374Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dcf0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288381Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dcf8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288390Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd00, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288396Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd08, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288405Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd10, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288411Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd18, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288420Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd20, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288426Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd28, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288435Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd30, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288441Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd38, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288450Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd40, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288456Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd48, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288465Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd50, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288472Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd58, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288480Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd60, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288487Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd68, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288502Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd70, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288556Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd78, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288568Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd80, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288574Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd88, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288583Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd90, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288589Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dd98, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288598Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dda0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288604Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dda8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288613Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddb0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288620Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddb8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288628Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddc0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288635Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddc8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288644Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddd0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288650Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddd8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288659Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dde0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288665Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7dde8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288674Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddf0, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.288692Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7ddf8, 0x0,8) failed: Device or resource busy
2019-12-24T00:15:14.294177Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x43f0, 0x2be8dc01,8) failed: Device or resource busy
2019-12-24T00:15:14.294292Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7e000, 0xabcdabcd,4) failed: Device or resource busy
2019-12-24T00:15:14.294303Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7e004, 0xabcdabcd,4) failed: Device or resource busy
2019-12-24T00:15:14.294312Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7e008, 0xabcdabcd,4) failed: Device or resource busy
2019-12-24T00:15:14.294320Z qemu-system-x86_64: vfio_region_write(0000:01:00.0:region3+0x7e00c, 0xabcdabcd,4) failed: Device or resource busy

 

System:

M/B: ASUSTeK COMPUTER INC. ROG MAXIMUS X CODE Version Rev 1.xx - s/n: 171115042001373

BIOS: American Megatrends Inc. Version 1801. Dated: 11/05/2018

CPU: Intel® Core™ i5-8600K CPU @ 3.60GHz

HVM: Enabled

IOMMU: Enabled

Cache: 384 KiB, 1536 KiB, 9216 KiB

Memory: 16 GiB DDR4 (max. installable capacity 64 GiB)

Network: bond0: fault-tolerance (active-backup), mtu 1500
 eth0: 1000 Mbps, full duplex, mtu 1500

Kernel: Linux 4.19.88-Unraid x86_64

OpenSSL: 1.1.1d

 

XML:

<?xml version='1.0' encoding='UTF-8'?>
<domain type='kvm' id='1'>
  <name>Windows 10</name>
  <uuid>c8acce93-3285-84b6-916f-adf98e199256</uuid>
  <metadata>
    <vmtemplate xmlns="unraid" name="Windows 10" icon="windows.png" os="windows10"/>
  </metadata>
  <memory unit='KiB'>4194304</memory>
  <currentMemory unit='KiB'>4194304</currentMemory>
  <memoryBacking>
    <nosharepages/>
  </memoryBacking>
  <vcpu placement='static'>2</vcpu>
  <cputune>
    <vcpupin vcpu='0' cpuset='2'/>
    <vcpupin vcpu='1' cpuset='3'/>
  </cputune>
  <resource>
    <partition>/machine</partition>
  </resource>
  <os>
    <type arch='x86_64' machine='pc-i440fx-4.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/usr/share/qemu/ovmf-x64/OVMF_CODE-pure-efi.fd</loader>
    <nvram>/etc/libvirt/qemu/nvram/c8acce93-3285-84b6-916f-adf98e199256_VARS-pure-efi.fd</nvram>
  </os>
  <features>
    <acpi/>
    <apic/>
    <hyperv>
      <relaxed state='on'/>
      <vapic state='on'/>
      <spinlocks state='on' retries='8191'/>
      <vendor_id state='on' value='none'/>
    </hyperv>
  </features>
  <cpu mode='host-passthrough' check='none'>
    <topology sockets='1' cores='2' threads='1'/>
  </cpu>
  <clock offset='localtime'>
    <timer name='hypervclock' present='yes'/>
    <timer name='hpet' present='no'/>
  </clock>
  <on_poweroff>destroy</on_poweroff>
  <on_reboot>restart</on_reboot>
  <on_crash>restart</on_crash>
  <devices>
    <emulator>/usr/local/sbin/qemu</emulator>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/domains/Windows 10/vdisk1.img'/>
      <backingStore/>
      <target dev='hdc' bus='virtio'/>
      <boot order='1'/>
      <alias name='virtio-disk2'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
    </disk>
    <disk type='file' device='cdrom'>
      <driver name='qemu' type='raw'/>
      <source file='/mnt/user/isos/Windows.iso'/>
      <backingStore/>
      <target dev='hda' bus='ide'/>
      <readonly/>
      <boot order='2'/>
      <alias name='ide0-0-0'/>
      <address type='drive' controller='0' bus='0' target='0' unit='0'/>
    </disk>
    <disk type='file' device='cdrom'>
      <driver name='qemu' type='raw'/>
      <source file='/mnt/user/isos/virtio-win-0.1.160-1.iso'/>
      <backingStore/>
      <target dev='hdb' bus='ide'/>
      <readonly/>
      <alias name='ide0-0-1'/>
      <address type='drive' controller='0' bus='0' target='0' unit='1'/>
    </disk>
    <controller type='pci' index='0' model='pci-root'>
      <alias name='pci.0'/>
    </controller>
    <controller type='ide' index='0'>
      <alias name='ide'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
    </controller>
    <controller type='virtio-serial' index='0'>
      <alias name='virtio-serial0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x03' function='0x0'/>
    </controller>
    <controller type='usb' index='0' model='ich9-ehci1'>
      <alias name='usb'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x7'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci1'>
      <alias name='usb'/>
      <master startport='0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0' multifunction='on'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci2'>
      <alias name='usb'/>
      <master startport='2'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x1'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci3'>
      <alias name='usb'/>
      <master startport='4'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x2'/>
    </controller>
    <interface type='bridge'>
      <mac address='52:54:00:d8:cc:a0'/>
      <source bridge='br0'/>
      <target dev='vnet0'/>
      <model type='virtio'/>
      <alias name='net0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
    </interface>
    <serial type='pty'>
      <source path='/dev/pts/0'/>
      <target type='isa-serial' port='0'>
        <model name='isa-serial'/>
      </target>
      <alias name='serial0'/>
    </serial>
    <console type='pty' tty='/dev/pts/0'>
      <source path='/dev/pts/0'/>
      <target type='serial' port='0'/>
      <alias name='serial0'/>
    </console>
    <channel type='unix'>
      <source mode='bind' path='/var/lib/libvirt/qemu/channel/target/domain-1-Windows 10/org.qemu.guest_agent.0'/>
      <target type='virtio' name='org.qemu.guest_agent.0' state='connected'/>
      <alias name='channel0'/>
      <address type='virtio-serial' controller='0' bus='0' port='1'/>
    </channel>
    <input type='tablet' bus='usb'>
      <alias name='input0'/>
      <address type='usb' bus='0' port='1'/>
    </input>
    <input type='mouse' bus='ps2'>
      <alias name='input1'/>
    </input>
    <input type='keyboard' bus='ps2'>
      <alias name='input2'/>
    </input>
    <sound model='ich9'>
      <alias name='sound0'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x08' function='0x0'/>
    </sound>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
      </source>
      <alias name='hostdev0'/>
      <rom file='/mnt/user/isos/asus1080ti2.dump'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
    </hostdev>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x01' slot='0x00' function='0x1'/>
      </source>
      <alias name='hostdev1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
    </hostdev>
    <hostdev mode='subsystem' type='usb' managed='no'>
      <source>
        <vendor id='0x04d9'/>
        <product id='0x1829'/>
        <address bus='1' device='2'/>
      </source>
      <alias name='hostdev2'/>
      <address type='usb' bus='0' port='2'/>
    </hostdev>
    <hostdev mode='subsystem' type='usb' managed='no'>
      <source>
        <vendor id='0x1532'/>
        <product id='0x0067'/>
        <address bus='1' device='3'/>
      </source>
      <alias name='hostdev3'/>
      <address type='usb' bus='0' port='3'/>
    </hostdev>
    <memballoon model='none'/>
  </devices>
  <seclabel type='dynamic' model='dac' relabel='yes'>
    <label>+0:+100</label>
    <imagelabel>+0:+100</imagelabel>
  </seclabel>
</domain>
 

kraken-diagnostics-20191224-0012.zip

Edited by Amanhem
Different Error
Link to comment

I had this issue and resolved it by uninstalling the Nvidia driver, shutting down the vm, and then only passing through the video only, no audio, from the card. You may have to use acs functions to split your card into separate iommu groups. Upon restart, it works as expected minus GPU sound, but I'm using something else for that anyways so it wasn't a big deal.

 

there may be a better way to resolve this though.

Link to comment
On 12/28/2019 at 4:01 PM, dodgypast said:

Spaceinvaderone has a video addressing this:

 

I have tried to do steps mentioned in this video about multifunction but that does not help, 

 

On 12/29/2019 at 6:45 AM, phat_cow said:

I had to use Machine Type: Q35-4.1

BIOS: OVMF

 

You might need to recreate your VM when changing machine types. 

I also tried making a seperate Windows VM with Q35 and that did not help either

 

On 12/24/2019 at 5:08 PM, 1812 said:

I had this issue and resolved it by uninstalling the Nvidia driver, shutting down the vm, and then only passing through the video only, no audio, from the card. You may have to use acs functions to split your card into separate iommu groups. Upon restart, it works as expected minus GPU sound, but I'm using something else for that anyways so it wasn't a big deal.

 

there may be a better way to resolve this though.

This did not work either. I just dont understand guys, let me know if there is some tech info missing and I will post it

Link to comment
  • 4 months later...

These may not work since I am new to unraid but I did have the error 43 myself, try these:

 

I had to disable Legacy bios or CSM in the motherboard bios then the error 43 went away and my Nvidia card worked fine.

GPU pass through does not work with those it has to be UEFI bios only, also when creating your VM template in unraid do not use seabios since its legacy/csm mode (so wont pass through gpus) it has to be set to OVMF only since that supports UEFI bios and GPU pass through.

 

You should also use your correct gpu bios of your gpu card and make sure it's been edited correctly, otherwise if it's not been edited it won't work either for pass through. Ytube space invader has the vids for that and shows you how to edit the rom file.

 

also this may not help but I did all the above and had a blank screen when my VM started I followed jt rippers instructions here:

and applied a script fix, this allowed my gpu to display and work also.

 

Again not sure if it helps but maybe worth a look.

 

Link to comment
  • JorgeB changed the title to [SOLVED] Windows VM gives me Code 43 Nvidia GPU
  • 1 year later...

Started having the same issue with my 3070 passthrough to Win10 VM after I reflashed my unraid thumbdrive due to corruption.

Tried all the guides I could find online, tired disabling CSM, setting UEFI only, setting bind iommu group to vfio at boot, edited xml.... nothing worked.

Finally decided to shutdown the system, pull the plug, press the power to drain board, unplugged hdmi from 3070, re-attached power, and started system.

I waited until unraid had fully booted, then I started the VM (was set to auto start), then attached the hdmi back to the rtx... BLAM, win10 VM was on screen.

 

I'll update this once I've got a more reliable method, in the meantime I hope this helps someone avoid a headache! ^.^

Edited by freqy
Link to comment

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...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.