[Support] SpaceinvaderOne - Macinabox


Recommended Posts

3 minutes ago, RockDawg said:

Well at least I know what the problem is and I have a compatible video card from a Hackintosh sytem I had a couple years back.  Time to watch SpaceInvaders video on how to passthrough.

What are compatible GPUs for Catalina? My Nvidia 1050 still not supported, right?

Link to comment

In regards to the CPU, are you sure about AVXas a necessity to run macOS? I’ve read quite often that AVX is necessary (somewhere else, not on this forum), not the newer version. I’m gonna try this out myself soon and will report back, I just thought I might ask first. Still waiting for my motherboard to run a Xeon E5 on, which only support AVX but not AVX2. 

It also looks to me in the XML as if you were only passing the AVX instructions set anyway, not AVX2? I have to admit I haven’t checked the original XML yet, but all of the ones I could find in this topic seem to pass AVX only.

Edited by aureus
Link to comment
1 hour ago, RockDawg said:

I guess I'll have to get a dummy plug and try a dedicated video card I guess. One question though... what is it about MacOS that requires the dedicated video card.? I have a win10 VM that runs just fine without one.  

it isn't intended to be virtualized, so it assumes it is running on hardware and some sort of hardware GPU is present, either card/soldered or graphics via cpu. Yes, you can run it in VMware officially from apple, but it's not really built to do that in the same manner as windows.

Link to comment

Hi all 

i wonder if i could tap in to the great minds on the forum. I have a stable running Catalina VM, however i can not get my 5700xt working. I wonder if i have missed something in the XML script below

 

<?xml version='1.0' encoding='UTF-8'?>
<domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'>
  <name>MacinaboxCatalina</name>
  <uuid></uuid>
  <description>MacOS Catalina</description>
  <metadata>
    <vmtemplate xmlns="unraid" name="Windows 10" icon="default.png" os="Catalina"/>
  </metadata>
  <memory unit='KiB'>16777216</memory>
  <currentMemory unit='KiB'>8388608</currentMemory>
  <memoryBacking>
    <nosharepages/>
  </memoryBacking>
  <vcpu placement='static'>16</vcpu>
  <cputune>
    <vcpupin vcpu='0' cpuset='3'/>
    <vcpupin vcpu='1' cpuset='27'/>
    <vcpupin vcpu='2' cpuset='5'/>
    <vcpupin vcpu='3' cpuset='29'/>
    <vcpupin vcpu='4' cpuset='7'/>
    <vcpupin vcpu='5' cpuset='31'/>
    <vcpupin vcpu='6' cpuset='9'/>
    <vcpupin vcpu='7' cpuset='33'/>
    <vcpupin vcpu='8' cpuset='11'/>
    <vcpupin vcpu='9' cpuset='35'/>
    <vcpupin vcpu='10' cpuset='13'/>
    <vcpupin vcpu='11' cpuset='37'/>
    <vcpupin vcpu='12' cpuset='15'/>
    <vcpupin vcpu='13' cpuset='39'/>
    <vcpupin vcpu='14' cpuset='17'/>
    <vcpupin vcpu='15' cpuset='41'/>
  </cputune>
  <os>
    <type arch='x86_64' machine='pc-q35-3.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_CODE.fd</loader>
    <nvram>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_VARS.fd</nvram>
  </os>
  <features>
    <acpi/>
    <apic/>
  </features>
  <cpu mode='host-passthrough' check='none'>
    <topology sockets='1' cores='8' threads='2'/>
    <cache mode='passthrough'/>
    <feature policy='require' name='topoext'/>
  </cpu>
  <clock offset='utc'>
    <timer name='rtc' tickpolicy='catchup'/>
    <timer name='pit' tickpolicy='delay'/>
    <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='qcow2' cache='writeback'/>
      <source file='/mnt/user/domains/MacinaboxCatalina/Clover.qcow2'/>
      <target dev='hdc' bus='sata'/>
      <boot order='1'/>
      <address type='drive' controller='0' bus='0' target='0' unit='2'/>
    </disk>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/domains/MacinaboxCatalina/Catalina-install.img'/>
      <target dev='hdd' bus='sata'/>
      <address type='drive' controller='0' bus='0' target='0' unit='3'/>
    </disk>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/domains/MacinaboxCatalina/macos_disk.img'/>
      <target dev='hde' bus='sata'/>
      <address type='drive' controller='0' bus='0' target='0' unit='4'/>
    </disk>
    <controller type='usb' index='0' model='ich9-ehci1'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x7'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci1'>
      <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'>
      <master startport='2'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x1' multifunction='on'/>
    </controller>
    <controller type='usb' index='0' model='ich9-uhci3'>
      <master startport='4'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x2'/>
    </controller>
    <controller type='pci' index='0' model='pcie-root'/>
    <controller type='pci' index='1' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='1' port='0x8'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x0' multifunction='on'/>
    </controller>
    <controller type='pci' index='2' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='2' port='0x9'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
    </controller>
    <controller type='pci' index='3' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='3' port='0x12'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x2'/>
    </controller>
    <controller type='pci' index='4' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='4' port='0x13'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x3'/>
    </controller>
    <controller type='virtio-serial' index='0'>
      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
    </controller>
    <controller type='sata' index='0'>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
    </controller>
    <interface type='bridge'>
      <mac address='52:54:00:42:5e:c1'/>
      <source bridge='br0'/>
      <model type='e1000-82545em'/>
      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
    </interface>
    <serial type='pty'>
      <target type='isa-serial' port='0'>
        <model name='isa-serial'/>
      </target>
    </serial>
    <console type='pty'>
      <target type='serial' port='0'/>
    </console>
    <channel type='unix'>
      <target type='virtio' name='org.qemu.guest_agent.0'/>
      <address type='virtio-serial' controller='0' bus='0' port='1'/>
    </channel>
    <input type='tablet' bus='usb'>
      <address type='usb' bus='0' port='1'/>
    </input>
    <input type='mouse' bus='ps2'/>
    <input type='keyboard' bus='ps2'/>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x45' slot='0x00' function='0x0'/>
      </source>
      <rom file='/mnt/user/domains/Vbios/Sapphire.RX5700XT.8192.190905_2.rom'/>
      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
    </hostdev>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x45' slot='0x00' function='0x1'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/>
    </hostdev>
    <memballoon model='none'/>
  </devices>
  <qemu:commandline>
    <qemu:arg value='-usb'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='usb-kbd,bus=usb-bus.0'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='************************'/>
    <qemu:arg value='-smbios'/>
    <qemu:arg value='type=2'/>
    <qemu:arg value='-cpu'/>
    <qemu:arg value='Penryn,kvm=on,vendor=GenuineIntel,+invtsc,vmware-cpuid-freq=on,+pcid,+ssse3,+sse4.2,+popcnt,+avx,+aes,+xsave,+xsaveopt,check'/>
  </qemu:commandline>
</domain>
 

Maybe its something very simple i have overlooked

Any help would be appreciated 

 

 

Just to add this is the log 

 

blockdev '{"driver":"file","filename":"/mnt/user/domains/MacinaboxCatalina/macos_disk.img","node-name":"libvirt-1-storage","cache":{"direct":false,"no-flush":false},"auto-read-only":true,"discard":"unmap"}' \
-blockdev '{"node-name":"libvirt-1-format","read-only":false,"cache":{"direct":false,"no-flush":false},"driver":"raw","file":"libvirt-1-storage"}' \
-device ide-hd,bus=ide.4,drive=libvirt-1-format,id=sata0-0-4,write-cache=on \
-netdev tap,fd=37,id=hostnet0 \
-device e1000-82545em,netdev=hostnet0,id=net0,mac=52:54:00:42:5e:c1,bus=pci.1,addr=0x0 \
-chardev pty,id=charserial0 \
-device isa-serial,chardev=charserial0,id=serial0 \
-chardev socket,id=charchannel0,fd=38,server,nowait \
-device virtserialport,bus=virtio-serial0.0,nr=1,chardev=charchannel0,id=channel0,name=org.qemu.guest_agent.0 \
-device usb-tablet,id=input0,bus=usb.0,port=1 \
-device vfio-pci,host=0000:45:00.0,id=hostdev0,bus=pci.3,addr=0x0,romfile=/mnt/user/domains/Vbios/Sapphire.RX5700XT.8192.190905_2.rom \
-device vfio-pci,host=0000:45:00.1,id=hostdev1,bus=pci.4,addr=0x0 \
-usb \
-device usb-kbd,bus=usb-bus.0 \
-device '************************' \
-smbios type=2 \
-cpu Penryn,kvm=on,vendor=GenuineIntel,+invtsc,vmware-cpuid-freq=on,+pcid,+ssse3,+sse4.2,+popcnt,+avx,+aes,+xsave,+xsaveopt,check \
-sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
-msg timestamp=on
2020-06-06 18:03:20.713+0000: Domain id=14 is tainted: high-privileges
2020-06-06 18:03:20.713+0000: Domain id=14 is tainted: custom-argv
2020-06-06 18:03:20.714+0000: Domain id=14 is tainted: host-cpu
char device redirected to /dev/pts/1 (label charserial0)
2020-06-06T18:03:20.774032Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.776743Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.777980Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.779457Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.780812Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.782475Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.783778Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.785099Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.786555Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.788010Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.789497Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.791044Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.792473Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.793765Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.795058Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:20.796380Z qemu-system-x86_64: warning: host doesn't support requested feature: CPUID.01H:ECX.pcid [bit 17]
2020-06-06T18:03:23.679237Z qemu-system-x86_64: -device vfio-pci,host=0000:45:00.0,id=hostdev0,bus=pci.3,addr=0x0,romfile=/mnt/cache/domains/Vbios/Sapphire.RX5700XT.8192.190905_2.rom: Failed to mmap 0000:45:00.0 BAR 0. Performance may be slow

Edited by grizzle
Link to comment

So I'm an idiot, and forgot to delete the container after utilizing it.  It was fine for a couple of months, and then somehow it started and ran again (just prior to the update to fix this issue) and overwrote my disks.  Now the thing is, I edited the xml to install everything on an nvme drive I have...

 

So my question is, how do I get it to boot off the proper drive, rather than the newly created drive?

 

~Spritz

 

EDIT - I may have resolved it by removing the install disk that is created, and simply leaving the clover image and then the physical disk.  Anything wrong with my solution?

Edited by Spritzup
Fixed it?
Link to comment

Hi,

I installed the VM as described, however, on first run I get an error saying "Execution error, Cannot get interface MTU on 'virbr0': No such device".

 

In another Win 10 VM, I also have virbr0 as networking card.

 

Any idea what I can do?

 

 

Link to comment
1 hour ago, kana said:

Hi,

I installed the VM as described, however, on first run I get an error saying "Execution error, Cannot get interface MTU on 'virbr0': No such device".

 

In another Win 10 VM, I also have virbr0 as networking card.

 

Any idea what I can do?

 

 

Ok, this one solved itself after I had restarted Unraid.

But now the VM is stuck and just shows the Apple logo when I VNC it. I can't stop it either, when I choose the menu entry, I get the green wheel, after a few seconds the green triangle, all the time saying "started".

Link to comment

Blank screen, booting from GPU

Along with many others, it appears I am having the same issue. 

I have been able to successfully install and run the Catalina VM through VNC, but now I am trying to setup the GPU passthrough and getting just a black screen when it boots.

I have removed the topolgy line from the XML, changed the network access, and made sure to reinsert the script at the bottom of the XML per @SpaceInvaderOne video.
Looking through the forum I can't seem to find any solution that has worked for anyone else, but perhaps I have just overlooked something?

CatalinaXML.txt

Link to comment
On 5/18/2020 at 1:23 PM, Abz said:

Thanks, got to the next screen which said press enter to boot. Pressed enter and now on the following screen. Been a few minutes and 1 core of the cpu is pegged at 100% but nothings happened so far. How long should it normally take this part or is it frozen?

 

Thanks again, quite new to unraid (just built the server last week) :D

 

 

Capture3.PNG

I am unable to get pass  this issue - a black screen after clover boot screen using vnc - with mojave.

I've checked everything and I can't find what the issue might be.

Also,  do we know for certain nvidia cards will not work with mojave. 

Link to comment
On 6/10/2020 at 2:15 PM, braydination said:

Blank screen, booting from GPU

Along with many others, it appears I am having the same issue. 

I have been able to successfully install and run the Catalina VM through VNC, but now I am trying to setup the GPU passthrough and getting just a black screen when it boots.

I have removed the topolgy line from the XML, changed the network access, and made sure to reinsert the script at the bottom of the XML per @SpaceInvaderOne video.
Looking through the forum I can't seem to find any solution that has worked for anyone else, but perhaps I have just overlooked something?

CatalinaXML.txt 6.97 kB · 3 downloads

Same for me, if you have any solution I'll glad to hear.

Link to comment
On 6/10/2020 at 9:15 PM, braydination said:

Blank screen, booting from GPU

Along with many others, it appears I am having the same issue. 

I have been able to successfully install and run the Catalina VM through VNC, but now I am trying to setup the GPU passthrough and getting just a black screen when it boots.

I have removed the topolgy line from the XML, changed the network access, and made sure to reinsert the script at the bottom of the XML per @SpaceInvaderOne video.
Looking through the forum I can't seem to find any solution that has worked for anyone else, but perhaps I have just overlooked something?

CatalinaXML.txt 6.97 kB · 4 downloads

So when ever you mess with your XML you need to make sure the following are correct/repaired;
- CPU topology
- Network card
- Reinsert <qemu:commandline> XML at the botom
- Update the <OS> section with the custom <loader> and <nvram> (not mentioned in the @SpaceInvaderOne video)
- Add the multifunction tag to the video card and change the function id to 0x1 for the audio component
 

I've only had a 5 second look at your XML but I think you missed the last two. The <OS> changes are needed to avoid a blank screen. Turning multifunction on will prevent video driver and video card audio problems. I've had great success with passing through an RX550 (video and HDMI audio) without any custom changes in Clover.

One thing I would say is that Clover is quite brittle and requires the custom Macinabox ovmf loader and nvram to work. I plan on moving to OpenCore as some point to improve reliability and allow use of the latest q35 machines but that's a project for another day.

  <os>
    <type arch='x86_64' machine='pc-q35-3.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_CODE.fd</loader>
    <nvram>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_VARS.fd</nvram>
  </os>
...
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x0f' slot='0x00' function='0x0'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0' multifunction='on'/>
    </hostdev>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x0f' slot='0x00' function='0x1'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x1'/>
    </hostdev>

 

Edited by cat2devnull
Link to comment
10 hours ago, cat2devnull said:

So when ever you mess with your XML you need to make sure the following are correct/repaired;
- CPU topology
- Network card
- Reinsert <qemu:commandline> XML at the botom
- Update the <OS> section with the custom <loader> and <nvram> (not mentioned in the @SpaceInvaderOne video)
- Add the multifunction tag to the video card and change the function id to 0x1 for the audio component
 

I've only had a 5 second look at your XML but I think you missed the last two. The <OS> changes are needed to avoid a blank screen. Turning multifunction on will prevent video driver and video card audio problems. I've had great success with passing through an RX550 (video and HDMI audio) without any custom changes in Clover.

One thing I would say is that Clover is quite brittle and requires the custom Macinabox ovmf loader and nvram to work. I plan on moving to OpenCore as some point to improve reliability and allow use of the latest q35 machines but that's a project for another day.


  <os>
    <type arch='x86_64' machine='pc-q35-3.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_CODE.fd</loader>
    <nvram>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_VARS.fd</nvram>
  </os>
...
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x0f' slot='0x00' function='0x0'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0' multifunction='on'/>
    </hostdev>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x0f' slot='0x00' function='0x1'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x1'/>
    </hostdev>

 

hi there i have a similar problem passing through a 5700xt the VM boots but in the logs i get the following errors below

 

-msg timestamp=on
2020-06-13 10:30:10.873+0000: Domain id=4 is tainted: high-privileges
2020-06-13 10:30:10.873+0000: Domain id=4 is tainted: custom-argv
2020-06-13 10:30:10.873+0000: Domain id=4 is tainted: host-cpu
char device redirected to /dev/pts/0 (label charserial0)
2020-06-13T10:30:16.387348Z qemu-system-x86_64: -device vfio-pci,host=0000:45:00.0,id=hostdev0,bus=pci.3,multifunction=on,addr=0x0: Failed to mmap 0000:45:00.0 BAR 0. Performance may be slow

 

I have been trying for days now and i am sure i have just over looked something in the XML 

 

my xml is as follows 

 

<description>MacOS Catalina</description>
  <metadata>
    <vmtemplate xmlns="unraid" name="Windows 10" icon="default.png" os="Catalina"/>
  </metadata>
  <memory unit='KiB'>8388608</memory>
  <currentMemory unit='KiB'>8388608</currentMemory>
  <memoryBacking>
    <nosharepages/>
  </memoryBacking>
  <vcpu placement='static'>16</vcpu>
  <cputune>
    <vcpupin vcpu='0' cpuset='10'/>
    <vcpupin vcpu='1' cpuset='34'/>
    <vcpupin vcpu='2' cpuset='11'/>
    <vcpupin vcpu='3' cpuset='35'/>
    <vcpupin vcpu='4' cpuset='12'/>
    <vcpupin vcpu='5' cpuset='36'/>
    <vcpupin vcpu='6' cpuset='13'/>
    <vcpupin vcpu='7' cpuset='37'/>
    <vcpupin vcpu='8' cpuset='14'/>
    <vcpupin vcpu='9' cpuset='38'/>
    <vcpupin vcpu='10' cpuset='15'/>
    <vcpupin vcpu='11' cpuset='39'/>
    <vcpupin vcpu='12' cpuset='16'/>
    <vcpupin vcpu='13' cpuset='40'/>
    <vcpupin vcpu='14' cpuset='17'/>
    <vcpupin vcpu='15' cpuset='41'/>
  </cputune>
  <resource>
    <partition>/machine</partition>
  </resource>
  <os>
    <type arch='x86_64' machine='pc-q35-3.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/usr/share/qemu/ovmf-x64/OVMF_CODE-pure-efi.fd</loader>
    <nvram>/etc/libvirt/qemu/nvram/3143a24c-7dcf-4c5a-a334-be6fff6c6226_VARS-pure-efi.fd</nvram>
  </os>
  <features>
    <acpi/>
    <apic/>
  </features>
  <cpu mode='host-passthrough' check='none'>
    <topology sockets='1' cores='8' threads='2'/>
    <cache mode='passthrough'/>
    <feature policy='require' name='topoext'/>
  </cpu>
  <clock offset='utc'>
    <timer name='rtc' tickpolicy='catchup'/>
    <timer name='pit' tickpolicy='delay'/>
    <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='qcow2' cache='writeback'/>
      <source file='/mnt/user/domains/MacinaboxCatalina/Clover.qcow2' index='3'/>
      <backingStore/>
      <target dev='hdc' bus='sata'/>
      <boot order='1'/>
      <alias name='sata0-0-2'/>
      <address type='drive' controller='0' bus='0' target='0' unit='2'/>
    </disk>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/domains/MacinaboxCatalina/Catalina-install.img' index='2'/>
      <backingStore/>
      <target dev='hdd' bus='sata'/>
      <alias name='sata0-0-3'/>
      <address type='drive' controller='0' bus='0' target='0' unit='3'/>
    </disk>
    <disk type='file' device='disk'>
      <driver name='qemu' type='raw' cache='writeback'/>
      <source file='/mnt/user/domains/MacinaboxCatalina/macos_disk.img' index='1'/>
      <backingStore/>
      <target dev='hde' bus='sata'/>
      <alias name='sata0-0-4'/>
      <address type='drive' controller='0' bus='0' target='0' unit='4'/>
    </disk>
    <controller type='pci' index='0' model='pcie-root'>
      <alias name='pcie.0'/>
    </controller>
    <controller type='pci' index='1' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='1' port='0x10'/>
      <alias name='pci.1'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0' multifunction='on'/>
    </controller>
    <controller type='pci' index='2' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='2' port='0x11'/>
      <alias name='pci.2'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x1'/>
    </controller>
    <controller type='pci' index='3' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='3' port='0x12'/>
      <alias name='pci.3'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x2'/>
    </controller>
    <controller type='pci' index='4' model='pcie-root-port'>
      <model name='pcie-root-port'/>
      <target chassis='4' port='0x13'/>
      <alias name='pci.4'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x3'/>
    </controller>
    <controller type='virtio-serial' index='0'>
      <alias name='virtio-serial0'/>
      <address type='pci' domain='0x0000' bus='0x02' slot='0x00' function='0x0'/>
    </controller>
    <controller type='sata' index='0'>
      <alias name='ide'/>
      <address type='pci' domain='0x0000' bus='0x00' slot='0x1f' function='0x2'/>
    </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:b0:43:ad'/>
      <source bridge='br0'/>
      <target dev='vnet0'/>
      <model type='e1000-82545em'/>
      <alias name='net0'/>
      <address type='pci' domain='0x0000' bus='0x01' slot='0x00' 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-4-MacinaboxCatalina/org.qemu.guest_agent.0'/>
      <target type='virtio' name='org.qemu.guest_agent.0' state='disconnected'/>
      <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>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x45' slot='0x00' function='0x0'/>
      </source>
      <alias name='hostdev0'/>
      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0' multifunction='on'/>
    </hostdev>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x45' slot='0x00' function='0x1'/>
      </source>
      <alias name='hostdev1'/>
      <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x1'/>
    </hostdev>
    <memballoon model='none'/>
  </devices>
  <seclabel type='dynamic' model='dac' relabel='yes'>
    <label>+0:+100</label>
    <imagelabel>+0:+100</imagelabel>
  </seclabel>
  <qemu:commandline>
    <qemu:arg value='-usb'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='usb-kbd,bus=usb-bus.0'/>
    <qemu:arg value='-device'/>
    <qemu:arg value='************************'/>
    <qemu:arg value='-smbios'/>
    <qemu:arg value='type=2'/>
    <qemu:arg value='-cpu'/>
    <qemu:arg value='Penryn,kvm=on,vendor=GenuineIntel,+invtsc,vmware-cpuid-freq=on,+ssse3,+sse4.2,+popcnt,+avx,+aes,+xsave,+xsaveopt,check'/>
  </qemu:commandline>
</domain>
 

Link to comment

@steveBBB, domain is tainted error can be safely ignored. I just means you're running a configuration or some component that is not officially supported by the maintainers of either KVM or QEMU. That means that if you ever need to contact them to report a bug or get help, you would need to adjust your configuration such that it is purely running their supported code and not "tainted" or they will not try to fix it, because they don't support that use case or component added.

Link to comment
12 hours ago, cat2devnull said:

So when ever you mess with your XML you need to make sure the following are correct/repaired;
- CPU topology
- Network card
- Reinsert <qemu:commandline> XML at the botom
- Update the <OS> section with the custom <loader> and <nvram> (not mentioned in the @SpaceInvaderOne video)
- Add the multifunction tag to the video card and change the function id to 0x1 for the audio component
 

I've only had a 5 second look at your XML but I think you missed the last two. The <OS> changes are needed to avoid a blank screen. Turning multifunction on will prevent video driver and video card audio problems. I've had great success with passing through an RX550 (video and HDMI audio) without any custom changes in Clover.

One thing I would say is that Clover is quite brittle and requires the custom Macinabox ovmf loader and nvram to work. I plan on moving to OpenCore as some point to improve reliability and allow use of the latest q35 machines but that's a project for another day.


  <os>
    <type arch='x86_64' machine='pc-q35-3.1'>hvm</type>
    <loader readonly='yes' type='pflash'>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_CODE.fd</loader>
    <nvram>/mnt/user/domains/MacinaboxCatalina/ovmf/OVMF_VARS.fd</nvram>
  </os>
...
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x0f' slot='0x00' function='0x0'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0' multifunction='on'/>
    </hostdev>
    <hostdev mode='subsystem' type='pci' managed='yes'>
      <driver name='vfio'/>
      <source>
        <address domain='0x0000' bus='0x0f' slot='0x00' function='0x1'/>
      </source>
      <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x1'/>
    </hostdev>

 

Thanks for the advice, I tried adding both, but I'm still having no luck. There's no errors whatsoever, but the screen still just won't load...

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.