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

    Offline host vm removal

    Scheduled Pinned Locked Moved Solved Xen Orchestra
    6 Posts 2 Posters 1.2k Views 1 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.
    • C Offline
      cyrus104
      last edited by

      Running xcp-ng 8.2, had a host drop offline due to a power supply issue. VM running on can't be "stopped" in XO.

      I've tried Force reboot, Force Shutdown, stop, etc and I keep getting an error that the host is offline. I know this fact but I need to get rid of this not running anymore vm.

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

        It's not an XO issue. Let me explain why 🙂

        In fact, that's a Xen API protection. Let's imagine this slave host was just "cut" from the management network, but still connected on the shared storage.

        In this situation, there's no way to be sure those VMs aren't really running. And if you could just force shutdown them from the master point of view, it means they could be started on your master (for example) while still running on the slave host. This will lead to VM disk corruption instantly.

        In your case, you have to go with a VM reset power state, to tell XAPI to consider them halted regardless the unknown context (you are the only one to know your host is really down).

        https://xcp-ng.org/docs/cli_reference.html#vm-reset-powerstate

        C 1 Reply Last reply Reply Quote 2
        • C Offline
          cyrus104 @olivierlambert
          last edited by

          @olivierlambert

          That makes sense, thank you for explaining it to me.

          Would it be possible to add an option in the advanced menu to do a state reset, it can even be labelled with a break glass and don't use unless you are sure type of thing.

          Thanks again for explaining it to me.

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

            It's not exposed in the UI right now indeed. I created the issue:

            https://github.com/vatesfr/xen-orchestra/issues/5767

            olivierlambert created this issue in vatesfr/xen-orchestra

            open Add VM.power_state_reset #5767

            C 1 Reply Last reply Reply Quote 2
            • C Offline
              cyrus104 @olivierlambert
              last edited by

              @olivierlambert

              Thanks a bunch. Once on the commandline I was able to kill it as you pointed out.

              All is good. How can I mark this solved?

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

                I just did 🙂

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