mirror of
https://github.com/xcat2/xcat-core.git
synced 2025-05-21 19:22:05 +00:00
fix the indent issue and combine trace message
This commit is contained in:
parent
a35ca71281
commit
a81a5e1a45
30
xCAT-server/lib/xcat/plugins/anaconda.pm
Executable file → Normal file
30
xCAT-server/lib/xcat/plugins/anaconda.pm
Executable file → Normal file
@ -964,7 +964,6 @@ sub mkinstall
|
||||
GetOptions('V' => \$opt{V});
|
||||
my $verbose_on_off=0;
|
||||
if($opt{V}){$verbose_on_off=1;}
|
||||
xCAT::MsgUtils->trace(0,"d","anaconda->mkinstall: opt{V}=$opt{V} verbose_on_off=$verbose_on_off");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
#if ($sitetab)
|
||||
@ -976,8 +975,6 @@ sub mkinstall
|
||||
{
|
||||
$installroot = $site_ent;
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: installroot = $installroot");
|
||||
|
||||
#( $ref) = $sitetab->getAttribs({key => 'tftpdir'}, 'value');
|
||||
@ents = xCAT::TableUtils->get_site_attribute("tftpdir");
|
||||
@ -986,7 +983,7 @@ sub mkinstall
|
||||
{
|
||||
$globaltftpdir = $site_ent;
|
||||
}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: globaltftpdir = $globaltftpdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: installroot=$installroot globaltftpdir=$globaltftpdir");
|
||||
#}
|
||||
|
||||
my $node;
|
||||
@ -1053,8 +1050,6 @@ sub mkinstall
|
||||
} else {
|
||||
$xcatmaster = '!myipfn!';
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: xcatmaster = $xcatmaster");
|
||||
|
||||
my $osinst;
|
||||
if ($rents{$node}->[0] and $rents{$node}->[0]->{tftpdir}) {
|
||||
@ -1062,9 +1057,11 @@ sub mkinstall
|
||||
} else {
|
||||
$tftpdir = $globaltftpdir;
|
||||
}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: tftpdir = $tftpdir");
|
||||
my $ent = $osents{$node}->[0]; #$ostab->getNodeAttribs($node, ['profile', 'os', 'arch']);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: provmethod = $ent->{provmethod}");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: xcatmaster=$xcatmaster tftpdir=$tftpdir provmethod=$ent->{provmethod}");
|
||||
|
||||
|
||||
|
||||
if ($ent and $ent->{provmethod} and ($ent->{provmethod} ne 'install') and ($ent->{provmethod} ne 'netboot') and ($ent->{provmethod} ne 'statelite')) {
|
||||
$imagename=$ent->{provmethod};
|
||||
#print "imagename=$imagename\n";
|
||||
@ -1179,11 +1176,7 @@ sub mkinstall
|
||||
$driverupdatesrc = $ph->{driverupdatesrc};
|
||||
$osupdir = $ph->{'osupdir'};
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: imagename = $imagename");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: pkgdir = $pkgdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: pkglistfile = $pkglistfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: tmplfile = $tmplfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: partfile = $partfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: imagename=$imagename pkgdir=$pkgdir pkglistfile=$pkglistfile tmplfile=$tmplfile partfile=$partfile");
|
||||
}
|
||||
else {
|
||||
$os = $ent->{os};
|
||||
@ -1213,10 +1206,7 @@ sub mkinstall
|
||||
#get the partition file from the linuximage table
|
||||
my $imgname = "$os-$arch-install-$profile";
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: imagename = $imgname");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: pkgdir = $pkgdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: pkglistfile = $pkglistfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: tmplfile = $tmplfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: imagename=$imgname pkgdir=$pkgdir pkglistfile=$pkglistfile tmplfile=$tmplfile");
|
||||
|
||||
if ( ! $linuximagetab ) {
|
||||
$linuximagetab = xCAT::Table->new('linuximage');
|
||||
@ -1226,7 +1216,7 @@ sub mkinstall
|
||||
(my $ref1) = $linuximagetab->getAttribs({imagename => $imgname}, 'partitionfile');
|
||||
if ( $ref1 and $ref1->{'partitionfile'}){
|
||||
$partfile = $ref1->{'partitionfile'};
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: partfile = $partfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: partfile = $partfile");
|
||||
}
|
||||
}
|
||||
#can not find the linux osiamge object, tell users to run "nodeset <nr> osimage=***"
|
||||
@ -1618,9 +1608,7 @@ sub mkinstall
|
||||
$i = "$rtftppath/initrd.img";
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: kcmdline = $kcmdline");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: kernal = $k");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: initrd = $i");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","anaconda->mkinstall: kcmdline=$kcmdline kernal=$k initrd=$i");
|
||||
|
||||
$bptab->setNodeAttribs(
|
||||
$node,
|
||||
|
16
xCAT-server/lib/xcat/plugins/debian.pm
Executable file → Normal file
16
xCAT-server/lib/xcat/plugins/debian.pm
Executable file → Normal file
@ -457,7 +457,6 @@ sub mkinstall {
|
||||
GetOptions('V' => \$opt{V});
|
||||
my $verbose_on_off=0;
|
||||
if($opt{V}){$verbose_on_off=1;}
|
||||
xCAT::MsgUtils->trace(0,"d","debian->mkinstall: opt{V}=$opt{V} verbose_on_off=$verbose_on_off");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
my $installroot;
|
||||
@ -471,7 +470,7 @@ sub mkinstall {
|
||||
}
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: installroot = $installroot");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: installroot=$installroot");
|
||||
|
||||
my $node;
|
||||
my $ostab = xCAT::Table->new('nodetype');
|
||||
@ -620,10 +619,7 @@ sub mkinstall {
|
||||
}
|
||||
$pkglistfile=$ph->{pkglist};
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: imagename = $imagename");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: pkgdir = $pkgdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: pkglistfile = $pkglistfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: tmplfile = $tmplfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: imagename=$imagename pkgdir=$pkgdir pkglistfile=$pkglistfile tmplfile=$tmplfile");
|
||||
}
|
||||
else {
|
||||
$os = $ent->{os};
|
||||
@ -644,9 +640,7 @@ sub mkinstall {
|
||||
}
|
||||
|
||||
$pkgdir="$installroot/$os/$arch";
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: pkgdir = $pkgdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: pkglistfile = $pkglistfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: tmplfile = $tmplfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: pkgdir=$pkgdir pkglistfile=$pkglistfile tmplfile=$tmplfile");
|
||||
}
|
||||
|
||||
if ($arch eq "x86_64") {
|
||||
@ -905,9 +899,7 @@ sub mkinstall {
|
||||
$kcmdline .= " live-installer/net-image=http://${instserver}${pkgdir}/install/filesystem.squashfs";
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: kcmdline = $kcmdline");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: kernal = $rtftppath/vmlinuz");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: initrd = $rtftppath/initrd.img");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","debian->mkinstall: kcmdline=$kcmdline kernal=$rtftppath/vmlinuz initrd=$rtftppath/initrd.img");
|
||||
|
||||
$bptab->setNodeAttribs($node, { kernel => "$rtftppath/vmlinuz",
|
||||
initrd => "$rtftppath/initrd.img",
|
||||
|
@ -93,10 +93,11 @@ sub setdestiny {
|
||||
@ARGV = @{$req->{arg}};
|
||||
my $noupdateinitrd;
|
||||
my $ignorekernelchk;
|
||||
my $verbose; #>>>>>>>used for trace log>>>>>>>
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $verbose;
|
||||
GetOptions('noupdateinitrd' => \$noupdateinitrd,
|
||||
'ignorekernelchk' => \$ignorekernelchk,
|
||||
'V' => \$verbose); #>>>>>>>used for trace log>>>>>>>
|
||||
'V' => \$verbose); #>>>>>>>used for trace log>>>>>>>
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>>
|
||||
my $verbose_on_off=0;
|
||||
|
36
xCAT-server/lib/xcat/plugins/dhcp.pm
Executable file → Normal file
36
xCAT-server/lib/xcat/plugins/dhcp.pm
Executable file → Normal file
@ -1045,7 +1045,7 @@ sub preprocess_request
|
||||
'r' => \$opt{r},
|
||||
's=s' => \$statements, # $statements is declared globally
|
||||
'q' => \$opt{q},
|
||||
'V' => \$opt{V} #>>>>>>>used for trace log>>>>>>>
|
||||
'V' => \$opt{V} #>>>>>>>used for trace log>>>>>>>
|
||||
))
|
||||
{
|
||||
# If the arguements do not pass GetOptions then issue error message and return
|
||||
@ -1056,7 +1056,7 @@ sub preprocess_request
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
if($opt{V}){ $verbose_on_off=1;}
|
||||
if($opt{V}){ $verbose_on_off=1;}
|
||||
|
||||
# check the syntax
|
||||
$rc = check_options($req, \%opt,$callback);
|
||||
@ -1071,7 +1071,7 @@ sub preprocess_request
|
||||
if (defined($t_entry)) {
|
||||
$snonly=$t_entry;
|
||||
}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: disjointdhcps = $t_entry");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: disjointdhcps=$t_entry");
|
||||
my @requests=();
|
||||
my $hasHierarchy=0;
|
||||
|
||||
@ -1140,12 +1140,11 @@ sub preprocess_request
|
||||
xCAT::MsgUtils->message("I", $rsp, $callback);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: nodes are $str_node");
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node=join(" ",@nodes);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: nodes are $str_node");
|
||||
|
||||
# If service node and not -n option
|
||||
if (($snonly == 1) && (!$opt{n})) {
|
||||
@ -1206,7 +1205,7 @@ sub preprocess_request
|
||||
}
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: hasHierarchy = $hasHierarchy");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: hasHierarchy=$hasHierarchy");
|
||||
|
||||
if ( $hasHierarchy)
|
||||
{
|
||||
@ -1266,7 +1265,7 @@ sub process_request
|
||||
'r' => \$opt{r},
|
||||
's=s' => \$statements, # $statements is declared globally
|
||||
'q' => \$opt{q},
|
||||
'V' => \$opt{V} #>>>>>>>used for trace log>>>>>>>
|
||||
'V' => \$opt{V} #>>>>>>>used for trace log>>>>>>>
|
||||
))
|
||||
{
|
||||
# If the arguements do not pass GetOptions then issue error message and return
|
||||
@ -1276,8 +1275,8 @@ sub process_request
|
||||
return 1;
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
if($opt{V}){ $verbose_on_off=1;}
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
if($opt{V}){ $verbose_on_off=1;}
|
||||
|
||||
# Check options again in case we are called from plugin and options have not been processed
|
||||
my $rc = 0;
|
||||
@ -1409,12 +1408,9 @@ sub process_request
|
||||
# return;
|
||||
} else {
|
||||
$site_domain = $t_entry;
|
||||
}
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: sitelogservers = $sitelogservers");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: sitentpservers = $sitentpservers");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: sitenameservers = $sitenameservers");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: site_domain = $site_domain");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: sitelogservers=$sitelogservers sitentpservers=$sitentpservers sitenameservers=$sitenameservers site_domain=$site_domain");
|
||||
}
|
||||
|
||||
@dhcpconf = ();
|
||||
@ -1425,7 +1421,7 @@ sub process_request
|
||||
flock($dhcplockfd,LOCK_EX);
|
||||
if ($::XCATSITEVALS{externaldhcpservers}) {
|
||||
# do nothing if remote dhcpservers at this point
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: remote dhcpservers at this point, do nothing");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: remote dhcpservers at this point, do nothing");
|
||||
} elsif ($opt{n}) {
|
||||
if (-e $dhcpconffile) {
|
||||
if ($^O eq 'aix') {
|
||||
@ -1455,7 +1451,7 @@ sub process_request
|
||||
|
||||
my $bakname = "$dhcpconffile.xcatbak";
|
||||
rename("$dhcpconffile", $bakname);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: Renamed existing dhcp configuration file to $dhcpconffile.xcatbak");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: Renamed existing dhcp configuration file to $dhcpconffile.xcatbak");
|
||||
}
|
||||
}
|
||||
else
|
||||
@ -1952,7 +1948,7 @@ sub process_request
|
||||
writeout();
|
||||
if (not $::XCATSITEVALS{externaldhcpservers} and $restartdhcp) {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","dhcp: restart dhcp service");
|
||||
if ( $^O eq 'aix')
|
||||
if ( $^O eq 'aix')
|
||||
{
|
||||
restart_dhcpd_aix();
|
||||
}
|
||||
|
@ -360,9 +360,8 @@ sub preprocess_request {
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>
|
||||
my $verbose_on_off=0;
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#xCAT::MsgUtils->trace(1,"d","grub2: VERBOSE=$VERBOSE verbose_on_off=$verbose_on_off ");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
if ($HELP) {
|
||||
if($usage{$command}) {
|
||||
@ -396,7 +395,7 @@ sub preprocess_request {
|
||||
my @entries = xCAT::TableUtils->get_site_attribute("sharedtftp");
|
||||
my $t_entry = $entries[0];
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: sharedtftp = $t_entry");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: sharedtftp=$t_entry");
|
||||
|
||||
if ( defined($t_entry) and ($t_entry eq "0" or $t_entry eq "no" or $t_entry eq "NO")) {
|
||||
# check for computenodes and servicenodes from the noderange, if so error out
|
||||
@ -439,7 +438,6 @@ sub process_request {
|
||||
my @rnodes;
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>>
|
||||
#my @args=();
|
||||
my %opt;
|
||||
my $verbose_on_off=0;
|
||||
if (ref($::XNBA_request->{arg})) {
|
||||
@ -479,9 +477,8 @@ sub process_request {
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: nodes are $str_node");
|
||||
my $str_node = join(" ",@nodes);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: nodes are $str_node");
|
||||
|
||||
# return directly if no nodes in the same network
|
||||
unless (@nodes) {
|
||||
@ -499,15 +496,15 @@ sub process_request {
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact') {
|
||||
$errored=0;
|
||||
if ($request->{'_disparatetftp'}->[0]) { #the call is distrubuted to the service node already, so only need to handles my own children
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: the call is distrubuted to the service node already, so only need to handles my own children");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: the call is distrubuted to the service node already, so only need to handles my own children");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@nodes,
|
||||
arg=>[$args[0], '-l']},\&pass_along);
|
||||
} else { #nodeset did not distribute to the service node, here we need to let runednpre to distribute the nodes to their masters
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@rnodes,
|
||||
arg=>[$args[0]]},\&pass_along);
|
||||
}
|
||||
@ -526,8 +523,8 @@ sub process_request {
|
||||
if (!$inittime) { $inittime=0;}
|
||||
$errored=0;
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact') {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue setdestiny request");
|
||||
$sub_req->({command=>['setdestiny'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue setdestiny request");
|
||||
$sub_req->({command=>['setdestiny'],
|
||||
node=>\@nodes,
|
||||
inittime=>[$inittime],
|
||||
arg=>\@args},\&pass_along);
|
||||
@ -633,11 +630,11 @@ sub process_request {
|
||||
}
|
||||
if ($do_dhcpsetup) {
|
||||
if ($request->{'_disparatetftp'}->[0]) { #reading hint from preprocess_command
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@{$osimagenodehash{$osimage}}}, $callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@{$osimagenodehash{$osimage}}},$callback);
|
||||
}
|
||||
@ -651,12 +648,12 @@ sub process_request {
|
||||
}
|
||||
if ($do_dhcpsetup) {
|
||||
if ($request->{'_disparatetftp'}->[0]) { #reading hint from preprocess_command
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@breaknetboot,
|
||||
arg=>['-l']},$callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@breaknetboot},$callback);
|
||||
}
|
||||
@ -667,13 +664,13 @@ sub process_request {
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact')
|
||||
$errored=0;
|
||||
if ($request->{'_disparatetftp'}->[0]) { #the call is distrubuted to the service node already, so only need to handles my own children
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runendpre request");
|
||||
$sub_req->({command=>['runendpre'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runendpre request");
|
||||
$sub_req->({command=>['runendpre'],
|
||||
node=>\@nodes,
|
||||
arg=>[$args[0], '-l']},\&pass_along);
|
||||
} else { #nodeset did not distribute to the service node, here we need to let runednpre to distribute the nodes to their masters
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runendpre request");
|
||||
$sub_req->({command=>['runendpre'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","grub2: issue runendpre request");
|
||||
$sub_req->({command=>['runendpre'],
|
||||
node=>\@rnodes,
|
||||
arg=>[$args[0]]},\&pass_along);
|
||||
}
|
||||
|
@ -267,9 +267,8 @@ sub preprocess_request {
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>
|
||||
my $verbose_on_off=0;
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#xCAT::MsgUtils->trace(1,"d","petitboot: VERBOSE=$VERBOSE verbose_on_off=$verbose_on_off ");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
if ($HELP) {
|
||||
if($usage{$command}) {
|
||||
@ -355,7 +354,6 @@ sub process_request {
|
||||
if ($::XCATSITEVALS{"httpmethod"}) { $httpmethod = $::XCATSITEVALS{"httpmethod"}; }
|
||||
if ($::XCATSITEVALS{"httpport"}) { $httpport = $::XCATSITEVALS{"httpport"}; }
|
||||
|
||||
#my @args;
|
||||
my @nodes;
|
||||
my @rnodes;
|
||||
if (ref($request->{node})) {
|
||||
@ -385,8 +383,7 @@ sub process_request {
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
my $str_node = join(" ",@nodes);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: nodes are $str_node");
|
||||
|
||||
# return directly if no nodes in the same network
|
||||
@ -411,8 +408,8 @@ sub process_request {
|
||||
node=>\@nodes,
|
||||
arg=>[$args[0], '-l']},\&pass_along);
|
||||
} else { #nodeset did not distribute to the service node, here we need to let runednpre to distribute the nodes to their masters
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: issue runbeginpre request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@rnodes,
|
||||
arg=>[$args[0]]},\&pass_along);
|
||||
@ -519,7 +516,7 @@ sub process_request {
|
||||
arg=>['-l']},$callback);
|
||||
#arg=>['-l','-s','option conf-file \"'.$fpath.'\";']},$callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","petitboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=> [$node]}, $callback);
|
||||
#arg=>['-s','option conf-file \"'.$fpath.'\";']},$callback);
|
||||
|
@ -55,7 +55,6 @@ sub preprocess_request
|
||||
@ARGV = @args;
|
||||
GetOptions('V' => \$opt{V});
|
||||
if($opt{V}){$verbose_on_off=1;}
|
||||
xCAT::MsgUtils->trace(0,"d","prescripts->preprocess_request: opt{V}=$opt{V} verbose_on_off=$verbose_on_off");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
#if already preprocessed, go straight to request
|
||||
@ -94,9 +93,9 @@ sub preprocess_request
|
||||
|
||||
# if no nodes left to process, we are done
|
||||
if (! @nodes) {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d", "prescripts->preprocess_request: no nodes left to process, we are done");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","prescripts->preprocess_request: no nodes left to process, we are done");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
my $service = "xcat";
|
||||
@args=();
|
||||
@ -110,11 +109,9 @@ sub preprocess_request
|
||||
#print "prepscripts: preprocess_request get called, args=@args, nodes=@$nodes\n";
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>
|
||||
my $str_node;
|
||||
my $str_args;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
foreach my $str_a (@args){$str_args .= $str_a." ";}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","prescripts->preprocess_request: get called, args=$str_args, nodes=$str_node");
|
||||
my $str_node=join(" ",@nodes);
|
||||
my $str_args=join(" ",@args);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","prescripts->preprocess_request: get called, args='$str_args', nodes='$str_node'");
|
||||
|
||||
#use Getopt::Long;
|
||||
Getopt::Long::Configure("bundling");
|
||||
@ -142,7 +139,7 @@ sub preprocess_request
|
||||
$reqcopy->{'_xcatdest'} = $hostinfo[0];
|
||||
$reqcopy->{_xcatpreprocessed}->[0] = 1;
|
||||
push @requests, $reqcopy;
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","prescripts: handle request in $hostinfo[0]");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","prescripts: handle request in $hostinfo[0]");
|
||||
return \@requests;
|
||||
}
|
||||
} else { #run on mn and need to dispatch the requests to the service nodes
|
||||
|
@ -314,9 +314,8 @@ sub preprocess_request {
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>
|
||||
my $verbose_on_off=0;
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#xCAT::MsgUtils->trace(1,"d","pxe: VERBOSE=$VERBOSE verbose_on_off=$verbose_on_off ");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
if ($HELP) {
|
||||
if($usage{$command}) {
|
||||
@ -347,7 +346,7 @@ sub preprocess_request {
|
||||
#my $sent = $stab->getAttribs({key=>'sharedtftp'},'value');
|
||||
my @entries = xCAT::TableUtils->get_site_attribute("sharedtftp");
|
||||
my $t_entry = $entries[0];
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: sharedtftp = $t_entry");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: sharedtftp=$t_entry");
|
||||
if ( defined($t_entry) and ($t_entry eq "0" or $t_entry eq "no" or $t_entry eq "NO")) {
|
||||
# check for computenodes and servicenodes from the noderange, if so error out
|
||||
my @SN;
|
||||
@ -425,8 +424,7 @@ sub process_request {
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
my $str_node = join(" ",@nodes);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: nodes are $str_node");
|
||||
|
||||
# return directly if no nodes in the same network
|
||||
@ -445,15 +443,15 @@ sub process_request {
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact') {
|
||||
$errored=0;
|
||||
if ($::PXE_request->{'_disparatetftp'}->[0]) { #the call is distrubuted to the service node already, so only need to handles my own children
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: the call is distrubuted to the service node already, so only need to handles my own children");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: issue runbeginpre request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: the call is distrubuted to the service node already, so only need to handles my own children");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@nodes,
|
||||
arg=>[$args[0], '-l']},\&pass_along);
|
||||
} else { #nodeset did not distribute to the service node, here we need to let runednpre to distribute the nodes to their masters
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@rnodes,
|
||||
arg=>[$args[0]]},\&pass_along);
|
||||
}
|
||||
@ -489,7 +487,7 @@ sub process_request {
|
||||
if (exists($::PXE_request->{inittime})) { $inittime= $::PXE_request->{inittime}->[0];}
|
||||
if (!$inittime) { $inittime=0;}
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact') {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: issue setdestiny request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","pxe: issue setdestiny request");
|
||||
$sub_req->({command=>['setdestiny'],
|
||||
node=>\@nodes,
|
||||
inittime=>[$inittime],
|
||||
|
26
xCAT-server/lib/xcat/plugins/sles.pm
Executable file → Normal file
26
xCAT-server/lib/xcat/plugins/sles.pm
Executable file → Normal file
@ -764,7 +764,6 @@ sub mkinstall
|
||||
GetOptions('V' => \$opt{V});
|
||||
my $verbose_on_off=0;
|
||||
if($opt{V}){$verbose_on_off=1;}
|
||||
xCAT::MsgUtils->trace(0,"d","sles->mkinstall: opt{V}=$opt{V} verbose_on_off=$verbose_on_off");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
my $ntents = $ostab->getNodesAttribs($request->{node}, ['os', 'arch', 'profile', 'provmethod']);
|
||||
@ -795,7 +794,7 @@ sub mkinstall
|
||||
}
|
||||
#}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: installroot = $installroot");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: installroot=$installroot");
|
||||
|
||||
my %donetftp;
|
||||
require xCAT::Template; #only used here, load so memory can be COWed
|
||||
@ -847,7 +846,7 @@ sub mkinstall
|
||||
$tftpdir = $globaltftpdir;
|
||||
}
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: tftpdir = $tftpdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: tftpdir=$tftpdir");
|
||||
|
||||
if ($ent and $ent->{provmethod} and ($ent->{provmethod} ne 'install') and ($ent->{provmethod} ne 'netboot') and ($ent->{provmethod} ne 'statelite')) {
|
||||
$imagename=$ent->{provmethod};
|
||||
@ -934,11 +933,7 @@ sub mkinstall
|
||||
$driverupdatesrc = $ph->{driverupdatesrc};
|
||||
$osupdir = $ph->{'osupdir'};
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: imagename = $imagename");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: pkgdir = $pkgdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: pkglistfile = $pkglistfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: tmplfile = $tmplfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: partfile = $partfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: imagename=$imagename pkgdir=$pkgdir pkglistfile=$pkglistfile tmplfile=$tmplfile partfile=$partfile");
|
||||
}
|
||||
else {
|
||||
$os = $ent->{os};
|
||||
@ -965,10 +960,7 @@ sub mkinstall
|
||||
#get the partition file from the linuximage table
|
||||
my $imgname = "$os-$arch-install-$profile";
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: imagename = $imgname");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: pkgdir = $pkgdir");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: pkglistfile = $pkglistfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: tmplfile = $tmplfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: imagename=$imgname pkgdir=$pkgdir pkglistfile=$pkglistfile tmplfile=$tmplfile");
|
||||
|
||||
if (! $linuximagetab) {
|
||||
$linuximagetab = xCAT::Table->new('linuximage');
|
||||
@ -978,7 +970,7 @@ sub mkinstall
|
||||
(my $ref1) = $linuximagetab->getAttribs({imagename => $imgname}, 'partitionfile');
|
||||
if ( $ref1 and $ref1->{'partitionfile'}){
|
||||
$partfile = $ref1->{'partitionfile'};
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: partfile = $partfile");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: partfile=$partfile");
|
||||
}
|
||||
}
|
||||
else {
|
||||
@ -1313,9 +1305,7 @@ sub mkinstall
|
||||
{
|
||||
$kernelpath = "$rtftppath/linux";
|
||||
$initrdpath = "$rtftppath/initrd";
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: kcmdline = $kcmdline");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: kernal = $kernelpath");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: initrd = $initrdpath");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: kcmdline=$kcmdline kernal=$kernelpath initrd=$initrdpath");
|
||||
$bptab->setNodeAttribs(
|
||||
$node,
|
||||
{
|
||||
@ -1328,9 +1318,7 @@ sub mkinstall
|
||||
elsif ($arch =~ /ppc/)
|
||||
{
|
||||
$kernelpath = "$rtftppath/inst64";
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: kcmdline = $kcmdline");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: kernal = $kernelpath");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: initrd = ");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","sles->mkinstall: kcmdline=$kcmdline kernal=$kernelpath initrd=");
|
||||
$bptab->setNodeAttribs(
|
||||
$node,
|
||||
{
|
||||
|
@ -332,9 +332,8 @@ sub preprocess_request {
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>
|
||||
my $verbose_on_off=0;
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#xCAT::MsgUtils->trace(1,"d","xnba: VERBOSE=$VERBOSE verbose_on_off=$verbose_on_off ");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
if ($HELP) {
|
||||
if($usage{$command}) {
|
||||
@ -367,7 +366,7 @@ sub preprocess_request {
|
||||
#they specify no sharedtftp in site table
|
||||
my @entries = xCAT::TableUtils->get_site_attribute("sharedtftp");
|
||||
my $t_entry = $entries[0];
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: sharedtftp = $t_entry");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: sharedtftp=$t_entry");
|
||||
if ( defined($t_entry) and ($t_entry eq "0" or $t_entry eq "no" or $t_entry eq "NO")) {
|
||||
# check for computenodes and servicenodes from the noderange, if so error out
|
||||
my @SN;
|
||||
@ -438,15 +437,14 @@ sub process_request {
|
||||
push @nodes,$_;
|
||||
} else {
|
||||
xCAT::MsgUtils->message("S", "$_: xnba netboot: stop configuration because of none sharedtftp and not on same network with its xcatmaster.");
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
@nodes = @rnodes;
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
my $str_node = join(" ",@nodes);
|
||||
xCAT::MsgUtils->trace(0,"d","xnba: nodes are $str_node");
|
||||
|
||||
# return directly if no nodes in the same network
|
||||
@ -465,14 +463,14 @@ sub process_request {
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact') {
|
||||
$errored=0;
|
||||
if ($::XNBA_request->{'_disparatetftp'}->[0]) { #the call is distrubuted to the service node already, so only need to handles my own children
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: the call is distrubuted to the service node already, so only need to handles my own children");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: issue runbeginpre request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: the call is distrubuted to the service node already, so only need to handles my own children");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@nodes,
|
||||
arg=>[$args[0], '-l']},\&pass_along);
|
||||
} else { #nodeset did not distribute to the service node, here we need to let runednpre to distribute the nodes to their masters
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: issue runbeginpre request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: nodeset did not distribute to the service node");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: issue runbeginpre request");
|
||||
$sub_req->({command=>['runbeginpre'],
|
||||
node=>\@rnodes,
|
||||
arg=>[$args[0]]},\&pass_along);
|
||||
@ -506,8 +504,8 @@ sub process_request {
|
||||
if (!$inittime) { $inittime=0;}
|
||||
$errored=0;
|
||||
unless ($args[0] eq 'stat') { # or $args[0] eq 'enact') {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: issue setdestiny request");
|
||||
$sub_req->({command=>['setdestiny'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","xnba: issue setdestiny request");
|
||||
$sub_req->({command=>['setdestiny'],
|
||||
node=>\@nodes,
|
||||
inittime=>[$inittime],
|
||||
arg=>\@args},\&pass_along);
|
||||
|
@ -375,11 +375,10 @@ sub preprocess_request {
|
||||
return;
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log start>>>>>>
|
||||
#>>>>>>>used for trace log start>>>>>>
|
||||
my $verbose_on_off=0;
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#xCAT::MsgUtils->trace(1,"d","yaboot: VERBOSE=$VERBOSE verbose_on_off=$verbose_on_off ");
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
if($VERBOSE){$verbose_on_off=1;}
|
||||
#>>>>>>>used for trace log end>>>>>>>
|
||||
|
||||
if ($HELP) {
|
||||
if($usage{$command}) {
|
||||
@ -413,7 +412,7 @@ sub preprocess_request {
|
||||
my @entries = xCAT::TableUtils->get_site_attribute("sharedtftp");
|
||||
my $t_entry = $entries[0];
|
||||
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: sharedtftp = $t_entry");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: sharedtftp=$t_entry");
|
||||
|
||||
if ( defined($t_entry) and ($t_entry eq "0" or $t_entry eq "no" or $t_entry eq "NO")) {
|
||||
# check for computenodes and servicenodes from the noderange, if so error out
|
||||
@ -496,10 +495,9 @@ sub process_request {
|
||||
@nodes = @rnodes;
|
||||
}
|
||||
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node;
|
||||
foreach my $str_n (@nodes){$str_node .= $str_n." ";}
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: nodes are $str_node");
|
||||
#>>>>>>>used for trace log>>>>>>>
|
||||
my $str_node = join(" ",@nodes);
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: nodes are $str_node");
|
||||
|
||||
# return directly if no nodes in the same network
|
||||
unless (@nodes) {
|
||||
@ -750,12 +748,12 @@ sub process_request {
|
||||
}
|
||||
}
|
||||
if ($::YABOOT_request->{'_disparatetftp'}->[0]) { #reading hint from preprocess_command
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@{$osimagenodehash{$osimage}},
|
||||
arg=>['-l']},$::YABOOT_callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@{$osimagenodehash{$osimage}}},$::YABOOT_callback);
|
||||
}
|
||||
@ -767,24 +765,24 @@ sub process_request {
|
||||
}
|
||||
|
||||
if ($::YABOOT_request->{'_disparatetftp'}->[0]) { #reading hint from preprocess_command, only change local settings if already farmed
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],arg=>['-l'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],arg=>['-l'],
|
||||
node=>\@{$osimagenodehash{$osimage}}},$::YABOOT_callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@{$osimagenodehash{$osimage}}},$::YABOOT_callback);
|
||||
}
|
||||
}
|
||||
}
|
||||
} else {
|
||||
if ($::YABOOT_request->{'_disparatetftp'}->[0]) { #reading hint from preprocess_command, only change local settings if already farmed
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],arg=>['-l'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],arg=>['-l'],
|
||||
node=>\@normalnodeset},$::YABOOT_callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@normalnodeset},$::YABOOT_callback);
|
||||
}
|
||||
}
|
||||
@ -794,12 +792,12 @@ sub process_request {
|
||||
}
|
||||
}
|
||||
if ($::YABOOT_request->{'_disparatetftp'}->[0]) { #reading hint from preprocess_command
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@breaknetboot,
|
||||
arg=>['-l']},$::YABOOT_callback);
|
||||
} else {
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
xCAT::MsgUtils->trace($verbose_on_off,"d","yaboot: issue makedhcp request");
|
||||
$sub_req->({command=>['makedhcp'],
|
||||
node=>\@breaknetboot}, $::YABOOT_callback);
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user