diff --git a/perl-xCAT/xCAT/PPCboot.pm b/perl-xCAT/xCAT/PPCboot.pm index 4281d97ed..f8f1ae9a7 100644 --- a/perl-xCAT/xCAT/PPCboot.pm +++ b/perl-xCAT/xCAT/PPCboot.pm @@ -306,11 +306,25 @@ sub rnetboot { if ( !defined( $name )) { return( [[$node,"Node not found, lparid=$lparid",RC_ERROR]] ); } - ######################################### - # Manually perform boot. - ######################################### - $result = do_rnetboot( $request, $d, $exp, $name, $node, \%opt ); + + my $sitetab = xCAT::Table->new('site'); + my $vcon = $sitetab->getAttribs({key => "conserveronhmc"}, 'value'); + if ($vcon and $vcon->{"value"} and $vcon->{"value"} eq "yes" ) { + $result = xCAT::PPCcli::lpar_netboot( + $exp, + $request->{verbose}, + $name, + $d, + \%opt ); + } else { + ######################################### + # Manually perform boot. + ######################################### + $result = do_rnetboot( $request, $d, $exp, $name, $node, \%opt ); + } + $sitetab->close; $Rc = shift(@$result); + ################################## # Form string from array results diff --git a/perl-xCAT/xCAT/PPCmac.pm b/perl-xCAT/xCAT/PPCmac.pm index 968d80648..f59ec0927 100644 --- a/perl-xCAT/xCAT/PPCmac.pm +++ b/perl-xCAT/xCAT/PPCmac.pm @@ -375,10 +375,23 @@ sub getmacs { if ( !defined( $name )) { return( [[$node,"Node not found, lparid=$lparid",RC_ERROR]] ); } - ######################################### - # Manually collect MAC addresses. - ######################################### - $result = do_getmacs( $request, $d, $exp, $name, $node ); + + my $sitetab = xCAT::Table->new('site'); + my $vcon = $sitetab->getAttribs({key => "conserveronhmc"}, 'value'); + if ($vcon and $vcon->{"value"} and $vcon->{"value"} eq "yes" ) { + $result = xCAT::PPCcli::lpar_netboot( + $exp, + $request->{verbose}, + $name, + $d, + $opt ); + } else { + ######################################### + # Manually collect MAC addresses. + ######################################### + $result = do_getmacs( $request, $d, $exp, $name, $node ); + } + $sitetab->close; $Rc = shift(@$result); ##################################