diff options
| author | Alan Conway <aconway@apache.org> | 2014-04-28 20:21:11 +0000 |
|---|---|---|
| committer | Alan Conway <aconway@apache.org> | 2014-04-28 20:21:11 +0000 |
| commit | 5d7077d9b82b60a7fb5b95b4cd2393b15a6a7085 (patch) | |
| tree | bab1dd53de710c8cc6d27b3a3b0d5132017fc98d /qpid/cpp | |
| parent | 6125de2e1aa8779d7fd1e59f378ce0a2225d453f (diff) | |
| download | qpid-python-5d7077d9b82b60a7fb5b95b4cd2393b15a6a7085.tar.gz | |
QPID-5719: Fix unintentional dependency on qpid-ha for non-HA installations.
qpidd init script should not use qpid-ha if it is not installed.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@1590777 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'qpid/cpp')
| -rwxr-xr-x | qpid/cpp/etc/qpidd.in | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/qpid/cpp/etc/qpidd.in b/qpid/cpp/etc/qpidd.in index 7db59e369f..b5416668ba 100755 --- a/qpid/cpp/etc/qpidd.in +++ b/qpid/cpp/etc/qpidd.in @@ -51,11 +51,16 @@ test -f @sysconfdir@/sysconfig/$prog && source @sysconfdir@/sysconfig/$prog source /etc/rc.d/init.d/functions # Check presence of executables/scripts -for f in $QPID_BIN $QPID_HA; do +for f in $QPID_BIN; do test -x $f || { echo "$f not found or not executable"; exit 5; } done -QPID_HA="$QPID_HA $QPID_HA_OPTIONS" +qpid_ping() { + # Only do ping test if qpid-ha is installed. + if test -x $QPID_HA; then + $QPID_HA $QPID_HA_OPTIONS ping + fi +} RETVAL=0 @@ -68,7 +73,7 @@ fi do_status() { # Check PID file and ping for liveness - status $prog && $QPID_HA ping + status $prog && $qpid_ping } start() { |
