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

    Deteching Host is Failing with Error

    Scheduled Pinned Locked Moved Management
    5 Posts 3 Posters 24 Views 3 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.
    • K Online
      Kajetan321
      last edited by

      Hello, I’m trying to decommission a host. It is the only host in its pool. There are no VMs on this host. When I go to Home > Hosts > select host > Advanced > Detach I get:

      host.detach
      {
        "host": "69c0c257-a547-4d49-8270-b49eafe35c2c"
      }
      {
        "code": "INTERNAL_ERROR",
        "params": [
          "Xapi_pool.Cannot_eject_master"
        ],
        "call": {
          "duration": 4,
          "method": "pool.eject",
          "params": [
            "* session id *",
            "OpaqueRef:a845b495-af26-4fd0-8b82-813167b3f2ca"
          ]
        },
        "message": "INTERNAL_ERROR(Xapi_pool.Cannot_eject_master)",
        "name": "XapiError",
        "stack": "XapiError: INTERNAL_ERROR(Xapi_pool.Cannot_eject_master)
          at XapiError.wrap (file:///opt/xo/xo-builds/xen-orchestra-202602261435/packages/xen-api/_XapiError.mjs:16:12)
          at file:///opt/xo/xo-builds/xen-orchestra-202602261435/packages/xen-api/transports/json-rpc.mjs:38:21
          at runNextTicks (node:internal/process/task_queues:65:5)
          at processImmediate (node:internal/timers:472:9)
          at process.callbackTrampoline (node:internal/async_hooks:130:17)"
      }
      
      

      Any ideas? I’m running Xen Orchestra commit 32220 from source. I tried rebooting the host and updating XO but this changed nothing, still getting the same error. The error seems to imply that one cannot eject a pool master but how do I decommission the host that is its own pool master?

      M 1 Reply Last reply Reply Quote 0
      • M Offline
        MajorP93 @Kajetan321
        last edited by MajorP93

        @Kajetan321 said in Deteching Host is Failing with Error:

        Cannot_eject_master

        According to your log the host that you are trying to decommission / detach is your pool master.
        You have to designate a new master before you can detach that particular host.

        You can do that via Xen Orchestra: Home --> Pools --> YourPool --> Advanced --> Master --> click on name of current master and select a new one.

        After that you should be able to detach the host in question.

        //EDIT: Oh I just read that it is the only host in that pool. In that case you should disconnect the whole pool (the pool that has only 1 host, the 1 host in question).

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

          A host cannot be outside a pool. Even on a fresh install, a host is always in a pool. If the host is already alone in a pool, there's nothing specific to decomission it, just shutdown it and you are done.

          M 1 Reply Last reply Reply Quote 0
          • M Offline
            MajorP93 @olivierlambert
            last edited by

            @olivierlambert I understood him in a way that his XO has multiple pools connected to it hence the suggestion to disconnect the pool that only has this one host as a member.

            1 Reply Last reply Reply Quote 0
            • K Online
              Kajetan321 @MajorP93
              last edited by Kajetan321

              @MajorP93 OK I tried disconnecting the pool first but now I'm getting:

              server.disable
              {}
              {
                "code": 10,
                "data": {
                  "errors": [
                    {
                      "instancePath": "",
                      "schemaPath": "#/required",
                      "keyword": "required",
                      "params": {
                        "missingProperty": "id"
                      },
                      "message": "must have required property 'id'"
                    }
                  ]
                },
                "message": "invalid parameters",
                "name": "XoError",
                "stack": "XoError: invalid parameters
                  at Module.invalidParameters (/opt/xo/xo-builds/xen-orchestra-202602261435/packages/xo-common/api-errors.js:26:11)
                  at Xo.call (file:///opt/xo/xo-builds/xen-orchestra-202602261435/packages/xo-server/src/xo-mixins/api.mjs:121:22)
                  at Api.#callApiMethod (file:///opt/xo/xo-builds/xen-orchestra-202602261435/packages/xo-server/src/xo-mixins/api.mjs:409:19)"
              }
              

              I guess I will just power down the host and that will be it, as Olivier recommends.

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