From d2f17d76bd3e45db502206049b7b2cc6b00a68b1c7870224f87d272b4da82a28 Mon Sep 17 00:00:00 2001 From: Stephan Kulow Date: Sun, 27 Sep 2015 06:40:21 +0000 Subject: [PATCH] Accepting request 333662 from server:http fix haproxy status checks (bsc#947204) OBS-URL: https://build.opensuse.org/request/show/333662 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/haproxy?expand=0&rev=33 --- haproxy.changes | 5 +++++ haproxy.init | 15 ++++++++------- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/haproxy.changes b/haproxy.changes index a361a7b..9f30cbb 100644 --- a/haproxy.changes +++ b/haproxy.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Sep 23 19:26:54 UTC 2015 - dmueller@suse.com + +- fix haproxy status checks (bsc#947204) + ------------------------------------------------------------------- Tue Sep 8 09:10:02 UTC 2015 - kgronlund@suse.com diff --git a/haproxy.init b/haproxy.init index 748927e..6fea7c6 100644 --- a/haproxy.init +++ b/haproxy.init @@ -205,12 +205,13 @@ case "$1" in rc_status -v ;; reload|force-reload) - if checkproc -p $HAPROXY_PID $HAPROXY_BIN; then - haproxy_check - echo -n "Reload service haproxy " - $HAPROXY_BIN -p $HAPROXY_PID -D -f $HAPROXY_CONF -sf $(cat $HAPROXY_PID) - rc_status -v - fi + ## Like force-reload, but if daemon does not support + ## signaling, do nothing (!) + haproxy_check + # If it supports signaling: + echo -n "Reload service haproxy " + $HAPROXY_BIN -p $HAPROXY_PID -D -f $HAPROXY_CONF -sf $(cat $HAPROXY_PID) + rc_status -v ;; status) echo -n "Checking for service haproxy " @@ -226,7 +227,7 @@ case "$1" in # 5--199 reserved (5--99 LSB, 100--149 distro, 150--199 appl.) # NOTE: checkproc returns LSB compliant status values. - /sbin/checkproc $HAPROXY_BIN + /sbin/checkproc -p $HAPROXY_PID $HAPROXY_BIN # NOTE: rc_status knows that we called this init script with # "status" option and adapts its messages accordingly. rc_status -v