1. modified , 2. handle the Not Available case

git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@5398 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
jjhua 2010-03-08 06:54:45 +00:00
parent 1d9b8388e0
commit b2e32a8f15

View File

@ -99,7 +99,7 @@ proc run_lssyscfg {} {
nc_msg "$PROGRAM Status: run_lssyscg : partition status : $msg\n"
regexp "$node:\[ ]*(.*)" $msg tmp1 tmp
set msg $tmp
send_user "####msg:$msg#########"
nc_msg "####msg:$msg#########\n"
# Slow down the requests speed to hcp, so that hcp will not busy on
@ -1827,7 +1827,7 @@ proc Firmware_Dump { device_path phandle } {
# Main MAIN main
#
set BINPATH "/opt/xcat/bin"
set PROGRAM "lpar_netboot.expect"
set PROGRAM "lpar_netboot"
set CONSOLEBIN "/opt/xcat/bin/rcons"
@ -2132,6 +2132,13 @@ send_user "# Checking for power off.\n"
run_lssyscfg
if { [string compare "$msg" "Not Available"] == 0 } {
send_user "$PROGRAM: LPAR is Not Available. Please make sure the CEC's state\n"
set rc 1
exit 1
}
if { ([string compare "$msg" "Off"] == 0) || ([string compare "$msg" "off"] == 0) || ([string compare "$msg" "Not Activated"] == 0) } {
send_user "# Power off complete.\n"
} else {