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

    Forgot password for the webgui

    Scheduled Pinned Locked Moved Xen Orchestra
    11 Posts 6 Posters 2.0k Views 5 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.
    • lawrencesystemsL Offline
      lawrencesystems Ambassador @isener
      last edited by

      @isener

      I think the XO-CLI has to be registered with XO to get it working and seeing as you are locked out that is not an option. Maybe someone here will offer a way to edit the database if not I would just delete and rebuild XO.

      1 Reply Last reply Reply Quote 1
      • I Offline
        isener
        last edited by isener

        I had a snapshot from some days ago, i used that, now I can login

        but:
        when I try to register with the:
        xo-cli --register http://xo.my-company.net/api/admin@admin.net
        with the right password, i het error:

        โœ– getaddrinfo ENOTFOUND xo.my-company.net
        Error: getaddrinfo ENOTFOUND xo.my-company.net
        at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:109:26

        and when I ping, I get:
        ping: xo.my-company.net: Name or service not known

        what is wrong?
        xo.my-company.net -> which ip address should this be:
        of the xcp-neg server or the server where the xen-orchestar is installed?

        from where to run this command:
        xo-cli --register http://xo.my-company.net/api/admin@admin.net
        the xcp-neg server or the server where the xen-orchestar is installed?

        ronivayR 1 Reply Last reply Reply Quote 0
        • ronivayR Offline
          ronivay Top contributor @isener
          last edited by ronivay

          @isener said in Forgot password for the webgui:

          and when I ping, I get:
          ping: xo.my-company.net: Name or service not known

          what is wrong?

          There is no DNS record for xo.my-company.net or you canโ€™t resolve it from wherever youโ€™re trying now.

          xo.my-company.net -> which ip address should this be:
          of the xcp-neg server or the server where the xen-orchestar is installed?

          from where to run this command:
          xo-cli --register http://xo.my-company.net/api/admin@admin.net
          the xcp-neg server or the server where the xen-orchestar is installed?

          Answer to both would be where XO is installed.

          @isener said in Forgot password for the webgui:

          I read somewhere that yiu have to use this command in CLI
          xo-server-recover-account youremail@here.com

          but how to install CLI?

          This does not mean you need xo-cli installed. CLI refers to just active shell to your XOA VM, via console or ssh. Just run the command in the shell. If you have XO from sources, there's no such command alias and you need to run the script directly from where your XO is installed, like <installdir>/packages/xo-server/dist/recover-account-cli.mjs

          I 1 Reply Last reply Reply Quote 1
          • I Offline
            isener @ronivay
            last edited by

            @ronivay
            how to sun the script?
            when I run:
            locate recover-account-cli.mjs
            I get
            /opt/xo/xo-builds/xen-orchestra-202207101640/packages/xo-server/dist/recover-account-cli.mjs
            /opt/xo/xo-builds/xen-orchestra-202207101640/packages/xo-server/dist/recover-account-cli.mjs.map
            /opt/xo/xo-builds/xen-orchestra-202207101640/packages/xo-server/src/recover-account-cli.mjs
            /opt/xo/xo-builds/xen-orchestra-202207101726/packages/xo-server/dist/recover-account-cli.mjs
            /opt/xo/xo-builds/xen-orchestra-202207101726/packages/xo-server/dist/recover-account-cli.mjs.map
            /opt/xo/xo-builds/xen-orchestra-202207101726/packages/xo-server/src/recover-account-cli.mjs
            /opt/xo/xo-builds/xen-orchestra-202211262158/packages/xo-server/dist/recover-account-cli.mjs
            /opt/xo/xo-builds/xen-orchestra-202211262158/packages/xo-server/dist/recover-account-cli.mjs.map
            /opt/xo/xo-builds/xen-orchestra-202211262158/packages/xo-server/src/recover-account-cli.mjs
            /opt/xo/xo-src/xen-orchestra/packages/xo-server/src/recover-account-cli.mjs

            ronivayR 1 Reply Last reply Reply Quote 0
            • ronivayR Offline
              ronivay Top contributor @isener
              last edited by

              @isener just run /opt/xo/xo-server/dist/recover-account-cli.mjs admin@admin.net

              I J 2 Replies Last reply Reply Quote 3
              • I Offline
                isener @ronivay
                last edited by

                @ronivay said in Forgot password for the webgui:

                /opt/xo/xo-server/dist/recover-account-cli.mjs admin@admin.net

                Thanks, it works ๐Ÿ™‚

                DarkbeldinD 1 Reply Last reply Reply Quote 0
                • DarkbeldinD Offline
                  Darkbeldin Vates ๐Ÿช Pro Support Team @isener
                  last edited by

                  @isener FYI you can register the xo-cli with the SSH account of the VM and if you don't have an SSH account you can create one.
                  Follow the doc here: https://xen-orchestra.com/docs/troubleshooting.html#set-or-recover-xoa-vm-password

                  1 Reply Last reply Reply Quote 0
                  • J Offline
                    jonybravo @ronivay
                    last edited by

                    what am I doing wrong? Debian 12, XOA from sources.

                    The recover-account-cli.mjs file is located in the opt/xo/xo-server/dist folder and I still get the error at the end:

                    dir
                    snap XenOrchestraInstallerUpdater
                    root@debian:~# cd opt/xo/xo-server/dist
                    -bash: cd: opt/xo/xo-server/dist: No such file or directory
                    root@debian:~# cd /opt/xo/xo-server/dist
                    root@debian:/opt/xo/xo-server/dist# dir
                    api _moveFirst.mjs.map
                    _asyncMapValues.mjs _normalizeVmNetworks.mjs
                    _asyncMapValues.mjs.map _normalizeVmNetworks.mjs.map
                    cli.mjs _normalizeVmNetworks.test.mjs cli.mjs.map _normalizeVmNetworks.test.mjs.map collection patch.mjs collection.mjs patch.mjs.map collection.mjs.map _pDebounceWithKey.mjs connection.mjs _pDebounceWithKey.mjs.map connection.mjs.map _pDebounceWithKey.test.mjs _creat eNdJsonStream.mjs _pDebounceWithKey.test.mjs.map _createNdJsonStream.mjs.map proxy-console.mjs db-cli.mjs proxy-console.mjs.map db-cli.mjs.map recover-account-cli.mjs _ensureArray.mjs recover-account-cli.mjs.map _ensureArray.mjs.map schemas _ensureArray.test.mjs stream-to-existing-buffer.mjs _ensureArray.test.mjs.map stream-to-existing-buffer.mjs.map _extractIpFromVmNetworks.mjs stream-to-existing-buffer.test.mjs _extractIpFromVmNetworks.m js.map stream-to-existing-buffer.test.mjs.map fatfs-buffer.mjs utils.mjs fatfs-buffer.mjs.map utils.mjs.map glob-matcher.mjs utils.test.mjs glob-matcher.mjs.map utils.test.mjs.map _handleBackupLog.mjs _waitAll.mjs _handleBackupLog.mjs.map _waitAll.mjs.map index.mjs xapi index.mjs.map xapi-object-to-xo.mjs logs-cli.mjs xapi-object-to-xo.mjs.map logs-cli.mj s.map xapi-stats.mjs math.mjs xapi-stats.mjs.map math.mjs.map _XenStore.mjs math.test.mjs _XenStore.mjs.map math.test.mjs.map xo-mixins models xo.mjs _moveFirst.mjs xo.mjs.map
                    root@debian:/opt/xo/xo-server/dist# cli.mjs --help
                    -bash: cli.mjs: command not found
                    root@debian:/opt/xo/xo-server/dist# cli.mjs
                    -bash: cli.mjs: command not found
                    root@debian:/opt/xo/xo-server/dist# recover-account-cli.mjs admin@admin.net
                    -bash: recover-account-cli.mjs: command not found
                    root@debian:/opt/xo/xo-server/dist#

                    1 Reply Last reply Reply Quote 0
                    • P Offline
                      peder
                      last edited by

                      To run a command in the current directory you have to prepend it with ./
                      So try ./recover-account-cli.mjs

                      J 1 Reply Last reply Reply Quote 1
                      • J Offline
                        jonybravo @peder
                        last edited by

                        @peder Thanks, it works ๐Ÿ‘

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