Sargie Posted October 19, 2021 Share Posted October 19, 2021 Hello! I have managed to get a Mac OS High Sierra VM running, largely thanks to SpaceInvaderOne's excellent videos and an old thread on this forum. Unfortunately, I cannot get my Sound Card to work. This is a USB device attached to a Hub. The Hub is "isolated" from Unraid and works great on my Windows 10 VM but I cannot get it to work on High Sierra. Any help would be appreciated! Thanks Sarge Quote Link to comment
ghost82 Posted October 20, 2021 Share Posted October 20, 2021 (edited) Hi, how is the usb hub isolated?Are you isolating the usb controller? what brand of audio usb?Is it detected in system profile or it simply doesn't output any sound? Can you post your diagnostics file? Edited October 20, 2021 by ghost82 Quote Link to comment
Sargie Posted October 21, 2021 Author Share Posted October 21, 2021 Hello Ghost82 - thanks for the reply - I really appreciate it. I will do my best to answer. The USB Controller is isolated as IOMMU group 19: [1022:149c] 08:00.3 USB controller: Advanced Micro Devices, Inc. [AMD] Matisse USB 3.0 Host Controller This controller is bound to vfio, connected USB devices are not visible. I have a USB Hub plugged into that controller that the USB Audio Device is plugged into. The USB Audio Device is a Focusrite Scarlett 6i6 first gen. It is not detected in the Mac system profile (or indeed, by the Focusrite drivers). It does, however, work fine on my Windows VM. I have attached the diagnostics file. Many thanks again! Sarge sargienas-diagnostics-20211020-2118.zip Quote Link to comment
ghost82 Posted October 21, 2021 Share Posted October 21, 2021 (edited) 3 hours ago, Sargie said: It is not detected in the Mac system profile (or indeed, by the Focusrite drivers) Does any other usb device is recognized if plugged in the hub (same usb port)? Can you provide a copy of ioreg and a copy of your efi folder? <-- send them in private message as they contain sensible data. So the usb needs a driver (kext)?Are you sure gatekeeper is configured accordingly to allow third party extensions to load? Sidenote (nothing to do with the current issue): put your gpu audio on the same bus and slot as video, change from this: <hostdev mode='subsystem' type='pci' managed='yes'> <driver name='vfio'/> <source> <address domain='0x0000' bus='0x06' slot='0x00' function='0x0'/> </source> <rom file='/mnt/vm/BIOS/Nvidia Geforce 970 - UnraidNAS.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='0x06' slot='0x00' function='0x1'/> </source> <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/> </hostdev> To this: <hostdev mode='subsystem' type='pci' managed='yes'> <driver name='vfio'/> <source> <address domain='0x0000' bus='0x06' slot='0x00' function='0x0'/> </source> <rom file='/mnt/vm/BIOS/Nvidia Geforce 970 - UnraidNAS.rom'/> <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='0x06' slot='0x00' function='0x1'/> </source> <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x1'/> </hostdev> Edited October 21, 2021 by ghost82 Quote Link to comment
Sargie Posted October 21, 2021 Author Share Posted October 21, 2021 Thanks for the reply! I will delve into this when I return to the house but just to get ahead of a few things: Other USB devices are not recognized (which is why I think it's a USB hub issue maybe and not the sound card in itself - it's just I need the sound card to work ). "Drivers" is the wrong word I think. The sound card has a mixer utility that you can use to set what comes out of which channel. etc. This utility does not detect the sound card is attached. I will turn off Gatekeeper but I've used this Soundcard with a real Mac going back 8 years or so and it's always worked just fine. This is probably a dumb question but are the ioreg and efi folder on the Mac or on the Unraid server? I think you mean Mac but I just wanted to double check. Thanks again! Best, Sarge Quote Link to comment
Sargie Posted October 22, 2021 Author Share Posted October 22, 2021 Hey ghost82, I think I have the files you need. I will send them via PM. Please let me know if it's not what you need. I turned off Gatekeeper but this has made no difference. USB devices work (Keyboard) during the Clover boot. I can navigate the Clover screens. However, if I do this and then try to load MacOS the process will hang on the Clover screen. If I leave the keyboard alone, the VM will load. When the VM loaded, the keyboard no longer works. What may also be interesting is that I can see the Apple logo on the screen through the passthrough GPU during the boot process then the screen goes blank and I have to use Screen Sharing to actually login to the VM Mac. I hope this helps. Thank you once again! Best, Sarge Quote Link to comment
ghost82 Posted October 22, 2021 Share Posted October 22, 2021 Thank you, Some questions: 1. Do you really need all that virtual usb controllers in unraid?Do you need virtual usb tablet/usb mouse/usb keyboard or are you using a physical mouse/keyboard? 2. I'm not sure you attached the right efi folder: the config.plist contains near nothing, no kext injected, seems not the right efi to me..how did you obtain that? From your description it could be: 1. lacking of usb mapping ports with power values and/or usb port limit exceeded ---> need the creation of a usb map kext and removal of (some of the) uhci/ehci virtual controllers 2. are you sure your hub has enough power?is it externally powered with an additional power supply? 1 hour ago, Sargie said: USB devices work (Keyboard) during the Clover boot This is expected, but the bootloader has nothing to do with the os, it has integrated its own efi drivers for usb/mouse/keyboard/etc. Quote Link to comment
Sargie Posted October 22, 2021 Author Share Posted October 22, 2021 To try and answer: 1. I don't understand what a "Virtual USB Controller" is completely. 99% of the time I interact with Unraid through the web interface on a another computer. Sometimes, I plug a keyboard into the Unraid Box for diagnostic purposes. Before I learnt how to isolate the USB hub, I used to plug in a keyboard and mouse into directly into the Unraid box for use with Virtual Machines. 2. I loaded the El Capitan VM, mounted the EFI partition, copied the EFI folder to the desktop, Zipped it up and sent it to you. *** 1. How do I do that? 2. Yes. It is powered and works well with other VM's. Thanks again! Best. Sarge Quote Link to comment
ghost82 Posted October 22, 2021 Share Posted October 22, 2021 25 minutes ago, Sargie said: mounted the EFI partition, are you sure that you don't have another efi partition with another clover installed?It doesn't look good what you attached, please carefully check it. Tomorrow I will prepare the kext but I need your clover config.plist to edit and you will need to replace it in the right place! Quote Link to comment
Sargie Posted October 22, 2021 Author Share Posted October 22, 2021 Hey ghost82, Thank you once again! The short answer is "I don't know" - I am new to messing about with EFI partitions Not very helpful I know. I will take another look. Best, Sarge Quote Link to comment
Sargie Posted October 23, 2021 Author Share Posted October 23, 2021 Hey ghost82, I think I figured it out and now have the correct EFI with the plist. I have PM'd it to you. Best. Sarge Quote Link to comment
ghost82 Posted October 23, 2021 Share Posted October 23, 2021 (edited) 5 hours ago, Sargie said: I think I figured it out and now have the correct EFI with the plist. mmmm. no One step back, sorry: 1. in your first post you mention: On 10/20/2021 at 12:57 AM, Sargie said: I have managed to get a Mac OS High Sierra VM running But your ioreg files report OS build 15G22010 which is el capitan, I'm quite sure it's el capitan, not high sierra, but please confirm. About the efi, the file you attached has no kext for el capitan, so I'm quite sure it cannot be that! Let's try to find the efi..Run a terminal in mac os and write: diskutil list and report the output please The correct efi is into clover.qcow2 at /mnt/vm/El Capitan/clover.qcow2 Zip this file and send it to me. You are probably mounting the efi into /mnt/vm/El Capitan/El Capitan.img or into /mnt/vm/El Capitan/vdisk3.img (most probably the second one, the first being the installer disk) Edited October 23, 2021 by ghost82 Quote Link to comment
Sargie Posted October 23, 2021 Author Share Posted October 23, 2021 Gah - you are right - It's El Capitan... I don't know why I did that. What an idiot. Sorry! It has to be El Capitan too as that is the last version of MacOS that supports the software I need to run. Here is the result of the diskutil list. /dev/disk0 (internal, physical): #: TYPE NAME SIZE IDENTIFIER 0: GUID_partition_scheme *268.4 MB disk0 1: EFI EFI 101.4 MB disk0s1 2: Linux Filesystem 163.9 MB disk0s2 /dev/disk1 (internal, physical): #: TYPE NAME SIZE IDENTIFIER 0: GUID_partition_scheme *53.7 GB disk1 1: EFI EFI 209.7 MB disk1s1 2: Apple_HFS Macintosh HD 52.8 GB disk1s2 3: Apple_Boot Recovery HD 650.0 MB disk1s3 /dev/disk2 (internal, physical): #: TYPE NAME SIZE IDENTIFIER 0: GUID_partition_scheme *8.0 GB disk2 1: EFI EFI 209.7 MB disk2s1 2: Apple_HFS Install OS X El Capitan 7.7 GB disk2s2 In my El Capitan VM folder on Unraid there are 3 disk images. I have mounted and looked inside each of the 3 EFI partitions above. Disk0s1 contains an EFI file with a Boot and Clover folder. The Clover Folder contains a config.plist. I assumed this was the correct one. Disk1s1 contains an EFI file with an Apple/Extensions/Firmware.scrap file in it. Disk2s1 contains an EFI file that is empty. On Unraid: El Capitan.img which is the installer image. Clover.qcow2 which is the clover image (I suppose). vdisk3.img which is the "operating system" VM image. I am sending you both EFI folders the clover.qcow2 file. I hope that helps and thanks again for your help and patience! Best, Sarge Quote Link to comment
ghost82 Posted October 24, 2021 Share Posted October 24, 2021 (edited) 15 hours ago, Sargie said: I hope that helps Well..you were right, apparently you are booting without any kext injection: that sounded strange to me, but it's possible and I remember that it was possible. Let's try with something simple, to modify the vm template by removing some of the virtual usb controllers; maybe that you have too many usb ports defined exceeding mac os limits.. 1. copy and paste your current xml somewhere as a backup 2. replace the xml with this: <!-- WARNING: THIS IS AN AUTO-GENERATED FILE. CHANGES TO IT ARE LIKELY TO BE OVERWRITTEN AND LOST. Changes to this xml configuration should be made using: virsh edit f3aa0671-06f6-a8ef-6bb1-76050b958a5a or other application using the libvirt API. --> <domain type='kvm' xmlns:qemu='http://libvirt.org/schemas/domain/qemu/1.0'> <name>El Capitan</name> <uuid>f3aa0671-06f6-a8ef-6bb1-76050b958a5a</uuid> <metadata> <vmtemplate xmlns="unraid" name="Linux" icon="linux.png" os="linux"/> </metadata> <memory unit='KiB'>8388608</memory> <currentMemory unit='KiB'>8388608</currentMemory> <memoryBacking> <nosharepages/> </memoryBacking> <vcpu placement='static'>8</vcpu> <cputune> <vcpupin vcpu='0' cpuset='4'/> <vcpupin vcpu='1' cpuset='12'/> <vcpupin vcpu='2' cpuset='5'/> <vcpupin vcpu='3' cpuset='13'/> <vcpupin vcpu='4' cpuset='6'/> <vcpupin vcpu='5' cpuset='14'/> <vcpupin vcpu='6' cpuset='7'/> <vcpupin vcpu='7' cpuset='15'/> </cputune> <os> <type arch='x86_64' machine='pc-q35-5.1'>hvm</type> <loader readonly='yes' type='pflash'>/usr/share/qemu/ovmf-x64/OVMF_CODE-pure-efi.fd</loader> <nvram>/etc/libvirt/qemu/nvram/f3aa0671-06f6-a8ef-6bb1-76050b958a5a_VARS-pure-efi.fd</nvram> </os> <features> <acpi/> <apic/> </features> <cpu mode='host-passthrough' check='none' migratable='on'> <topology sockets='1' dies='1' cores='4' 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/vm/El Capitan/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/vm/El Capitan/El Capitan.img'/> <target dev='hdd' bus='sata'/> <boot order='2'/> <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/vm/El Capitan/vdisk3.img'/> <target dev='hde' bus='sata'/> <boot order='3'/> <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='0x1'/> </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='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='0xa'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' 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='pci' index='5' model='pcie-root-port'> <model name='pcie-root-port'/> <target chassis='5' port='0xb'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x01' 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:cc:37:24'/> <source bridge='br0'/> <model type='vmxnet3'/> <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='mouse' bus='ps2'/> <input type='keyboard' bus='ps2'/> <hostdev mode='subsystem' type='pci' managed='yes'> <driver name='vfio'/> <source> <address domain='0x0000' bus='0x06' slot='0x00' function='0x0'/> </source> <rom file='/mnt/vm/BIOS/Nvidia Geforce 970 - UnraidNAS.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='0x06' slot='0x00' function='0x1'/> </source> <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x0'/> </hostdev> <hostdev mode='subsystem' type='pci' managed='yes'> <driver name='vfio'/> <source> <address domain='0x0000' bus='0x08' slot='0x00' function='0x3'/> </source> <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/> </hostdev> <memballoon model='none'/> </devices> <qemu:commandline> <qemu:arg value='-device'/> REPLACE HERE <qemu:arg value='-smbios'/> <qemu:arg value='type=2'/> <qemu:arg value='-cpu'/> <qemu:arg value='Penryn,vendor=GenuineIntel,kvm=on,+invtsc,+avx,+avx2,+aes,+xsave,+xsaveopt,vmware-cpuid-freq=on,'/> </qemu:commandline> </domain> At the end of the xml you see "REPLACE HERE": delete this line and paste this (highlighted in yellow): https://github.com/SpaceinvaderOne/Macinabox/blob/master/xml/Macinabox BigSur.xml#L139 Save and start the vm. Test the vm, if remote mouse and keyboard work. If it works, try this with ioregistry explorer opened: 1. disconnect your hub 2. in ioreg find pci1022,149c: 3. plug a usb 2 device into the usb port in which the hub was connected and see if something gets detected (something in green should appear in ioreg) 4. plug a usb 3 device into the usb port in which the hub was connected and see if something gets detected (something in green should appear in ioreg) 5. if these tests are successful, plug the hub to that port 6. plug a usb 2 device into the hub and see if something gets detected (something in green should appear in ioreg) 7. plug a usb 3 device into the hub and see if something gets detected (something in green should appear in ioreg) Another test you can try: plug a usb 2 device into the hub, start the vm with the device plugged in, does it get detected in ioreg? If usb still doesn't work, but remote mouse and keyboard work, attach a new copy of ioreg. Edited October 24, 2021 by ghost82 Quote Link to comment
Sargie Posted October 25, 2021 Author Share Posted October 25, 2021 Thanks ghost82! I will text this as soon as I can. It looks like my HD controller card died in my server so I’m having to get a new one… Epic bad timing. I’ll let you know how it goes ASAP. Best, sarge 1 Quote Link to comment
Sargie Posted October 27, 2021 Author Share Posted October 27, 2021 New card should be here in a day or so - assuming that fixes the problem I can test this weekend! Wanted to give an update because I am incredibly grateful for your help and feel bad I can't implement your solution immediately. 1 Quote Link to comment
Sargie Posted October 29, 2021 Author Share Posted October 29, 2021 OK! I am back up and running. VM is loading with your XML. I can VNC in using Screen Sharing and use keyboard and mouse. I do not see the USB ports using ioreg. Nothing happens when I plug in a USB 2 or USB 3 device. I am sending you a new ioreg. Best, Sarge Quote Link to comment
Sargie Posted November 12, 2021 Author Share Posted November 12, 2021 Just wanted to say thank-you! I bought the USB interface you recommended and this now works like a charm! Thanks again! 1 Quote Link to comment
Recommended Posts
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.