2
0
mirror of https://github.com/xcat2/xcat-core.git synced 2025-06-23 06:25:38 +00:00

Merged the zVM changes into some xcat_client files (#1608)

Change-Id: I3405cede348c63ea6b43ceda4bdfdad0f3a5422a
This commit is contained in:
Chuck Brazie
2016-08-02 22:03:15 -04:00
committed by yangsong
parent 5cd203cdf5
commit a21edcdcb5
2 changed files with 16 additions and 6 deletions

View File

@ -57,6 +57,7 @@ sub print_usage
print "Usage:\n";
print " genimage\n\n";
print " genimage --dryrun\n\n";
print ' genimage -o <osver> [-a <arch>] -p <profile> -i <nodebootif> -n <nodenetdrivers> [--onlyinitrd] [-r <otherifaces>] [-k <kernelver>] [-g <krpmver>] [-m statelite] [-l rootlimitsize] [-t tmplimitsize] [--permission <permission>] [--interactive] [--dryrun]'."\n\n";
print ' genimage [-o <osver>] [-a <arch>] [-p <profile>] [-i <nodebootif>] [-n <nodenetdrivers>] [--onlyinitrd] [-r <otherifaces>] [-k <kernelver>] [-g <krpmver>] [-m statelite] [-l rootlimitsize] [-t tmplimitsize] [--permission <permission>] [--interactive] [--dryrun] [--noupdate] <imagename>' . "\n\n";
print " --permission is used for statelite only\n";
print " -g is used for SLES only\n\n";
@ -64,6 +65,11 @@ sub print_usage
print "Examples:\n";
print " genimage\n";
print " genimage --interactive\n";
print " genimage -i eth0 -n tg3 -o sles11 -p compute\n";
print " genimage -i eth0 -n tg3 -o sles11 -p compute --onlyinitrd\n";
print " genimage -i eth0 -r eth1,eth2 -n tg3,bnx2 -o centos5.1 -p compute --interactive\n";
print " genimage -i eth0 -n tg3,bnx2 -o sles11 -p compute --dryrun\n";
print " genimage -i eth0 -n igb,e1000e,e1000,bnx2,tg3 -o centos5.4 -p nfsroot --permission 777\n";
print " genimage -i eth0 -n tg3 --interactive myimagename\n";
print " genimage myimagename\n";
}

View File

@ -38,7 +38,7 @@ This program is the client interface for xdsh/xdcp.
Bypass mode is useful, when executing the command on the Management Server
and in particular if you want to run as a non-root id.
Call parse_args to verify mode (client/server or bypass)
and whether to use Env Variables
and whether to use Env Variables
Build hash and submit request
See man page for options
@ -232,6 +232,8 @@ sub parse_args_xdsh
'q|show-config' => \$options{'show-config'},
'r|node-rsh=s' => \$options{'node-rsh'},
'i|rootimg=s' => \$options{'rootimg'},
'ip=s' => \$options{'ip'},
'show=s' => \$options{'show'},
's|stream' => \$options{'streaming'},
't|timeout=i' => \$options{'timeout'},
'v|verify' => \$options{'verify'},
@ -407,12 +409,12 @@ sub parse_args_xdsh
if ($options{'ssh-setup'}) # if going to setup ssh keys
{
my $msg;
if (!($ENV{'DSH_REMOTE_PASSWORD'}))
{ # if not already set
# prompt for the password for the userid on the node that will be setup
if (!($ENV{'DSH_REMOTE_PASSWORD'}) && !$options{'show'} )
{ # if not already set and not requested to just show the information,
# prompt for the password for the userid on the node that will be setup
my $userpw;
$msg =
"The ssh keys will be updated for '$to_userid' on the node(s).\nPassword:";
"Enter the password for the userid: $to_userid on the node where the ssh keys \nwill be updated:\n";
xCAT::MsgUtils->message("I", $msg);
system("stty -echo"); # turn off keyboard
chop($userpw = <STDIN>);
@ -573,9 +575,11 @@ sub parse_args_xdcp
'F|File=s' => \$options{'File'},
'h|help' => \$options{'help'},
'i|rootimg=s' => \$options{'rootimg'},
'l|user=s' => \$options{'user'},
'ip=s' => \$options{'ip'},
'l|user=s' => \$options{'user'},
'm|monitor' => \$options{'monitor'},
'o|node-options=s' => \$options{'node-options'},
'show=s' => \$options{'show'},
'q|show-config' => \$options{'show-config'},
'p|preserve' => \$options{'preserve'},
'r|c|node-rcp=s' => \$options{'node-rcp'},