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

    Tips on installing XO

    Scheduled Pinned Locked Moved Xen Orchestra
    97 Posts 11 Posters 19.6k Views 9 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.
    • olivierlambertO Offline
      olivierlambert Vates đŸȘ Co-Founder CEO @jasonnix
      last edited by

      @jasonnix No. You can rely on a non-root install with a regular Linux users, with enough permissions to deal with "usually restricted" features by default.

      J 1 Reply Last reply Reply Quote 0
      • J Offline
        jasonnix @olivierlambert
        last edited by jasonnix

        Hi @olivierlambert,
        What is meant by enough permissions? If I want to clone XO under the /usr/local/src, then I need the root permission!
        If I use the root account to install, will there be a problem?
        I tried to clone the XO several times, but I got the following error:

        # git clone -b master https://github.com/vatesfr/xen-orchestra.git
        Cloning into 'xen-orchestra'...
        remote: Enumerating objects: 122975, done.
        remote: Counting objects: 100% (2950/2950), done.
        remote: Compressing objects: 100% (1307/1307), done.
        error: 1124 bytes of body are still expected MiB | 162.00 KiB/s 
        fetch-pack: unexpected disconnect while reading sideband packet
        fatal: early EOF
        fatal: fetch-pack: invalid index-pack output
        

        What is wrong?

        J 1 Reply Last reply Reply Quote 0
        • J Offline
          john.c @jasonnix
          last edited by john.c

          @jasonnix The Linux distribution operating system restricts certain commands, operations and/or path (location) to the root account, as well as the location owner.

          The path your trying to write to is just one such location as the location is read only to non-root users. If you really wish to write to /usr/local/src then root account is required.

          If you use the root account to install then the directory and the Xen Orchestra files will be owner by root. You would need to create a non-root user for the xen orchestra server process. As well as change ownership of the Xen Orchestra files and folders to that non-root account. Though at least the ones which Xen Orchestra should be able to modify as required, when needed.

          As well as provide the necessary sudo permissions for the necessary commands to that account.

          Using root account to run exposes any vulnerabilities present to the capacity of being exploited as root (aka Administrator) privileges.

          Also how good is your internet connection and your connection to GitHub? Cause you could be experiencing a time out packet loss connection issue.

          J 1 Reply Last reply Reply Quote 2
          • J Offline
            jasonnix @john.c
            last edited by jasonnix

            Hello @john-c,
            Thank you so much for your advices.
            1- I had used the root account for this, so there is no permission issue. Now, I realized that root account is not suitable for this. Which directory is suitable for cloning?

            2- Is there a problem if I download the file from Github as a zip file and install it?

            1 Reply Last reply Reply Quote 0
            • olivierlambertO Offline
              olivierlambert Vates đŸȘ Co-Founder CEO
              last edited by

              1. You can but it's less convenient.

              b35e4ba6-15a6-405e-8beb-e55309c4f1c2-image.png

              J 1 Reply Last reply Reply Quote 1
              • J Offline
                john.c @olivierlambert
                last edited by john.c

                @olivierlambert said in Tips on installing XO:

                1. You can but it's less convenient.

                b35e4ba6-15a6-405e-8beb-e55309c4f1c2-image.png

                As well as more tricky when updated as you will need to create a zip and then re-download it. If however you can clone it especially by the git command then you can use it to update it as needed and/or use other methods to speed it up.

                Additionally you can have a script to update the instance and handle any instances of ownership changes.

                D 1 Reply Last reply Reply Quote 0
                • D Offline
                  DustinB @john.c
                  last edited by

                  @john-c said in Tips on installing XO:

                  @olivierlambert said in Tips on installing XO:

                  1. You can but it's less convenient.

                  b35e4ba6-15a6-405e-8beb-e55309c4f1c2-image.png

                  As well as more tricky when updated as you will need to create a zip and then re-download it. If however you can clone it especially by the git command then you can use it to update it as needed and/or use other methods to speed it up.

                  Additionally you can have a script to update the instance and handle any instances of ownership changes.

                  That seems like an insane way to install and update this XO.

                  1 Reply Last reply Reply Quote 0
                  • J Offline
                    jasonnix
                    last edited by

                    Hello,
                    You said that I should not do the installation with the root account, which directory is suitable for cloning?

                    Cheers.

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

                      Hello,
                      No idea?

                      Cheers.

                      lawrencesystemsL 1 Reply Last reply Reply Quote 0
                      • lawrencesystemsL Offline
                        lawrencesystems Ambassador @jasonnix
                        last edited by

                        @jasonnix

                        I have. a tutorial here on how to build from sources using https://github.com/ronivay/XenOrchestraInstallerUpdater which can be done using a sudo user.

                        https://youtu.be/fuS7tSOxcSo

                        J 1 Reply Last reply Reply Quote 0
                        • J Offline
                          jasonnix @lawrencesystems
                          last edited by

                          Hi @lawrencesystems,
                          Some people said that I should not use the root account. Which directory is suitable for cloning?

                          lawrencesystemsL 1 Reply Last reply Reply Quote 0
                          • lawrencesystemsL Offline
                            lawrencesystems Ambassador @jasonnix
                            last edited by

                            @jasonnix

                            use an account that is in the sudo list.

                            J 1 Reply Last reply Reply Quote 0
                            • J Offline
                              jasonnix @lawrencesystems
                              last edited by

                              Thanks @lawrencesystems.
                              If I want to clone it manually, then which directory is OK? For example, "/home", "/tmp", etc.

                              lawrencesystemsL 1 Reply Last reply Reply Quote 0
                              • lawrencesystemsL Offline
                                lawrencesystems Ambassador @jasonnix
                                last edited by

                                @jasonnix

                                If you are going to do it manually then choose whatever you want, but /tmp might not make much sense to put something important.

                                J 1 Reply Last reply Reply Quote 0
                                • J Offline
                                  jasonnix @lawrencesystems
                                  last edited by jasonnix

                                  Hi @lawrencesystems,
                                  Thanks again.
                                  I want to clone XO under the /usr/local/src directory, but this directory requires root access. Is there a problem if I do this with the sudo command?

                                  E D 2 Replies Last reply Reply Quote 0
                                  • E Offline
                                    ElemondCraw @jasonnix
                                    last edited by

                                    @jasonnix There is a paragraph about sudo in the install : https://xen-orchestra.com/docs/installation.html#sudo

                                    1 Reply Last reply Reply Quote 0
                                    • D Offline
                                      DustinB @jasonnix
                                      last edited by

                                      @jasonnix said in Tips on installing XO:

                                      Hi @lawrencesystems,
                                      Thanks again.
                                      I want to clone XO under the /usr/local/src directory, but this directory requires root access. Is there a problem if I do this with the sudo command?

                                      At this point I'm not sure if its intentional idiocy or not. Xen Orchestra does not get installed within XCP-ng's Dom0, it can be installed as a VM that is running as a guest on XCP-ng or on a separate environment entirely.

                                      Read the documentation, install Ubuntu or Debian and then you install XO as an application on that system.

                                      1 Reply Last reply Reply Quote 0
                                      • J Offline
                                        jasonnix
                                        last edited by

                                        Hello,
                                        I tried to install XO, but I got the following error:

                                        $ sudo yarn
                                        yarn install v1.22.21
                                        [1/5] Validating package.json...
                                        [2/5] Resolving packages...
                                        [3/5] Fetching packages...
                                        error https://registry.yarnpkg.com/react-sparklines/-/react-sparklines-1.6.0.tgz: Extracting tar content of undefined failed, the file appears to be corrupt: "ENOSPC: no space left on device, write"
                                        info Visit https://yarnpkg.com/en/docs/cli/install for documentation about this command.
                                        

                                        I have enough disk space:

                                        $ sudo df -i
                                        Filesystem     Inodes  IUsed  IFree IUse% Mounted on
                                        udev           492266    395 491871    1% /dev
                                        tmpfs          497999    589 497410    1% /run
                                        /dev/xvda1     238560 139439  99121   59% /
                                        tmpfs          497999      1 497998    1% /dev/shm
                                        tmpfs          497999      3 497996    1% /run/lock
                                        /dev/xvda6     354816  20966 333850    6% /home
                                        tmpfs           99599     14  99585    1% /run/user/0
                                        tmpfs           99599     19  99580    1% /run/user/1000
                                        $
                                        $ sudo lsblk
                                        NAME    MAJ:MIN RM  SIZE RO TYPE MOUNTPOINTS
                                        sr0      11:0    1   16M  0 rom  
                                        xvda    202:0    0   10G  0 disk 
                                        ├─xvda1 202:1    0  3.6G  0 part /
                                        ├─xvda2 202:2    0    1K  0 part 
                                        ├─xvda5 202:5    0  976M  0 part [SWAP]
                                        └─xvda6 202:6    0  5.4G  0 part /home
                                        

                                        Any idea?

                                        AtaxyaNetworkA 1 Reply Last reply Reply Quote 0
                                        • AtaxyaNetworkA Offline
                                          AtaxyaNetwork Ambassador @jasonnix
                                          last edited by

                                          @jasonnix Hi !

                                          Can you do a df -h instead of -i ?

                                          J 1 Reply Last reply Reply Quote 0
                                          • J Offline
                                            jasonnix @AtaxyaNetwork
                                            last edited by jasonnix

                                            Hi @AtaxyaNetwork,
                                            I did:

                                            $ sudo df -h
                                            Filesystem      Size  Used Avail Use% Mounted on
                                            udev            1.9G     0  1.9G   0% /dev
                                            tmpfs           390M  564K  389M   1% /run
                                            /dev/xvda1      3.6G  3.5G     0 100% /
                                            tmpfs           1.9G     0  1.9G   0% /dev/shm
                                            tmpfs           5.0M     0  5.0M   0% /run/lock
                                            /dev/xvda6      5.3G  247M  4.8G   5% /home
                                            tmpfs           390M     0  390M   0% /run/user/0
                                            tmpfs           390M     0  390M   0% /run/user/1000
                                            
                                            

                                            Disk is full!

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