[Koha-bugs] [Bug 30684] koha-* scripts --restart should start even when not running

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Wed Aug 17 14:00:21 CEST 2022


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=30684

--- Comment #29 from Alex Buckley <alexbuckley at catalyst.net.nz> ---
(In reply to Jonathan Druart from comment #28)
> Why did you replace log_daemon_msg with echo?

My apologies Jonathan. I replaced log_daemon_msg with echo because I went
through all 6 scripts and found it wasn't just koha-sip where the output was
not split over multiple lines.

For example, with only the first patch applied (i.e. log_daemon_msg being used)
koha-plack gives this output:

vagrant at kohadevbox:kohaclone((0e08cf28f57...))$ sudo koha-plack --restart
kohadev
[ ok ] Plack not running for kohadev.:[....] Starting Plack daemon for
kohadev:.

---

With the second patch applied (i.e. echo being used) the koha-plack gives this
output correctly split over two lines:

vagrant at kohadevbox:scripts((69bb9e5e337...))$ sudo koha-plack --restart kohadev
Plack not running for kohadev.
[ ok ] Starting Plack daemon for kohadev:.

---

I attempted keeping log_daemon_msg, and adding a newline character \n to the
end (log_daemon_msg "Plack not running for ${instancename}.\n"), however, the
newline character was not interpreted correctly, see below:

vagrant at kohadevbox:kohaclone((69bb9e5e337...))$ sudo koha-plack --restart
kohadev
[ ok ] Plack not running for kohadev.\n:[....] Starting Plack daemon for
kohadev:.

Likely, there is some way for the \n character to be correctly interpreted by
log_daemon_msg, I could not find how though - do you know how to do that?

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list