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

    Unable to display files in File Restore (failed to setup loop device)

    Scheduled Pinned Locked Moved Xen Orchestra
    21 Posts 2 Posters 3.0k 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.
    • S Offline
      simonk83
      last edited by simonk83

      I get here and immediately get that exclamation mark and the below log error:

      68e48ee0-f96a-4d96-9dda-1262b415360f-image.png

      backupNg.listFiles
      {
        "remote": "c7ae17c6-c7da-4ce5-a149-389257118aa1",
        "disk": "xo-vm-backups/9033182f-7a99-26c4-9f0c-f38c97438d3c/vdis/ea7fc1f6-bdb1-42af-8865-044767cf1340/6fd842c3-c025-4fee-80ad-fe2b3c33f6cc/20190427T140014Z.vhd",
        "path": "/",
        "partition": "7887b518-05/debian-vg/root"
      }
      {
        "code": 32,
        "stdout": "",
        "stderr": "mount: /tmp/tmp-751kkoSeZpmwHMt: failed to setup loop device for /dev/debian-vg/root.
      ",
        "failed": true,
        "signal": null,
        "cmd": "mount --options=loop,ro --source=/dev/debian-vg/root --target=/tmp/tmp-751kkoSeZpmwHMt",
        "timedOut": false,
        "killed": false,
        "message": "Command failed: mount --options=loop,ro --source=/dev/debian-vg/root --target=/tmp/tmp-751kkoSeZpmwHMt
      mount: /tmp/tmp-751kkoSeZpmwHMt: failed to setup loop device for /dev/debian-vg/root.
      
      ",
        "name": "Error",
        "stack": "Error: Command failed: mount --options=loop,ro --source=/dev/debian-vg/root --target=/tmp/tmp-751kkoSeZpmwHMt
      mount: /tmp/tmp-751kkoSeZpmwHMt: failed to setup loop device for /dev/debian-vg/root.
      
      
          at makeError (/opt/xen-orchestra/node_modules/execa/index.js:174:9)
          at Promise.all.then.arr (/opt/xen-orchestra/node_modules/execa/index.js:278:16)
          at tryCatcher (/opt/xen-orchestra/node_modules/bluebird/js/release/util.js:16:23)
          at Promise._settlePromiseFromHandler (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:512:31)
          at Promise._settlePromise (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:569:18)
          at Promise._settlePromise0 (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:614:10)
          at Promise._settlePromises (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:694:18)
          at Promise._fulfill (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:638:18)
          at PromiseArray._resolve (/opt/xen-orchestra/node_modules/bluebird/js/release/promise_array.js:126:19)
          at PromiseArray._promiseFulfilled (/opt/xen-orchestra/node_modules/bluebird/js/release/promise_array.js:144:14)
          at Promise._settlePromise (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:574:26)
          at Promise._settlePromise0 (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:614:10)
          at Promise._settlePromises (/opt/xen-orchestra/node_modules/bluebird/js/release/promise.js:694:18)
          at _drainQueueStep (/opt/xen-orchestra/node_modules/bluebird/js/release/async.js:138:12)
          at _drainQueue (/opt/xen-orchestra/node_modules/bluebird/js/release/async.js:131:9)
          at Async._drainQueues (/opt/xen-orchestra/node_modules/bluebird/js/release/async.js:147:5)
          at Immediate.Async.drainQueues (/opt/xen-orchestra/node_modules/bluebird/js/release/async.js:17:14)
          at runCallback (timers.js:810:20)
          at tryOnImmediate (timers.js:768:5)
          at processImmediate [as _immediateCallback] (timers.js:745:5)"
      }
      

      It seems to be just this VM, my others are OK...

      1 Reply Last reply Reply Quote 0
      • olivierlambertO Offline
        olivierlambert Vates 🪐 Co-Founder CEO
        last edited by

        We need more context:

        1. Are you using XOA or XO from the sources? If from the sources, did you install it following the official documentation?
        2. Are you up to date?
        3. On what kind of remote are stored your VMs?
        S R 2 Replies Last reply Reply Quote 0
        • S Offline
          simonk83 @olivierlambert
          last edited by simonk83

          @olivierlambert

          No worries:

          1. Yep I'm using the community version. I've set it up via this script and keep it updated via this script.

          2. I just ran the update script and am on 5.40.0, but I tried it with 5.35 before I updated and it didn't work (that's why I tried updating).

          3. My VM's are stored on internal SSD's in raid

          1 Reply Last reply Reply Quote 0
          • olivierlambertO Offline
            olivierlambert Vates 🪐 Co-Founder CEO
            last edited by

            So you are using "local" remote right?

            Anyway, because you are using a 3rd party installer, I'm not really able to assist (because we can't "validate" those installer/updater while we are adding/removing stuff on our side).

            1. If you can't see the files for all your backup VMs, I would suggest to create an issue on the installer GitHub repo because it's mainly an "environment" issue
            2. If you can't see files only for this VM, then it's maybe your VM is not "like" the others
            S 1 Reply Last reply Reply Quote 0
            • S Offline
              simonk83 @olivierlambert
              last edited by

              @olivierlambert Yep fair enough.

              It's only that one VM so I guess it's that, I'll have a dig around.

              1 Reply Last reply Reply Quote 0
              • S Offline
                simonk83
                last edited by simonk83

                Sorry, quick question just because it'll probably save me hours of googling 😉

                The log says

                failed to setup loop device for /dev/debian-vg/root
                

                If I run lsblk -fs in the VM I get:

                 lsblk -fs
                NAME              FSTYPE      LABEL UUID                                   MOUNTPOINT
                xvda1             ext2              728f3ff5-b4e4-4c49-8440-1afca3bedffb   /boot
                └─xvda                                                                     
                xvda2                                                                      
                └─xvda                                                                     
                debian--vg-root   ext4              e91dbbbe-5fc8-4631-8693-00fdea49cfcf   /
                └─xvda5           LVM2_member       0IfZhR-hixh-FPMO-nvSc-EdMa-l3Fh-JCFyC3 
                  └─xvda                                                                   
                debian--vg-swap_1 swap              3e7fab19-8bb2-47da-bb16-a829010e1d51   [SWAP]
                └─xvda5           LVM2_member       0IfZhR-hixh-FPMO-nvSc-EdMa-l3Fh-JCFyC3 
                  └─xvda                                                                   
                

                So is it that XO is trying to mount /dev/debian-vg/root but it's actually /dev/debian--vg/root ??

                EDIT: Nope, never mind:

                simon@dashboard:/dev/debian-vg$ ls
                root  swap_1
                

                Hmm.

                EDIT2: If I run the same command in the VM I get:

                simon@dashboard:/$ sudo mount --options=loop,ro --source=/dev/debian-vg/root --target=/tmp/tmp-751rBsQbj6YN1TI
                mount: mount point /tmp/tmp-751rBsQbj6YN1TI does not exist
                

                So is XO failing to create that first? I guess not as the error would probably indicate such

                1 Reply Last reply Reply Quote 0
                • olivierlambertO Offline
                  olivierlambert Vates 🪐 Co-Founder CEO
                  last edited by

                  You other VMs also have LVM with a "--" in the LV name?

                  S 2 Replies Last reply Reply Quote 0
                  • S Offline
                    simonk83 @olivierlambert
                    last edited by

                    @olivierlambert One does, but that seems fine with the file restore...

                    1 Reply Last reply Reply Quote 0
                    • olivierlambertO Offline
                      olivierlambert Vates 🪐 Co-Founder CEO
                      last edited by

                      To rule out a environment issue, you can try to same restore with XOA. If you have the issue too, it means there is a bug in XO. Otherwise, it's your install 🙂

                      1 Reply Last reply Reply Quote 0
                      • S Offline
                        simonk83 @olivierlambert
                        last edited by

                        @olivierlambert Well... I was just typing out a response about how I can select the smaller partition called Linux just fine but not the bigger partition called root, but when I clicked on root this time it loaded just fine....

                        Can't really explain that. I did reboot the VM again a bit ago, but I tried it straight after that and it still didn't work. Now a couple of hours later with no changes at my end it's fine. Odd!

                        1 Reply Last reply Reply Quote 0
                        • olivierlambertO Offline
                          olivierlambert Vates 🪐 Co-Founder CEO
                          last edited by

                          Okay, well 😄 We don't have a known issue with that on our support so I suppose it was "env" related 🙂

                          S 1 Reply Last reply Reply Quote 0
                          • S Offline
                            simonk83 @olivierlambert
                            last edited by

                            @olivierlambert said in Unable to display files in File Restore (failed to setup loop device):

                            Okay, well 😄 We don't have a known issue with that on our support so I suppose it was "env" related 🙂

                            Aaaand now it's broken again haha. I'll try what you said and give it a go in XOA when I get a chance, see if it's the same there.

                            1 Reply Last reply Reply Quote 0
                            • olivierlambertO Offline
                              olivierlambert Vates 🪐 Co-Founder CEO
                              last edited by

                              Okay, let us know. You can use the trial to unlock all features for 15 days, which is enough to test this 🙂

                              S 1 Reply Last reply Reply Quote 0
                              • S Offline
                                simonk83 @olivierlambert
                                last edited by

                                @olivierlambert Ohh I think I've already used it actually. I'll boot up the VM and check.

                                1 Reply Last reply Reply Quote 0
                                • olivierlambertO Offline
                                  olivierlambert Vates 🪐 Co-Founder CEO
                                  last edited by

                                  Let me know I can re-extend it 🙂

                                  S 1 Reply Last reply Reply Quote 0
                                  • S Offline
                                    simonk83 @olivierlambert
                                    last edited by

                                    @olivierlambert Ah thanks, it has indeed expired. Is there any issue having both XO's running at the same time by the way?

                                    1 Reply Last reply Reply Quote 0
                                    • olivierlambertO Offline
                                      olivierlambert Vates 🪐 Co-Founder CEO
                                      last edited by

                                      No problem 🙂 I'll extend your trial

                                      1 Reply Last reply Reply Quote 0
                                      • olivierlambertO Offline
                                        olivierlambert Vates 🪐 Co-Founder CEO
                                        last edited by

                                        Extended!

                                        S 1 Reply Last reply Reply Quote 0
                                        • S Offline
                                          simonk83 @olivierlambert
                                          last edited by

                                          @olivierlambert Thanks for that. Well it seems fine in the main XO so I guess it's a problem with the community version, or at least my install of it (plus something to do with that single VM). Who maintains the community version?

                                          1 Reply Last reply Reply Quote 0
                                          • olivierlambertO Offline
                                            olivierlambert Vates 🪐 Co-Founder CEO
                                            last edited by

                                            There is no "maintenance" but community support if you follow how it's installed from our official documentation: https://xen-orchestra.com/docs/from_the_sources.html

                                            If you use something else (like a 3rd party script), then create an issue on the GH repo where you found the script 🙂

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