modify usage for 'chvm' and 'mkvm', remove debug msg

This commit is contained in:
zhaoertao 2014-01-26 22:52:30 -08:00
parent 9374e01b76
commit 4c74a94daf
4 changed files with 14 additions and 12 deletions

View File

@ -1749,8 +1749,8 @@ sub query_cec_info {
my $args = $request->{opt};
my @td = ();
my @result = ();
print Dumper($request);
print Dumper($hash);
#print Dumper($request);
#print Dumper($hash);
while (my ($mtms,$h) = each(%$hash) ) {
while (my ($name, $d) = each (%$h)) {
@td = @$d;

View File

@ -207,6 +207,7 @@ my %usage = (
mkvm noderange [--full]
mkvm noderange [vmcpus=min/req/max] [vmmemory=min/req/max]
[vmphyslots=drc_index1,drc_index2...] [vmothersetting=hugepage:N,bsr:N]
[vmnics=vlan1,vlan2] [vmstorage=<N|viosnode:slotid>] [--vios]
For KVM
mkvm noderange -m|--master mastername -s|--size disksize -f|--force
For zVM
@ -241,6 +242,8 @@ my %usage = (
chvm <noderange> [lparname=<*|name>]
chvm <noderange> [vmcpus=min/req/max] [vmmemory=min/req/max]
[vmphyslots=drc_index1,drc_index2...] [vmothersetting=hugepage:N,bsr:N]
[vmnics=vlan1,vlan2] [vmstorage=<N|viosnode:slotid>] [--vios]
chvm <noderange> [del_vadapter=slotid]
VMware specific:
chvm <noderange> [-a size][-d disk][-p disk][--resize disk=size][--cpus count][--mem memory]
zVM specific:

View File

@ -17,7 +17,7 @@ use File::Path;
use File::Copy;
use Fcntl qw/:flock/;
use Data::Dumper;
#use Data::Dumper;
use Getopt::Long;
Getopt::Long::Configure("bundling");
Getopt::Long::Configure("pass_through");
@ -144,7 +144,7 @@ sub preprocess_request {
$request = {};
return;
}
print Dumper($request);
#print Dumper($request);
return [$request];
}
@ -160,7 +160,7 @@ sub process_request {
if ($command eq 'copycd') {
return copycd($request, $callback, $subreq);
} elsif ($command eq 'nodeset') {
print Dumper($request);
#print Dumper($request);
return nodeset($request, $callback, $subreq);
}
}
@ -202,8 +202,8 @@ sub copycd {
$callback->({error=>"Only suport to use the iso file vios"});
return;
}
print __LINE__."=====>vios=====.\n";
print Dumper($request);
#print __LINE__."=====>vios=====.\n";
#print Dumper($request);
my $installroot = "/install";
my @entries = xCAT::TableUtils->get_site_attribute("installdir");
my $t_entry = $entries[0];
@ -259,7 +259,7 @@ sub copycd {
close($expectcd_fd);
}
if ($expect_cd eq "END") {
goto CREATE_OBJ;
#goto CREATE_OBJ;
$callback->({error=>"All the cds for $distname are gotten."});
return;
}
@ -318,7 +318,7 @@ sub copycd {
$callback->({error=>$res});
return;
}
CREATE_OBJ:
#CREATE_OBJ:
if ($expect_cd eq "END") {
my $imagename = $distname.'_sysb';
xCAT::MsgUtils->message("I", {data=>["create osimage object: $imagename"]}, $callback);
@ -331,7 +331,7 @@ CREATE_OBJ:
osdistroname=>$distname,
osvers=>$oslevel,
osarch=>$arch);
print Dumper(%tb_cols);
#print Dumper(%tb_cols);
$osimagetab->setAttribs(\%key_col, \%tb_cols);
} else {
$callback->({error=>"Can not open 'osimage' table"});

View File

@ -129,16 +129,15 @@ unless($mask) {
}
}
close($::LOG_FILE);
{
my $lsicmd = "/usr/sbin/lsitab bootnicsea > /dev/null 2>&1";
if (&runcmd($lsicmd) == 0) {
#my $mkicmd = '/usr/sbin/mkitab "bootnicsea:2:wait:/xcatpost/config_bootnicsea > /dev/console 2>&1"';
my $rmicmd = 'rmitab "bootnicsea" > /dev/null 2>&1';
if (&runcmd($rmicmd) != 0) {
msg("Warning: config_bootnicsea: Could not remove config_bootnicsea from /etc/inittab.\n")
}
}
}
close($::LOG_FILE);
exit 0;