From 2ae905b5d4490929ea84d29be36b6983d1e5bb6d Mon Sep 17 00:00:00 2001 From: Denys Havrysh Date: Thu, 19 Jan 2017 10:21:27 +0200 Subject: [PATCH] RHEL6: disable stdin to fix shell session hang on killing tee pipe --- bootstrap-salt.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bootstrap-salt.sh b/bootstrap-salt.sh index 6c6c93d..22ba484 100755 --- a/bootstrap-salt.sh +++ b/bootstrap-salt.sh @@ -3754,9 +3754,9 @@ install_centos_restart_daemons() { return 1 fi elif [ -f /etc/init.d/salt-$fname ]; then - # Still in SysV init!? - /etc/init.d/salt-$fname stop > /dev/null 2>&1 - /etc/init.d/salt-$fname start + # Disable stdin to fix shell session hang on killing tee pipe + service salt-$fname stop < /dev/null > /dev/null 2>&1 + service salt-$fname start < /dev/null elif [ -f /usr/bin/systemctl ]; then # CentOS 7 uses systemd /usr/bin/systemctl stop salt-$fname > /dev/null 2>&1