From 9a851525c30a4bdb522e64301268c9ef2188ae83 Mon Sep 17 00:00:00 2001 From: fmherschel Date: Mon, 9 Aug 2021 11:57:22 +0200 Subject: [PATCH] SAPInstance: Fix for issue #1680 - SAPInstance fails to detect systemd integration (#1681) * SAPInstance: Fix for issue #1680 - SAPInstance fails to detect systemd integration --- heartbeat/SAPInstance | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/heartbeat/SAPInstance b/heartbeat/SAPInstance index 15b24024e..f8bcbc05b 100755 --- a/heartbeat/SAPInstance +++ b/heartbeat/SAPInstance @@ -456,7 +456,7 @@ check_systemd_integration() { local systemd_unit_name="SAP${SID}_${InstanceNr}" local rc=1 - if [ -x "$SYSTEMCTL" ]; then + if which "$SYSTEMCTL" 1>/dev/null 2>/dev/null; then if $SYSTEMCTL list-unit-files | \ awk '$1 == service { found=1 } END { if (! found) {exit 1}}' service="${systemd_unit_name}.service"; then rc=0