koha-start-zebra pbuilder Starting Zebra server for pbuilder build@vps181114:~$ ps aux | grep zebra 1002 6894 0.0 0.0 20000 552 ? S 15:41 0:00 daemon --name=pbuilder-koha-zebra --pidfiles=/var/run/koha/pbuilder/ --errlog=/var/log/koha/pbuilder/zebra-error.log --stdout=/var/log/koha/pbuilder/zebra.log --output=/var/log/koha/pbuilder/zebra-output.log --verbose=1 --respawn --delay=30 --user=pbuilder-koha.pbuilder-koha -- zebrasrv -v none,fatal,warn -f /etc/koha/sites/pbuilder/koha-conf.xml 1002 6895 0.3 0.4 104320 4724 ? S 15:41 0:00 zebrasrv -v none,fatal,warn -f /etc/koha/sites/pbuilder/koha-conf.xml koha-stop-zebra pbuilder Zebra already stopped for instance pbuilder. ps aux | grep zebra 1002 6894 0.0 0.0 20000 552 ? S 15:41 0:00 daemon --name=pbuilder-koha-zebra --pidfiles=/var/run/koha/pbuilder/ --errlog=/var/log/koha/pbuilder/zebra-error.log --stdout=/var/log/koha/pbuilder/zebra.log --output=/var/log/koha/pbuilder/zebra-output.log --verbose=1 --respawn --delay=30 --user=pbuilder-koha.pbuilder-koha -- zebrasrv -v none,fatal,warn -f /etc/koha/sites/pbuilder/koha-conf.xml 1002 6895 0.0 0.4 104320 4724 ? S 15:41 0:00 zebrasrv -v none,fatal,warn -f /etc/koha/sites/pbuilder/koha-conf.xml build 6944 0.0 0.0 11480 948 pts/0 S+ 15:46 0:00 grep zebra
This also has the effect that other commands do not work. If I disable and delete an instance, the user is still in use (running daemon and zebrasrv), can't be deleted, the dead conf symlink remains in /etc/apache2/sites-enabled, apache goes crazy over it and tells me to install stuff, zombie apocalypse starts and it all has to be cleaned up manually.
Looks like the check is_zebra_running does not work.
daemon --name="koha-koha-zebra" --user="koha-koha.koha-koha" --running in the command line does not give me any feedback, regardless of the actual state. Should it?
Created attachment 40705 [details] [review] Bug 14466 -- is_zebra_running in koha-functions.sh is broken is_zebra_running is broken, so koha-stop-zebra is broken too. daemon needs the --pidfiles if given at start, and the --running argumen has to be used before that. Beware that the path to koha-functions.sh in the koha- scripts is hardcoded for package installations (/usr/share…), so you need to change it to match koha-functions.sh in your dev environment to test this patch. Test plan: - Use koha-stop-zebra with an instance that has a running zebra. It will tell you that zebra was already stopped. - ps aux | grep zebra to see that is not true - Apply patch. Modify koha-stop-zebra to use /your/devpath/debian/scripts/koha-functions.sh - Use koha-stop-zebra. You will be told zebra is stopped now for your instance - ps aux | grep zebra to verify it is gone
Small addition to the test plan: - Use koha-stop-zebra again. You will now (correctly) be told that zebra is already stopped for your instance.
Would be nice if this could go into 3.18 too.
(In reply to Mirko Tietgen from comment #3) > daemon --name="koha-koha-zebra" --user="koha-koha.koha-koha" --running > > in the command line does not give me any feedback, regardless of the actual > state. Should it? It does with --verbose, btw.
(In reply to Mirko Tietgen from comment #3) > daemon --name="koha-koha-zebra" --user="koha-koha.koha-koha" --running > > in the command line does not give me any feedback, regardless of the actual > state. Should it? Perhaps check "echo $?" (without the double quotes)?
(In reply to Mirko Tietgen from comment #0) > ps aux | grep zebra > 1002 6894 0.0 0.0 20000 552 ? S 15:41 0:00 daemon > --name=pbuilder-koha-zebra --pidfiles=/var/run/koha/pbuilder/ > --errlog=/var/log/koha/pbuilder/zebra-error.log > --stdout=/var/log/koha/pbuilder/zebra.log > --output=/var/log/koha/pbuilder/zebra-output.log --verbose=1 --respawn > --delay=30 --user=pbuilder-koha.pbuilder-koha -- zebrasrv -v none,fatal,warn > -f /etc/koha/sites/pbuilder/koha-conf.xml > 1002 6895 0.0 0.4 104320 4724 ? S 15:41 0:00 zebrasrv -v > none,fatal,warn -f /etc/koha/sites/pbuilder/koha-conf.xml > build 6944 0.0 0.0 11480 948 pts/0 S+ 15:46 0:00 grep zebra When did --pidfiles get added? It's not in 3.14.x or 3.16.x as far as I know.
*** This bug has been marked as a duplicate of bug 14361 ***