Hi all, I'm a newbie here, and have been working on setting up a Koha git environment. The kohadevbox project looked good, so I gave it a try just now. The provisioning went fine until the koha-create step: fatal: [jessie]: FAILED! => {"changed": true, "cmd": "koha-create --create-db kohadev", "delta": "0:00:06.582852", "end": "2017-02-01 20:02:32.211551", "failed": true, "rc": 1, "start": "2017-02-01 20:02:25.628699", "stderr": "", "stdout": "Koha instance is empty, no staff user created.\nStarting Zebra server for kohadev", "stdout_lines": ["Koha instance is empty, no staff user created.", "Starting Zebra server for kohadev"], "warnings": []} I ssh'd into the VM and tried removing the kohadev instance and recreating it by hand, and it appears that koha-create returns a non-zero status, even though it appears to have been successful: vagrant@kohadevbox:~$ sudo /usr/sbin/koha-create --create-db kohadev Koha instance is empty, no staff user created. Starting Zebra server for kohadev vagrant@kohadevbox:~$ echo $? 1 vagrant@kohadevbox:~$ Is there some way I can get vagrant to ignore the non-zero result from koha-create, and restart the provisioning at the point where it left off? Thanks in advance!
Hello Mark and welcome ;) kohadevbox could be very usefu for developing and testing purposes, for sure. Just try to run vagrant up --provision it should continue in provision process regards Josef st 1. 2. 2017 v 21:40 odesílatel Mark Alexander <marka@pobox.com> napsal: Hi all, I'm a newbie here, and have been working on setting up a Koha git environment. The kohadevbox project looked good, so I gave it a try just now. The provisioning went fine until the koha-create step: fatal: [jessie]: FAILED! => {"changed": true, "cmd": "koha-create --create-db kohadev", "delta": "0:00:06.582852", "end": "2017-02-01 20:02:32.211551", "failed": true, "rc": 1, "start": "2017-02-01 20:02:25.628699", "stderr": "", "stdout": "Koha instance is empty, no staff user created.\nStarting Zebra server for kohadev", "stdout_lines": ["Koha instance is empty, no staff user created.", "Starting Zebra server for kohadev"], "warnings": []} I ssh'd into the VM and tried removing the kohadev instance and recreating it by hand, and it appears that koha-create returns a non-zero status, even though it appears to have been successful: vagrant@kohadevbox:~$ sudo /usr/sbin/koha-create --create-db kohadev Koha instance is empty, no staff user created. Starting Zebra server for kohadev vagrant@kohadevbox:~$ echo $? 1 vagrant@kohadevbox:~$ Is there some way I can get vagrant to ignore the non-zero result from koha-create, and restart the provisioning at the point where it left off? Thanks in advance! _______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
Excerpts from Josef Moravec's message of 2017-02-01 22:47:55 +0000:
Just try to run
vagrant up --provision
Thanks. I tried that and it the system is now in a worse state with a half-installed koha-common package. There was an error in the installation of koha-common: ... Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ...", "dpkg: error processing package koha-common (--configure):", " subprocess installed post-installation script returned error exit status 1", "Errors were encountered while processing:", " koha-common[} I tried configuring the half-installed koha-common manually via ssh, in an attempt to figure out what went wrong (see below). It's a bit too much for me to understand right now. I'll wait a week and try to start from scratch again. vagrant@kohadevbox:~$ sudo apt-get dist-upgrade Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 1 not fully installed or removed. After this operation, 0 B of additional disk space will be used. Do you want to continue? [Y/n] y Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ... dpkg: error processing package koha-common (--configure): subprocess installed post-installation script returned error exit status 1 Errors were encountered while processing: koha-common E: Sub-process /usr/bin/dpkg returned an error code (1) vagrant@kohadevbox:log$ sudo dpkg --configure -D377 koha-common D000001: ensure_diversions: new, (re)loading D000001: process queue pkg koha-common:all queue.len 0 progress 1, try 1 D000040: checking dependencies of koha-common:all (- <none>) D000040: ok 2 msgs >><< D000040: checking Breaks Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ... D000002: fork/exec /var/lib/dpkg/info/koha-common.postinst ( configure 16.12.01~git+20170201001109.692ea16f ) dpkg: error processing package koha-common (--configure): subprocess installed post-installation script returned error exit status 1 D000001: ensure_diversions: same, skipping Errors were encountered while processing: koha-common vagrant@kohadevbox:log$ sudo /var/lib/dpkg/info/koha-common.postinst Use of uninitialized value $action in string eq at /usr/share/debconf/frontend line 27.
Did you try to destroy it then create a new one from scratch? :) On Thu, 2 Feb 2017 at 02:08 Mark Alexander <marka@pobox.com> wrote:
Excerpts from Josef Moravec's message of 2017-02-01 22:47:55 +0000:
Just try to run
vagrant up --provision
Thanks. I tried that and it the system is now in a worse state with a half-installed koha-common package. There was an error in the installation of koha-common:
... Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ...", "dpkg: error processing package koha-common (--configure):", " subprocess installed post-installation script returned error exit status 1", "Errors were encountered while processing:", " koha-common[}
I tried configuring the half-installed koha-common manually via ssh, in an attempt to figure out what went wrong (see below). It's a bit too much for me to understand right now. I'll wait a week and try to start from scratch again.
vagrant@kohadevbox:~$ sudo apt-get dist-upgrade Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 1 not fully installed or removed. After this operation, 0 B of additional disk space will be used. Do you want to continue? [Y/n] y Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ... dpkg: error processing package koha-common (--configure): subprocess installed post-installation script returned error exit status 1 Errors were encountered while processing: koha-common E: Sub-process /usr/bin/dpkg returned an error code (1) vagrant@kohadevbox:log$ sudo dpkg --configure -D377 koha-common D000001: ensure_diversions: new, (re)loading D000001: process queue pkg koha-common:all queue.len 0 progress 1, try 1 D000040: checking dependencies of koha-common:all (- <none>) D000040: ok 2 msgs >><< D000040: checking Breaks Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ... D000002: fork/exec /var/lib/dpkg/info/koha-common.postinst ( configure 16.12.01~git+20170201001109.692ea16f ) dpkg: error processing package koha-common (--configure): subprocess installed post-installation script returned error exit status 1 D000001: ensure_diversions: same, skipping Errors were encountered while processing: koha-common vagrant@kohadevbox:log$ sudo /var/lib/dpkg/info/koha-common.postinst Use of uninitialized value $action in string eq at /usr/share/debconf/frontend line 27. _______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
This is due to recent changes on koha-* scripts. I'll try to fix it today. Once it fails on the instance creation you need to run $ vagrant provision And you will be fine. The instance is correctly created, but the exit status of the koha-create command seems to say otherwise. Regards El jue., 2 de feb. de 2017 5:40 AM, Jonathan Druart < jonathan.druart@bugs.koha-community.org> escribió:
Did you try to destroy it then create a new one from scratch? :)
On Thu, 2 Feb 2017 at 02:08 Mark Alexander <marka@pobox.com> wrote:
Excerpts from Josef Moravec's message of 2017-02-01 22:47:55 +0000:
Just try to run
vagrant up --provision
Thanks. I tried that and it the system is now in a worse state with a half-installed koha-common package. There was an error in the installation of koha-common:
... Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ...", "dpkg: error processing package koha-common (--configure):", " subprocess installed post-installation script returned error exit status 1", "Errors were encountered while processing:", " koha-common[}
I tried configuring the half-installed koha-common manually via ssh, in an attempt to figure out what went wrong (see below). It's a bit too much for me to understand right now. I'll wait a week and try to start from scratch again.
vagrant@kohadevbox:~$ sudo apt-get dist-upgrade Reading package lists... Done Building dependency tree Reading state information... Done Calculating upgrade... Done 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 1 not fully installed or removed. After this operation, 0 B of additional disk space will be used. Do you want to continue? [Y/n] y Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ... dpkg: error processing package koha-common (--configure): subprocess installed post-installation script returned error exit status 1 Errors were encountered while processing: koha-common E: Sub-process /usr/bin/dpkg returned an error code (1) vagrant@kohadevbox:log$ sudo dpkg --configure -D377 koha-common D000001: ensure_diversions: new, (re)loading D000001: process queue pkg koha-common:all queue.len 0 progress 1, try 1 D000040: checking dependencies of koha-common:all (- <none>) D000040: ok 2 msgs >><< D000040: checking Breaks Setting up koha-common (16.12.01~git+20170202001109.c65a151f) ... D000002: fork/exec /var/lib/dpkg/info/koha-common.postinst ( configure 16.12.01~git+20170201001109.692ea16f ) dpkg: error processing package koha-common (--configure): subprocess installed post-installation script returned error exit status 1 D000001: ensure_diversions: same, skipping Errors were encountered while processing: koha-common vagrant@kohadevbox:log$ sudo /var/lib/dpkg/info/koha-common.postinst Use of uninitialized value $action in string eq at /usr/share/debconf/frontend line 27. _______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
_______________________________________________ Koha-devel mailing list Koha-devel@lists.koha-community.org http://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-devel website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
-- Tomás Cohen Arazi Theke Solutions (https://theke.io <http://theke.io/>) ✆ +54 9351 3513384 GPG: B2F3C15F
Excerpts from Tomas Cohen Arazi's message of 2017-02-02 10:23:09 +0000:
This is due to recent changes on koha-* scripts. I'll try to fix it today.
Thanks, it seems better now. I decided to start over from scratch because the koha-common package somehow got into a broken, half-installed state that I was unable to fix. I reproduced the provision steps manually in a fresh Jessie VM, so that I could take snapshots of the VM for disaster recovery, and to see exactly where failures might occur. Things went much better this time: I was able to get a gitified Koha installation up and running. But things failed when I tried to start plack using koha-plack. The failure occurred in adjust_paths_dev_install(), in /usr/share/koha/bin/koha-functions.sh, at this line: dev_install=$(xmlstarlet sel -t -v 'yazgfs/config/dev_install' /etc/koha/sites/$instancename/koha-conf.xml) There is no dev_install in my copy of koha-conf.xml, so xmlstarlet returned a non-zero exit status. Because koha-plack has a "set -e" at the top, the script exited immediately and did not start plack.
Try updating yo kohadevbox code $ git pull And recreating. I've manually added <dev_install> to kohadevbox. See my email to the list. El dom., 5 de feb. de 2017 10:04 AM, Mark Alexander <marka@pobox.com> escribió:
Excerpts from Tomas Cohen Arazi's message of 2017-02-02 10:23:09 +0000:
This is due to recent changes on koha-* scripts. I'll try to fix it today.
Thanks, it seems better now.
I decided to start over from scratch because the koha-common package somehow got into a broken, half-installed state that I was unable to fix.
I reproduced the provision steps manually in a fresh Jessie VM, so that I could take snapshots of the VM for disaster recovery, and to see exactly where failures might occur. Things went much better this time: I was able to get a gitified Koha installation up and running.
But things failed when I tried to start plack using koha-plack. The failure occurred in adjust_paths_dev_install(), in /usr/share/koha/bin/koha-functions.sh, at this line:
dev_install=$(xmlstarlet sel -t -v 'yazgfs/config/dev_install' /etc/koha/sites/$instancename/koha-conf.xml)
There is no dev_install in my copy of koha-conf.xml, so xmlstarlet returned a non-zero exit status. Because koha-plack has a "set -e" at the top, the script exited immediately and did not start plack.
-- Tomás Cohen Arazi Theke Solutions (https://theke.io <http://theke.io/>) ✆ +54 9351 3513384 GPG: B2F3C15F
participants (4)
-
Jonathan Druart -
Josef Moravec -
Mark Alexander -
Tomas Cohen Arazi