ronivay / XenOrchestraInstallerUpdater

Xen Orchestra install/update script
GNU General Public License v3.0
1.14k stars 189 forks source link

Local changes in this script directory. Not attempting to self upgrade #190

Closed JoneKone closed 11 months ago

JoneKone commented 11 months ago

Debian 11

Server specs 1 cpu 96GB memory

Issue First time tried to update. [fail] Local changes in this script directory. Not attempting to self upgrade

@orkesteri:~/Git/XenOrchestraInstallerUpdater$ sudo ./xo-install.sh update
[sudo] password for : 
[fail] Local changes in this script directory. Not attempting to self upgrade
@orkesteri:~/Git/XenOrchestraInstallerUpdater$ git pull
hint: Pulling without specifying how to reconcile divergent branches is
hint: discouraged. You can squelch this message by running one of the following
hint: commands sometime before your next pull:
hint: 
hint:   git config pull.rebase false  # merge (the default strategy)
hint:   git config pull.rebase true   # rebase
hint:   git config pull.ff only       # fast-forward only
hint: 
hint: You can replace "git config" with "git config --global" to set a default
hint: preference for all repositories. You can also pass --rebase, --no-rebase,
hint: or --ff-only on the command line to override the configured default per
hint: invocation.
remote: Enumerating objects: 10, done.
remote: Counting objects: 100% (10/10), done.
remote: Compressing objects: 100% (3/3), done.
remote: Total 7 (delta 4), reused 6 (delta 4), pack-reused 0
Unpacking objects: 100% (7/7), 1.19 KiB | 35.00 KiB/s, done.
From https://github.com/ronivay/XenOrchestraInstallerUpdater
   eff60cc..dd2ea64  master     -> origin/master
Updating eff60cc..dd2ea64
Fast-forward
 README.md     |  1 +
 xo-install.sh | 10 +++++-----
 2 files changed, 6 insertions(+), 5 deletions(-)
@orkesteri:~/Git/XenOrchestraInstallerUpdater$ sudo ./xo-install.sh update
[fail] Local changes in this script directory. Not attempting to self upgrade
@orkesteri:~/Git/XenOrchestraInstallerUpdater$ ls
LICENSE  README.md  logs  sample.xo-install.cfg  xo-install.cfg  xo-install.sh  xo-vm-import.sh

Installation logfile

+ command -v git
/usr/bin/git
+ cd . && git config --get remote.origin.url
https://github.com/ronivay/XenOrchestraInstallerUpdater.git
+ cd . && git status --porcelain
 M sample.xo-install.cfg
Running script version eff60cc with config:

PORT="80"
INSTALLDIR="/opt/xo"
SELFUPGRADE=true
CONFIGUPDATE=true
REPOSITORY="https://github.com/vatesfr/xen-orchestra"
BRANCH="master"
PLUGINS="all"
AUTOUPDATE="true"
OS_CHECK="true"
ARCH_CHECK="true"
PRESERVE="3"
INSTALL_REPOS="true"

+ id -u
0
+ uname -m
x86_64
+ command -v xe
+ grep ^VERSION_ID /etc/os-release | cut -d'=' -f2 | grep -Eo '[0-9]{1,2}' | head -1
11
+ grep ^NAME /etc/os-release | cut -d'=' -f2 | sed 's/"//g' | awk '{print $1}'
Debian
+ grep ^GRUB_DISTRIBUTOR /etc/default/grub | grep 'Xen Orchestra'
+ command -v yum
+ command -v apt-get
/usr/bin/apt-get
+ command -v systemctl
/usr/bin/systemctl
+ df -P -k '/opt' | tail -1 | awk '{print $4}'
66142872
+ grep MemTotal /proc/meminfo | awk '{print $2}'
16355360

Like I said, my very first update try on this script. The installation if I recall correctly went fine.

ronivay commented 11 months ago

You have local modifications in sample.xo-install.cfg so the script refuses to update. You can see that with git status. git reset --hard will get rid of those changes and auto update should work.

JoneKone commented 11 months ago

thank you :)

git status
On branch master
Your branch is up to date with 'origin/master'.

Changes not staged for commit:
  (use "git add <file>..." to update what will be committed)
  (use "git restore <file>..." to discard changes in working directory)
    modified:   sample.xo-install.cfg

no changes added to commit (use "git add" and/or "git commit -a")

is it normal that the update doesn't give any output?

Ok now I remember what I had to do.. to get orchestra to install in the first place I had to turn a check off so it would install... Don't ask me what =) the check was.. Maybe something about Debian... why it's saying I did the change in sample file is beyond me. I'm pretty sure I changed stuff in the main conf. Maybe the git pull over wrote that.

ronivay commented 11 months ago

is it normal that the update doesn't give any output?

Script self update you mean? Yeah if there's no pending changes to the script itself or no local changes (error) it won't output anything.

Ok now I remember what I had to do.. to get orchestra to install in the first place I had to turn a check off so it would install... Don't ask me what =) the check was.. Maybe something about Debian... why it's saying I did the change in sample file is beyond me. I'm pretty sure I changed stuff in the main conf. Maybe the git pull over wrote that.

Looking at the log, it doesn't seem like you have any modifications been made in the config. Maybe some mistake edit against the sample file, hard to say :)

JoneKone commented 11 months ago

image

Ok this is what is currently online. Thank you for the help.

ronivay commented 11 months ago

image

Ok this is what is currently online. Thank you for the help.

Great. I'll close this one as the root cause was quite clear.