fix for scaling

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@2523 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
linggao 2008-11-22 04:03:24 +00:00
parent b47e2d3585
commit c9ceae7dd4
2 changed files with 21 additions and 2 deletions

View File

@ -213,11 +213,28 @@ if [ $isLinux -eq 0 ]; then
if [[ -n "$state" && "$state" = "active" ]];then
stopsrc -s syslogd
fi
startsrc -s syslogd
#wait for syslogd to fully started
RETRY_LIMIT=30 # number of 2 second retry intervals (60 second total)
let i=$RETRY_LIMIT
while :
do
ret=`LC_ALL=C startsrc -s syslogd 2>&1`
if [[ $ret == *PID* ]];then
break
fi
i=$((i - 1))
if (( i > 0 ));then
sleep 2
else
break
fi
done
else
$init restart
fi
#keep a record
logger -t xcat "Install: syslog setup"
logger -t xCAT "Install: syslog setup"
exit 0

View File

@ -9,6 +9,8 @@
use File::Path;
use IO::Socket;
sleep int(rand(10));
# since we don't have syslog set up yet we'll
# just save msgs in a local log file
$logdir = "/var/log/xcat";