XCP-ng
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Register
    • Login

    Sata controller passthrough. VM no bootable device

    Scheduled Pinned Locked Moved Compute
    24 Posts 3 Posters 5.3k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • I Offline
      impovich @jmccoy555
      last edited by

      @jmccoy555 i guess you have an HBA controller?

      J 1 Reply Last reply Reply Quote 0
      • J Offline
        jmccoy555 @impovich
        last edited by jmccoy555

        @impovich Ah yeah. Only passed though a controller to Linux VMs and that works fine. Could try TrueNAS Scale??

        https://forums.freebsd.org/threads/dev-ad4-becomes-dev-ada0.29899/ Any help?

        I'm out of ideas I'm afraid.

        I 1 Reply Last reply Reply Quote 0
        • I Offline
          impovich @jmccoy555
          last edited by

          @jmccoy555 said in Sata controller passthrough. VM no bootable device:

          @impovich Ah yeah. Only passed though a controller to Linux VMs and that works fine. Could try TrueNAS Scale??

          https://forums.freebsd.org/threads/dev-ad4-becomes-dev-ada0.29899/ Any help?

          I'm out of ideas I'm afraid.

          I tried to do the same with Debian, no success. Reading freebsd forum regarding labeling

          J 1 Reply Last reply Reply Quote 0
          • J Offline
            jmccoy555 @impovich
            last edited by

            @impovich Passing though my second onbord SATA controller to a Debian 10 VM gives me xvda for the virtual disk and sda, sdb, etc for discs on the passed though controller.

            I 1 Reply Last reply Reply Quote 0
            • I Offline
              impovich @jmccoy555
              last edited by impovich

              @jmccoy555 so managed to do it with a dirty hack 🙂

              1. Spwaned a new VM with 3 virtual drives
                ada0 - 5gb
                ada1 - 5gb
                ada2 - 50gb
              2. installed Truenas on ada2.
              3. After installation removed ada0 and ada1
              4. Rebooted VM and confirmed that ada2 is still ada2
              5. passed through SATA controller
              6. Bingo!!
              
              root@truenas[~]# geom disk list
              Geom name: ada2
              Providers:
              1. Name: ada2
                 Mediasize: 53687091200 (50G)
                 Sectorsize: 512
                 Mode: r1w1e2
                 descr: (null)
              
              
              Geom name: cd0
              Providers:
              1. Name: cd0
                 Mediasize: 0 (0B)
                 Sectorsize: 2048
                 Mode: r0w0e0
                 descr: QEMU QEMU DVD-ROM
                 ident: (null)
              
              Geom name: ada0
              Providers:
              1. Name: ada0
                 Mediasize: 4000787030016 (3.6T)
                 Sectorsize: 512
                 Stripesize: 4096
                 Stripeoffset: 0
                 Mode: r0w0e0
                 descr: ST4000LM024-2U817V
                 lunid: 5000c500d5
              
                 fwheads: 16
              
              Geom name: ada1
              Providers:
              1. Name: ada1
                 Mediasize: 4000787030016 (3.6T)
                 Sectorsize: 512
                 Stripesize: 4096
                 Stripeoffset: 0
                 Mode: r0w0e0
              
              1 Reply Last reply Reply Quote 0
              • I Offline
                impovich
                last edited by impovich

                Finally, I found a solution to the issue:
                https://www.truenas.com/community/threads/multiple-ada0-partitions-on-xen-pv-w-passthrough.16574/

                set via GUI tunables interface:

                hint.ada.0.at="scbus100".
                

                Works perfectly!

                root@truenas[~]# geom disk list
                Geom name: ada0
                Providers:
                1. Name: ada0
                   Mediasize: 53687091200 (50G)
                   Sectorsize: 512
                   Mode: r1w1e2
                   descr: (null)
                   ident: (null)
                   rotationrate: unknown
                   fwsectors: 0
                   fwheads: 0
                
                Geom name: cd0
                Providers:
                1. Name: cd0
                   Mediasize: 0 (0B)
                   Sectorsize: 2048
                   Mode: r0w0e0
                   descr: QEMU QEMU DVD-ROM
                   ident: (null)
                   rotationrate: unknown
                   fwsectors: 0
                   fwheads: 0
                
                Geom name: ada1
                Providers:
                1. Name: ada1
                   Mediasize: 4000787030016 (3.6T)
                   Sectorsize: 512
                   Stripesize: 4096
                   Stripeoffset: 0
                   Mode: r0w0e0
                   descr: ST4000LM024-2U817V
                   lunid: 5000c500d5b4af0c
                   ident: WCK7ABLM
                   rotationrate: 5400
                   fwsectors: 63
                   fwheads: 16
                
                Geom name: ada2
                Providers:
                1. Name: ada2
                   Mediasize: 4000787030016 (3.6T)
                   Sectorsize: 512
                   Stripesize: 4096
                   Stripeoffset: 0
                   Mode: r0w0e0
                   descr: ST4000LM024-2U817V
                   lunid: 5000c500d5b3d1cb
                   ident: WCK7ADS1
                   rotationrate: 5400
                   fwsectors: 63
                   fwheads: 16
                
                J 2 Replies Last reply Reply Quote 0
                • J Offline
                  jmccoy555 @impovich
                  last edited by

                  @impovich How odd that that can even happen. I still prefer the hack 😆

                  1 Reply Last reply Reply Quote 0
                  • J Offline
                    jmccoy555 @impovich
                    last edited by jmccoy555

                    @impovich I'm running with a 10gb boot drive if you want to save a bit of space, speed up backups etc.

                    I 1 Reply Last reply Reply Quote 0
                    • I Offline
                      impovich @jmccoy555
                      last edited by

                      @jmccoy555 sorry but didn't get it. I'm a newbie

                      J 1 Reply Last reply Reply Quote 0
                      • J Offline
                        jmccoy555 @impovich
                        last edited by

                        @impovich just saying 50gb is quite big for TrueNAS, but not a problem.

                        I 1 Reply Last reply Reply Quote 0
                        • I Offline
                          impovich @jmccoy555
                          last edited by

                          @jmccoy555 got it. Thank you for being with me during this amazing journey 🙂

                          1 Reply Last reply Reply Quote 1
                          • First post
                            Last post