• RC3 VM Alias Handler Change?


    Arbadacarba
    • Minor

    I'm running a pfsense VM with a 2port NIC and an Atheros Wifi card passed through.

     

    (I have a slightly unreliable POINT to POINT LTE connection, and occasional mission critical internet requirements - So the Wifi card is set to automatically connect to my cell phone hotspot)

     

    I had trouble getting this Wifi card to work with an error message referencing hostdev1 or something not fitting in BARs.

     

    image.thumb.png.de7558e8c54f0e1dbb3bbc404e5bbf0b.png

     

    I searched, I posted, I got a great answer from Ghost82 who translated the info I had found into the xml:

        <qemu:commandline>
          <qemu:arg value='-set'/>
          <qemu:arg value='device.hostdev1.x-msix-relocation=bar2'/>
        </qemu:commandline>
      </domain>

     

    This, with minimal fiddling (hostdev0 not hostdev1) worked perfectly.

    20220220_2240_pfSense - Cerberus.xml

     

    Right up until I updated to RC3.

     

    First the VFIO passthrough changed in System Devices, and then after I re-enabled that it still would not boot the VM.

    But now it doesn't refer to any hostdev id... it refers to it as bellow

      

    image.png.c84cd227207afc7bb7a0ef74d52395ae.png

     

    If I remove the Wifi card the 2 NIC ports get alias' lines, but if I add the Wifi card back in nothing does.

    Working - No WIFI.txt

    If I edit the xml to give the Wifi card an alias and put the comandline part back in.

    WIFI Added with Command.txt

     

    I get an error claiming there is no hostdev0

     

    image.png.c4ac339a0ae6781c02775e9eb7ab5e8d.png

     

    and when I look back in the XML the alias' are all gone.

    Alias missing.txt

     

    Ghost82 suggests editing the XML in the cli but I haven't tried that yet. Would it make a difference? Should it?

     

    Has there been some change t the way alias' are handled? I don't understand why they disappear.

     

    Thanks for any help

     

    Arbadacarba

     

    jupiter-diagnostics-20220315-0016.zip




    User Feedback

    Recommended Comments



    On 3/22/2022 at 11:56 AM, ghost82 said:

    ok, last test for this, back to the beginning:

    1. Restore the hostdev block:

        <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
          </source>
          <alias name='ua-sm2262'/>
          <address type='pci' domain='0x0000' bus='0x03' slot='0x00' function='0x0'/>
        </hostdev>

     

    2. Restore the -set qemu:arg and disable json:

      <qemu:commandline>
        <qemu:arg value='-set'/>
        <qemu:arg value='device.ua-sm2262.x-msix-relocation=bar2'/>
      </qemu:commandline>
      <qemu:capabilities>
        <qemu:del capability='device.json'/>
      </qemu:capabilities>

     

    Can you attach diagnostics after this? just to look at if json is disabled or not.

     

     

    I don't know if necro is allowed. But this thread is closest to what I need help with.
    Maybe I should start a new thread?

     

    I figured out the qemu stuff but now vm reports alias not found. Well...every time I put in my alias in the hostdev block it gets eaten by whatever script is cleaning up the xml stuff.

     

    How do I make it stop eating my alias line?

     

        <hostdev mode='subsystem' type='pci' managed='yes'>
          <driver name='vfio'/>
          <source>
            <address domain='0x0000' bus='0x23' slot='0x00' function='0x0'/>
          </source>
          	  <alias name='intel512'/>
          <address type='pci' domain='0x0000' bus='0x00' slot='0x05' function='0x0'/>
        </hostdev>
        <memballoon model='none'/>
      </devices>
      <qemu:commandline>
        <qemu:arg value='-set'/>
        <qemu:arg value='device.intel512.x-msix-relocation=bar2'/>
      </qemu:commandline>
      <qemu:capabilities>
        <qemu:del capability='device.json'/>
      </qemu:capabilities>
    </domain>

     

     

    [8086:f1a6] 23:00.0 Non-Volatile memory controller: Intel Corporation SSD Pro 7600p/760p/E 6100p Series (rev 03)
    This controller is bound to vfio, connected drives are not visible.
    
    Version 6.10.3 2022-06-14
    Libvirt version: 8.2.0
    

     

    Link to comment

    This is where we are at the moment. Same problem, it was fixed and then promptly broken again. What are you trying to alias?

     

    Here's the other thread:

     

     

     

    Link to comment

    Joy...

     

    On a good note Ghost82 seems to be a wizard; even using a translator!?

     

    I am trying to pass an intel 512 NVMe into a VM. It already has W10 installed so I wanted to do some basic BareMetal vs VM testing for funsies (new to Unraid, just trying things out to learn...).

     

    Reading through all the threads and editing xml made my head hurt. I thought I had it figured out (BAR error goes away) except for the alias for the NVMe disappears upon 'save/update'.

     

    Edit: Ahh, got to the bottom of the thread you sent about WiFi dongles... I see Ghost82's statemnt on June 20th saying this is borked. Sad... I really wanted VM's to work/be easy in Unraid.

    I might go back to my thinking of using XCP-NG and passing through for Unraid. But... that also has it's own annoyances.
    I'm sure normal VM's work just fine?

     

     

    53 minutes ago, Arbadacarba said:

    This is where we are at the moment. Same problem, it was fixed and then promptly broken again. What are you trying to alias?

     

    Here's the other thread:

     

     

     

    Edited by NathanR
    Link to comment

    Strangely you are doing the thing that started me down this path. My Server contained an Intel 660p 512 with Windows 10 on it that I used for my gaming machine with a GTX 1660 Ti passed through as well... 

     

    I was able to get the intel to pass through easily enough and in truth did it a few different ways...

     

    What error messages are you getting?

     

    I initially did mine by manually assigning a non ... passed through (?) (VFIO?) Drive:

     

        <disk type='block' device='disk'>

          <driver name='qemu' type='raw' cache='writeback'/>

          <source dev='/dev/disk/by-id/nvme-INTEL_SSDPEKKW512G7_BTPY652201XX512F'/>

          <backingStore/>

          <target dev='hdc' bus='sata'/>

          <boot order='1'/>

          <address type='drive' controller='0' bus='0' target='0' unit='2'/>

        </disk>

     

    I actually did that in the GUI but I don't have a screen shot of what it looked like but:

     

    image.png.eaefde222637e745c3127dc1eb918309.png

     

    The only problem I had with that was that in the event of a unexpected server shutdown the drive would get screwed up and I would have to fix it.

    image.png

    • Thanks 1
    Link to comment
    On 7/12/2022 at 9:40 PM, Arbadacarba said:

    Strangely you are doing the thing that started me down this path. My Server contained an Intel 660p 512 with Windows 10 on it that I used for my gaming machine with a GTX 1660 Ti passed through as well... 

     

    I was able to get the intel to pass through easily enough and in truth did it a few different ways...

     

    Holy crap that worked!

    Thank you!!!

    image.png.fdb19250253c67644c367eaf25a945e5.png

     

    I figured out that I needed a few things first though.

     

    Found this guide: https://exitcode0.net/how-to-pass-through-a-drive-to-a-unraid-vm/

    Which led me to this plugin/app: https://forums.unraid.net/topic/92462-unassigned-devices-managing-disk-drives-and-remote-shares-outside-of-the-unraid-array/

     

     

    Which led me to trying to figure out what my drive ID was. Until I finally found out that I could use /dev/nvme0n1

    image.thumb.png.39a41c1d6c05c8632c4b9115aef11204.png

     

    This also fixed the extra vDisk Size & Type lines that normally show up

    image.png.668ade3474625b02f3cbb56435129f02.png

    Link to comment

    Good to hear that it helped... Unassigned devices... Sorry, I didn't even think of that... Yes of course you need that first.

    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
    Add a comment...

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


  • Status Definitions

     

    Open = Under consideration.

     

    Solved = The issue has been resolved.

     

    Solved version = The issue has been resolved in the indicated release version.

     

    Closed = Feedback or opinion better posted on our forum for discussion. Also for reports we cannot reproduce or need more information. In this case just add a comment and we will review it again.

     

    Retest = Please retest in latest release.


    Priority Definitions

     

    Minor = Something not working correctly.

     

    Urgent = Server crash, data loss, or other showstopper.

     

    Annoyance = Doesn't affect functionality but should be fixed.

     

    Other = Announcement or other non-issue.