2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-05-22 11:42:05 +00:00

issue 1137: waiting longer for stopping xcatd when the system load of xCAT MN is heavy

This commit is contained in:
wangxiaopeng 2016-06-01 03:14:51 -04:00
parent 6824226606
commit d9519b6bd3

View File

@ -103,15 +103,21 @@ stop)
fi
kill -TERM -`cat /var/run/xcatd.pid`
i=0;
while $STATUS > /dev/null 2>&1 && [ $i -lt 15 ]; do
while $STATUS > /dev/null 2>&1 && [ $i -lt 30 ]; do
sleep .1
i=$((i+1))
done
$STATUS > /dev/null 2>&1
if [ "$?" = "0" ]; then
kill -KILL -`cat /var/run/xcatd.pid`
i=0
while $STATUS > /dev/null 2>&1 && [ $i -lt 30 ]; do
sleep .1
i=$((i+1))
done
fi
sleep .1
$STATUS > /dev/null 2>&1
if [ "$?" = "0" ]; then
$LOG_FAILURE