2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-06-18 12:20:40 +00:00

fix issue2726 remoteshell failed in line 488 in statelite (#3017)

* fix issue2726 remoteshell failed in line 488 in statelite

* polished based on comments

* polished based on comments
This commit is contained in:
Yuan Bai
2017-05-10 10:59:29 +08:00
committed by yangsong
parent d5c3e5d7ea
commit eec05162f5

View File

@ -485,10 +485,12 @@ else
#service sshd restart
# sshd is not enabled on SLES 12 by default
# does not hurt anything to re-enable if it is enabled already
enableservice sshd
# and disable enable service for diskless and statelite
if [ "$NODESETSTATE" = install ]; then
enableservice sshd
fi
restartservice sshd
fi
#if the service restart with "service/systemctl" failed
#try to kill the process and start
if [ "$?" != "0" ];then