Bug 16885: koha-stop-zebra should be more sure of stopping zebrasrv
authorMark Tompsett <mtompset@hotmail.com>
Wed, 3 Aug 2016 03:26:03 +0000 (23:26 -0400)
committerFrédéric Demians <f.demians@tamil.fr>
Tue, 23 Aug 2016 10:29:54 +0000 (12:29 +0200)
commit16769bdb1445bcccd3be0221ba69917344f363e9
treea87fa2070397cfdcf7115f3047341b707e2ba840
parent3b4564001d571304490fe81dbd92e656fc9ad53e
Bug 16885: koha-stop-zebra should be more sure of stopping zebrasrv

This patch follows Galen's suggestion in comment #7.

TEST PLAN
---------
1) Back up your koha logs as desired.
2) add something to /var/log/koha/{instance name}/intranet-error.log
3) ps aux | grep zebra
4) logrotate -f /etc/logrotate.d/koha-common
5) ps aux | grep zebra
   -- the zebrasrv and daemon process for zebra indexing
      didn't restart.
6) apply this patch against /usr/sbin/koha-stop-zebra
7) sudo koha-start-zebra {instance name}
8) ps aux | grep zebra
   -- the processes should have started up again.
9) add different junk to /var/log/koha/{instance name}/intranet-error.log
10) ps aux | grep zebra
11) logrotate -f /etc/logrotate.d/koha-common
12) ps aux | grep zebra
    -- the process ids for the zebrasrv and daemon processes should
       be different, but the number of processes is the same as before.
13) sign off, because its less ugly than comment #3

Sponsored-by: Tulong Aklatan
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Works as expected, no regressions found.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
(cherry picked from commit ac4a058b05fc1a1a6955d025328cca6ae369baeb)
Signed-off-by: Frédéric Demians <f.demians@tamil.fr>
debian/scripts/koha-stop-zebra