diff options
Diffstat (limited to 'recipes/corosync/files/init')
-rw-r--r-- | recipes/corosync/files/init | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/recipes/corosync/files/init b/recipes/corosync/files/init index fc45f433a4..7277ca905b 100644 --- a/recipes/corosync/files/init +++ b/recipes/corosync/files/init @@ -96,7 +96,10 @@ stop() { if [ $do_force = 1 ]; then echo -n "Escalating... " killall -KILL corosync - ps | grep /usr/lib/heartbeat | sed "s,^ *,," | cut -f 1 -d ' ' | xargs kill -9 + pids=`pgrep -f '/usr/lib/heartbeat/*'` + if [ -n "$pids" ]; then + kill -KILL $pids + fi sleep 5 if |