Fixed one issue that in the case of first boot try failed, and second boot try succeed, rnetboot still returns the first try's error. If second try succeed, it means rnetboot succeed, it should return success.
git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/trunk@10393 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd
This commit is contained in:
parent
cb9f712d6e
commit
f17d4135ca
@ -31,8 +31,9 @@ sub do_rnetboot {
|
||||
my $ssh = @$exp[0];
|
||||
my $userid = @$exp[4];
|
||||
my $pw = @$exp[5];
|
||||
my $result = "";
|
||||
my $Rc = SUCCESS;
|
||||
my $cmd;
|
||||
my $result;
|
||||
|
||||
#######################################
|
||||
# Disconnect Expect session
|
||||
@ -121,8 +122,9 @@ sub do_rnetboot {
|
||||
$cmd.= " -f \"$name\" \"$pprofile\" \"$fsp\" $id $hcp \"$node\"";
|
||||
print "cmd: $cmd\n";
|
||||
my $done = 0;
|
||||
my $Rc = SUCCESS;
|
||||
while ( $done < 2 ) {
|
||||
$result = "";
|
||||
$Rc = SUCCESS;
|
||||
#######################################
|
||||
# Execute command
|
||||
#######################################
|
||||
|
@ -107,9 +107,10 @@ sub do_rnetboot {
|
||||
my $ssh = @$exp[0];
|
||||
my $userid = @$exp[4];
|
||||
my $pw = @$exp[5];
|
||||
my $subreq = $request->{subreq};
|
||||
my $subreq = $request->{subreq};
|
||||
my $Rc = SUCCESS;
|
||||
my $result = "";
|
||||
my $cmd;
|
||||
my $result;
|
||||
|
||||
#######################################
|
||||
# Disconnect Expect session
|
||||
@ -181,7 +182,6 @@ sub do_rnetboot {
|
||||
$cmd.= " -o";
|
||||
}
|
||||
|
||||
my $Rc = SUCCESS;
|
||||
my @macs = split /,/, $opt->{m};
|
||||
foreach my $mac ( @macs ) {
|
||||
#######################################
|
||||
@ -259,6 +259,8 @@ sub do_rnetboot {
|
||||
|
||||
my $done = 0;
|
||||
while ( $done < 2 ) {
|
||||
$result = "";
|
||||
$Rc = SUCCESS;
|
||||
#######################################
|
||||
# Execute command
|
||||
#######################################
|
||||
|
Loading…
Reference in New Issue
Block a user