Jump to content

JKunraid

Members
  • Posts

    51
  • Joined

  • Last visited

Posts posted by JKunraid

  1. 10 hours ago, JorgeB said:

    First you can try redoing the flash drive, if you managed to backup that one, recreate it and see if it boots with the stock config, if yes, restore the /config folder from the backup.

    I created a new USB key using the Unraid software utility. The system boots but of course the drive mappings and everything else isn't configured or a valid license.. Are you saying this can all be fixed by simply overwriting the /config folder on the new USB by copying over the /config folder on the old USB key?

  2. Unraid server stopped booting after a cold restart. When looking at the boot sequence locally it does see the Unraid USB key but gets stuck during boot process (tried with GUI, without, and safe mode). I pulled out the USB key and put it in an Ubuntu machine to run a checkdisk using the built-in Disk app.  It did flag a dirty bit. I ran the repair and it seemed to work but when I try to boot with it I once again get stuck during the boot process.

     

    I have a flash key config backup but it's out of date and I've updated the array with additional drives and done other changes  since the old backup. Fortunately, I was able to copy all the files of the USB key to another computer. What would be the steps to recover to another USB key using the files from the old key?

     

     

  3. I have a bunch of HDDs in a Netapp disk shelf. I'd like to passthrough one of them to a PopOS VM. I can see them in unassigned disk devices (able to mount and unmount it). I was able to passthrough a GPU and a couple of M.2 SSD drives by binding them in Unraid's system devices but I don't see this particular HDD in the list. How would I do the passthrough? 

  4. 49 minutes ago, SimonF said:

    The pci devices will in hostdev sections the source will match the pci id i.e. bus=43 slot=00 feature=0

     

    Do you specify a boot order for the boot device in the form view?

     

    post xml.

     

    UPDATE: 


    I did of search of devices with bus 43 (and 44) as you suggested using the broken XML.  As the XML was nested I assumed the parent lines of XML were also required.  I added these lines to working XML config just above the <memballon model='none'/> line. It booted and showed the two drives. I need to spend a bit of time making sure I haven't broken anything but as it stands it seems to be working.. I'll update as soon as I know for sure.

     

      <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x43' slot='0x00' function='0x0'/>
          </source>
          <address type='pci' domain='0x0000' bus='0x07' slot='0x00' function='0x0'/>
        </hostdev>
        <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x44' slot='0x00' function='0x0'/>
          </source>
          <address type='pci' domain='0x0000' bus='0x08' slot='0x00' function='0x0'/>
        </hostdev>

  5. 33 minutes ago, SimonF said:

    The pci devices will in hostdev sections the source will match the pci id i.e. bus=43 slot=00 feature=0

     

    Do you specify a boot order for the boot device in the form view?

     

    post xml.

     

    Yes. A virtio vdisk is set to "1" on boot field. It has a working OS.  The m.2 drives are for secondary drives not operating system... I have nearly the same setup on the simpler VM and i have no issue using the form view to add them in. It's the manually modified xml VM that has the issue.  I could start from scratch again but I took hours to get the VM working for my particular configuration. It would be a lot simpler if I could add the lines into the xml manually.

     


     

     

     

     

  6. 15 hours ago, SimonF said:

    You can manually add path /dev/disk/by-id/usb-SanDisk_Cruzer_Blade_x-00: to the drive in the GUI or bind the drive to vfio and then you can add as a PCI device in the template. 

    image.png

     

     

    Thanks again for reply Simon. Not following you though.

     

    I've already done the vfio bind in system devices and confirmed I can add the m.2 drives to another basic VM using Unraids VM template GUI. That VM boots fine and adds the drives. The issue is if I use the VM template tool in form view to add the m.2 drives to another VM that has a manually modified XML config template. My second VM boots fine. When I use to VM template form view to modify the config (rather than the config directly using the "xml text" toggle) it messes up my manually modified XML config. The system won't boot then.

     

    In other words, what I'm trying to figure out is what text lines do I need to add to my VM's XML configuration to get the two m.2 drives to do the passthrough? (i.e. rather than using the form view)

     

     

    (Edit:" The devices below are available as an option in the VM's form view but if I check the boxes and click update the VM doesn't boot. I have to repaste a backup of the xml config to get it to boot again)

     

    Other PCI Devices:

            AMD RAID Bottom Device | Non-Volatile memory controller (43:00.0)
            AMD RAID Bottom Device | Non-Volatile memory controller (44:00.0)

  7. I want to passthrough a couple of M.2 SSDs. I am able to do the passthrough with a simple Linux VM configuration using the UI (confirmed with testing). When I try to do the passthrough to another Linux VM though, one that has some manual modifications done to its XML configuration file, it messes up the XML configuration and VM won't boot. 

     

    I've seen this Unraid bug before where if you switch back to UI mode and save after manually modifying VM's XML config it can mess it up. So I backed it up and was able to recover but I'm stuck as to how to add the passthrough for the m.2s manually to my xml file.

     

  8. 1 hour ago, SimonF said:

    To mount the partition add a line in the fstab with the source name and the directory you want to mount it. In this example we mount the directory exported from /home/shared, that will be called home_shared. It will be mounted in the path /mnt/shared inside the virtual machine.

     

    This line in the file 

    home_shared /mnt/shared virtiofs rw,relatime 0 0

     

    Got it. Thanks again.

  9. On 4/15/2024 at 2:20 AM, SimonF said:

    You have to create a mount point in the vm and then mount it.

     

    i.e.

    mkdir /mnt/vmShare

    mount -t virtiofs vmShare /mnt/vmShare

     

    I just realized I  have one more related question. How would I keep the connection to share persistent across reboots?

  10. Setup following virtiofs settings when I created a PopOS VM (settings selected from dropdown).

     

    Unraid Share Mode:  Virtiofs Mode  

    Unraid Share:  user: vmShare  

    Unraid Source Path:  /mnt/user/vmShare

    Unraid Mount Tag: vmShare

     

    The VM boots fine but I can't see the share named  "vmShare". either in locations, VM's mnt folder, or using Disks utility. Is there some step I'm missing or is there a problem?

  11. Unraid Share Mode:  Virtiofs Mode  

    Unraid Share:  user: vmShare  

    Unraid Source Path:  /mnt/user/vmShare

    Unraid Mount Tag: vmShare

  12. On 4/11/2024 at 12:13 AM, bmartino1 said:


    found my notes for the grub otion.

     

     

    pcie_acs_override=downstream,multifunction vfio_iommu_type1.allow_unsafe_interrupts=1


    your 
    Label GPU passthrough mode
      menu default
      kernel /bzimage
      append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off pcie_acs_override=downstream,multifunction options vfio_iommu_type1 allow_unsafe_interrupts=1

    so add the vfio_iommu_type1.allow_unsafe_interrupts=1. test adding all three iommu options as well. 

    amd_iommu=on iommu=pt intel_iommu=on

    so
     

    Label GPU passthrough mode
      menu default
      kernel /bzimage
      append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off pcie_acs_override=downstream,multifunction options vfio_iommu_type1 allow_unsafe_interrupts=1 vfio_iommu_type1.allow_unsafe_interrupts=1 amd_iommu=on iommu=pt intel_iommu=on

     

     

     

    Success!

     

    My existing Ubuntu VM still doesn't see it. And I tried with multiple new templates of Ubuntu but I tried with your suggested PopOS VM and it recognizes the GPU. Thanks so much for the help. 

     

    • Like 1
  13. On 4/6/2024 at 6:56 PM, bmartino1 said:

    the last thing i would ask is the diagnosit file.

     

    I would need you to start the vm once to generate thing in dmesg syslog.

    this will also let use review some other config setting you may have set.

     

    Download and attach for me and other advance users to take a look and hopefully fix and find other errors to fix.

     

    image.thumb.png.f1fa4be3bdd7b365bf1de2e78c93e9f9.png

     

    Honestly I'm not sure what else to check or try. Iommu is good pci memory remaping is in. Grub is not letting os/kernel use Gcard nor touch frame buffer.
    VM hypervisor is enabled and working. ?vm starts? but with blank screen.

    xml file is added correctly and xml edits are in to correctly grab the card and use it in the VM.

     

    ?try reinstalling the VM OS or try another distro like Pop OS with same vm config?

    Pop comes with the driver pre packaged. if it works with pop. its a VM os kernel driver issue.

    ?install winddows 10 see if you see the card and get a error code 43?

     

     

    Threadripper 3970x on Asus Zenith II Extreme Mobo.  Bios is from 2022. There is a newer version so i'm going to give it a shot tomorrow. 

     

    I created the diagnostic file.  i have some privacy related concerns about it since it contains a lot of data. Is there any way I can send you specific files or folder? (I will review before sending)

     

    I'll give Pop OS a try tomorrow.  Another Linux distro with an existing template in the vm setup after that. Big Brother AI spyware after that... umm I mean Windows. 

  14. 4 hours ago, bmartino1 said:

    your board may need a override setting option in grub. 

     

    we need the output of thesee 2 commands for unraid terminal

     

    Lets Verifying IOMMU parameters

     

    dmesg | grep -e DMAR -e IOMMU

     

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

    "detected IOMMU"

    If there is no output, something is wrong.

     

    and

     

    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.thumb.png.a1cfc3c99075354b56a9a597d17b938b.png

     

    You may need the grub line to allow unsafe interrupts.

     

    there is a grub options a modprobe option and a vfio added parameter:

    options vfio_iommu_type1 allow_unsafe_interrupts=1

    Otherwise your baord Bios firmware may not support IOMMU and your manufacture is lazy. A Bios upgrade or downgrade may be needed.

    *patches to fix specter and meltdown sometime break with how IOMMU is supposed to operate. AMD ASUS and Gigabyte had a big upraor during that time as they killied iommu for mitigation to teh virus/malware.

     

    I recommend installing but not eanble the disable to see if your processor/board are affected and if mitigation are in affect.;

    image.png.7a78ed691e722eba02db862df617de81.png
     

     

    Results of running (dmesg | grep -e DMAR -e IOMMU) on host system.

     

    [    0.507012] pci 0000:60:00.2: AMD-Vi: IOMMU performance counters supported
    [    0.508237] pci 0000:40:00.2: AMD-Vi: IOMMU performance counters supported
    [    0.513697] pci 0000:20:00.2: AMD-Vi: IOMMU performance counters supported
    [    0.515574] pci 0000:00:00.2: AMD-Vi: IOMMU performance counters supported
    [    0.518364] pci 0000:60:00.2: AMD-Vi: Found IOMMU cap 0x40
    [    0.518532] pci 0000:40:00.2: AMD-Vi: Found IOMMU cap 0x40
    [    0.518699] pci 0000:20:00.2: AMD-Vi: Found IOMMU cap 0x40
    [    0.518867] pci 0000:00:00.2: AMD-Vi: Found IOMMU cap 0x40
    [    0.521408] perf/amd_iommu: Detected AMD IOMMU #0 (2 banks, 4 counters/bank).
    [    0.521522] perf/amd_iommu: Detected AMD IOMMU #1 (2 banks, 4 counters/bank).
    [    0.521637] perf/amd_iommu: Detected AMD IOMMU #2 (2 banks, 4 counters/bank).
    [    0.521747] perf/amd_iommu: Detected AMD IOMMU #3 (2 banks, 4 counters/bank).
    [    1.748930] AMD-Vi: AMD IOMMUv2 loaded and initialized

     

     

    Results of (dmesg | grep 'remapping') on host,

     

     0.519033] AMD-Vi: Interrupt remapping enabled

     

    Installed "disable security mitigations" with no luck. Is this enabled or disabled by default?

     

    You mention add line (options vfio_iommu_type1 allow_unsafe_interrupts=1) to grub. Am I supposed to append it to it's own line  somewhere specific?

    (e.g  append it to the line I previously added?)

     

    label GPU passthrough mode
      menu default
      kernel /bzimage
      append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off pcie_acs_override=downstream,multifunction options vfio_iommu_type1 allow_unsafe_interrupts=1

     

    btw - thanks for the help. Hopefully we can figure this out but even if not I'm learning a lot just trying different things.

     

  15. 19 hours ago, bmartino1 said:

     

    It best to stay updated. with OS release. tools > update OS

    6.12.10 fixes a CVE issue.

    not sure if you added labe to the global configurations.

     

    its best to edit the text under Unraid OS.

    but yes, that looks good. 

     

    The good news. The System boots fine. The bad news. VM still doesn't recognize the GPU.  Any thoughts on what I should try next?

  16. 1 hour ago, bmartino1 said:

    If you haven't already. There is a os unraid release, I recommend updating to 6.12.10

    ? Perfect lspci showing the correct driver for VM use.

     

    Kernel driver in use: vfio-pci
     

    Kernel modules: is the driver that would be in use if it wasn't bond - told otherwise.



    Main > Flash ...

     

    /Main/Settings/Flash?name=flash

     

    Click Main
    image.png.b6489dc17d695f95ac666b3bd2b58f0e.png


    Click Flash under boot Device.

    image.png.1a4588437cb9a97bd754136cc67add16.png


    find syslinux configurations

    image.png.f33fd9af222c3988354cd2e681f38204.png

     

    to the right in green is your default boot option and grub configurations.

     

    This is your Grub Config:

    image.thumb.png.4958ed95063c50b260e1698f32c63d62.png

     

    I have other options for my grub config. for Hard disk and NVME settings.

    image.thumb.png.fb96f4b015729a50cba41f0dbd2bbc22.png

     

    For NVIDIA with fb issues, you just need the video portion and unraid gui settings from the vm tag. in this case, its the pcie_ace_overider option.

     

    You may need to fix the syntax in the box if adding more grub options. this is how the vm tab echo inserts and boots from setting the gui doesn't read it right and display it in the wrong syntax..

     

    ex:
    kernel /bzimage

    pcie_acs_override=downstream,multifunction
    append initrd=/bzroot

     

    need to become

    kernel /bzimage
    append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off pcie_acs_override=downstream,multifunction

     

     

    image.png

     

    Thanks. I made the edit (also changing it to default menu option I think) Can you quickly review before I try rebooting in case I messed something up.

     

    default menu.c32
    menu title Lime Technology, Inc.
    prompt 0
    timeout 50
    label Unraid OS
      kernel /bzimage
      append initrd=/bzroot
    label Unraid OS GUI Mode
      kernel /bzimage
      append initrd=/bzroot,/bzroot-gui
    label Unraid OS Safe Mode (no plugins, no GUI)
      kernel /bzimage
      append initrd=/bzroot unraidsafemode
    label Unraid OS GUI Safe Mode (no plugins)
      kernel /bzimage
      append initrd=/bzroot,/bzroot-gui unraidsafemode
    label Memtest86+
      kernel /memtest
    label GPU passthrough mode
      menu default
      kernel /bzimage
      append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pci=noaer pcie_aspm=off pcie_acs_override=downstream,multifunction

     

     

     

    (btw- I'm on Unraid 6.12.8)

     

  17. On 4/3/2024 at 6:20 PM, bmartino1 said:

    your xml looks good I don't see any xml issues. 

     

    the fact that unraid lspci or lspic-v done't show you the data is problematic.

    weird that system devices shows it though. a successful stub look slike this:

    lspci -v shows friend's gpu kernel driver in use as vfio. Please confirm g-card is firmly slotted and all power cables are firmly inserted.
     

    image.thumb.png.262f7c76ef73e54ba27fa2c076f2a32b.png

     

    since you don't have a onboard gpu and will go headless mode you will need to add the fb and int call back to your grub config to run unraid in headless mode.

    go to main > flash

     

    here you will need to edit your unraid grub settings.

     

    be sure to fix and keep any unraid set grub options

    the syntax should be:

     

    kernel /bzimage
    append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init

     

    depending on your vm settings you may have 

    "pcie_acs_override=downstream,multifunction"

     

    then the syntax would be:

     

    kernel /bzimage
    append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init pcie_acs_override=downstream,multifunction

     

    a reboot is required to intact these settings.

    I would also recommend unbinding the card. reboot add grub settings able then bind card to confirm a good stub.


    system tools vfio

     

    image.thumb.png.dabd90e26054cd851406b7a8c6365364.png

     

    image.thumb.png.483881b4faccea1d837d415b587552a2.png

     

     Optional but recommend.
    edit vfio and add

    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=10de:2204,10de:1aef disable_idle_d3=1 enable_sriov disable_denylist disable_vga=1

     

    rebuild and reboot. this eases the nvidia driver into vfio.

     

     

    I tried to add line...

     

    "kernel /bzimage append initrd=/bzroot video=vesafb:off,efifb:off,simplefb:off,astdrmfb initcall_blacklist=sysfb_init"

     

    ...but  couldn't find the grub file on flash drive. Where exactly is located in Unraid and its exact name?

  18. On 4/3/2024 at 6:50 PM, bmartino1 said:

    you need unraid to show lspci -v

     

    Kernel driver in use for all parts of the G-card.
    if you dont' see vfio / vfio-pci there is a bigger problem!

     

    If not, the device will not function properly in a vm.

     

    I ran "lspci -v | grep vfio" (on host) and it returned following.

    Kernel driver in use: vfio-pci
    Kernel driver in use: vfio-pci

     

    I also ran "lspci -v | grep nvidia"

     Kernel modules: nvidia_drm, nvidia

  19. 18 hours ago, bmartino1 said:

    Close, but no here is a fix for that portion:


    the problem being that both the pci bus are still need to be different. by default, unraids likes to default throws thing to pci bus 4


    Usually find keyboard in the xml and add the multifunction and fix settings to the next pcie device and one after.

    we will use vm virtual mother board slot 2. we will remove the broken/unnecessary xml
    I'm not sure if alias name is breaking something for you here.

    Note now that you have edited the xml you can't use the unraid GUI vm options to fix if you do you will erase all xml edits and need to fix them each edit!
     


     

    your vm tab should also show this after edits are done:
    image.thumb.png.e50331ca33e8cabe6bed2b7a9f517027.png

    Note that it says NVIDIA graphic for display out.


    I recommend editing the web gui version first, then making the necessary edits.
    image.thumb.png.4bea296c3b475e475e7e9c01af836043.png

     

    I don't like to use the pin feature, it has its uses. but i rather set a vcpu count and let the machin load balncer work it out.
    i would need the entire xml to make thoese edits for you. its hard to explin what to change and where. ther is no security issues.

    this is my friends unraid with a windows gaming machine with a nvdia 3060 as an example:
     

    <?xml version='1.0' encoding='UTF-8'?>
    <domain type='kvm' id='1'>
      <name>Windows</name>
      <uuid>a0abe979-e098-7bee-2054-aefa184b8732</uuid>
      <description>Windwos-Gaming</description>
      <metadata>
        <vmtemplate xmlns="unraid" name="Windows 10" icon="windows.png" os="windows10"/>
      </metadata>
      <memory unit='KiB'>8388608</memory>
      <currentMemory unit='KiB'>8388608</currentMemory>
      <memoryBacking>
        <nosharepages/>
      </memoryBacking>
      <vcpu placement='static'>4</vcpu>
      <resource>
        <partition>/machine</partition>
      </resource>
      <os>
        <type arch='x86_64' machine='pc-q35-7.2'>hvm</type>
        <loader readonly='yes' type='pflash'>/usr/share/qemu/ovmf-x64/OVMF_CODE-pure-efi.fd</loader>
        <nvram>/etc/libvirt/qemu/nvram/a0abe979-e098-7bee-2054-aefa184b8732_VARS-pure-efi.fd</nvram>
      </os>
      <features>
        <acpi/>
        <apic/>
        <hyperv mode='custom'>
          <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' migratable='on'>
        <topology sockets='1' dies='1' cores='4' threads='1'/>
        <cache mode='passthrough'/>
        <feature policy='require' name='topoext'/>
      </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/vdisk1.img' index='1'/>
          <backingStore/>
          <target dev='hdc' bus='sata'/>
          <serial>vdisk1</serial>
          <boot order='1'/>
          <alias name='sata0-0-2'/>
          <address type='drive' controller='0' bus='0' target='0' unit='2'/>
        </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='pci' index='5' model='pcie-root-port'>
          <model name='pcie-root-port'/>
          <target chassis='5' port='0x14'/>
          <alias name='pci.5'/>
          <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x4'/>
        </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='direct' trustGuestRxFilters='yes'>
          <mac address='52:54:00:a7:b1:48'/>
          <source dev='vhost0' mode='bridge'/>
          <target dev='macvtap0'/>
          <model type='virtio'/>
          <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-1-Windows/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='2'/>
        </input>
        <input type='mouse' bus='ps2'>
          <alias name='input1'/>
        </input>
        <input type='keyboard' bus='ps2'>
          <alias name='input2'/>
        </input>
        <audio id='1' type='none'/>
        <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x10' 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='0x10' slot='0x00' function='0x1'/>
          </source>
          <alias name='hostdev1'/>
          <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x1'/>
        </hostdev>
        <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x0b' slot='0x00' function='0x0'/>
          </source>
          <alias name='hostdev2'/>
          <address type='pci' domain='0x0000' bus='0x05' slot='0x00' function='0x0'/>
        </hostdev>
        <memballoon model='none'/>
      </devices>
      <seclabel type='dynamic' model='dac' relabel='yes'>
        <label>+0:+100</label>
        <imagelabel>+0:+100</imagelabel>
      </seclabel>
    </domain>

     

    your xml will be differnet you won't be able to copy past as there are thing you need to watch.

     

    vcpu and cores also is removed if you make a gui edit...


    don't delete your line 3-line 7 this is unraid visual display in vm tab
    note my line 14 vcpu is set to 4 and that cputune is removed.
    my line 19-21 machine vm type is pc q35 v 7.2
    the loader and nvram are vm specfic!!!!
    note my line 33 - 36 cores needs updated to fix hardware vcpu processing.
    note my line 49 this is where your vdisk is stored on unraid.


    find keyboard my line 150:
    150-169 is my gcard pass though.

    I also have a usb pci device passed

    You can use this as a reference if needed.

     

    I changed bus setting to "2" as  you suggested but it wouldn't save XML ("attempted double use of PCI Address error). I was able to change it to "5" but it didn't make a difference.

     

    Out of curiousity are you on a system with two GPUs? My system only has one GPU the 3090. It has no IGPU.. The first reply (other poster) suggested that when my system boots the host system might be locking the GPU which is what is preventing the passthrough to VM. I didn't understand his instructions as to how to change that though.

     

     

     

     

     

  20. 16 hours ago, bmartino1 said:

    the ubuntu vm also needs to have nvida drivers installer.

    I would have you install openssh-server and connect to the vm via ssh

     

    you can see the NVIDIA card by typing lspci in the ubuntu vm.

     

    apt-get install mc nano vim openssh-server nfs-common cifs-utils

    ^ other recommend packages. 

    https://ubuntu.com/server/docs/nvidia-drivers-installation

     

    I downloaded driver directly from Nvidia. During installation it doesn't recognize the existence of the 3090 not do I see it when I run various hardware utilities (I can see the GPU in Unraid host but not the VM). Also connected to Ubuntu VM with SSH as opposed to RDP but didn't make a difference.

  21. Thanks for the reply. There is a lot to unpack so I'm trying to make sure I'm doing things right step by step. I made multifunction edit to my VM's config  but doens't work yet. Does this at least look correct? (before I move on to something else)

     

        <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x01' slot='0x00' function='0x0'/>
          </source>
          <alias name='hostdev0'/>
          <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='0x01' slot='0x00' function='0x1'/>
          </source>
          <alias name='hostdev1'/>
          <address type='pci' domain='0x0000' bus='0x04' slot='0x00' function='0x1'/>
        </hostdev>

  22. My Ubuntu VM installed with no issues and boots fine. I am also able to RDP into it no problem (have XRDP installed). I'm trying to do a GPU passthrough with a rtx3090. 

     

    I've checked below IOMMU group in tools >  system devices (and rebooted)

    IOMMU group 84 :

    [10de:2204] 01:00.0 VGA compatible controller: NVIDIA Corporation GA102 [GeForce RTX 3090] (rev a1)

    [10de:1aef] 01:00.1 Audio device: NVIDIA Corporation GA102 High Definition Audio Controller (rev a1)

     

    Then I selected "NVIDIA GeForce RTX 3090 (01:00.0)" in dropdown of  "Graphics Card" field of my VM's configuration. 

     

    When I try to install the Nvidia Linux driver it can't find the GPU. I installed inxi to check then ran "sudo inxi --full". Although Unraid OS recognizes it, my Ubuntu VM does not see my GPU.  Any ideas on what I'm missing?

     

×
×
  • Create New...