Solved

Command line to define LPARs on HMC

Posted on 2011-09-06
3
2,005 Views
Last Modified: 2013-11-17
Hi, I am trying to use a scripted method to create LPARs on our P7 server via our HMC. I keep getting an error about 'the format of the configuration is invalid' and 'nest double quotes'.  I have tried various options but none want to work.

I have tried this using both the CLI with '-i' and also within a config file with 'f'.

Here are two examples of my code variation that fails;

 
mksyscfg -m P7SYSTEM -r lpar -i "name=LPAR01,profile_name=normal,lpar_env=aixlinux,\
all_resources=0,min_mem=1024,desired_mem=9216,max_mem=9216,proc_mode=shared,\
min_proc_units=0.3,desired_proc_units=1.0,max_proc_units=3.0,min_procs=1,\
desired_procs=3,max_procs=3,sharing_mode=uncap,uncap_weight=128,lpar_io_pool_ids=none,\
boot_mode=norm,conn_monitoring=0,auto_start=0,power_ctrl_lpar_ids=none,\
work_group_id=none,shared_proc_pool_util_auth=1,max_virtual_slots=20,\
"virtual_fc_adapters=21/client/2/VIOS1/21//1,41/client/2/VIOS2/41//1,\
22/client/1/VIOS1/22/1,42/client/2/VIOS2/42/1",\
"virtual_eth_adapters=196/0/200//1/1/ETHERNET0//all/none,\
197/0/201//1/1/ETHERNET0//all/none""

Open in new window


or

 
mksyscfg -m P7SYSTEM -r lpar -f testlpar.cfg

where testlpar.cfg looks like;

name=LPAR01
profile_name=normal
lpar_env=aixlinux
all_resources=0
min_mem=1024
desired_mem=9216
max_mem=9216
proc_mode=shared
min_proc_units=0.3
desired_proc_units=1.0
max_proc_units=3.0
min_procs=1
desired_procs=3
max_procs=3
sharing_mode=uncap
uncap_weight=128
lpar_io_pool_ids=none
boot_mode=norm
conn_monitoring=0
auto_start=0
power_ctrl_lpar_ids=none
work_group_id=none
shared_proc_pool_util_auth=1
max_virtual_slots=20
virtual_fc_adapters=21/client/2/VIOS1/21//1,41/client/2/VIOS2/41//1,22/client/1/VIOS1/22/1,42/client/2/VIOS2/42/1
virtual_eth_adapters=196/0/200//1/1/ETHERNET0//all/none,197/0/201//1/1/ETHERNET0//all/none

Open in new window


I am fairly sure I am close, just can't quite figure it out :-(

HMC is V7 r7.2.0.1


Cheers, JP.
0
Comment
Question by:popesy
  • 2
3 Comments
 
LVL 68

Accepted Solution

by:
woolmilkporc earned 250 total points
ID: 36487095
!) Command line

Add the two missing slashes and escape the nested quotes, like:

...
work_group_id=none,shared_proc_pool_util_auth=1,max_virtual_slots=20,\
\"virtual_fc_adapters=21/client/2/VIOS1/21//1,41/client/2/VIOS2/41//1,\
22/client/1/VIOS1/22//1,42/client/2/VIOS2/42//1\",\
\"virtual_eth_adapters=196/0/200//1/1/ETHERNET0//all/none,\
197/0/201//1/1/ETHERNET0//all/none\""

2) Configuration file

Add the two missing slashes, add commas at the line ends and enclose the attribute/value pairs which specify a list in double qoutes, like

name=LPAR01,
profile_name=normal,
lpar_env=aixlinux,
all_resources=0,
min_mem=1024,
desired_mem=9216,
max_mem=9216,
proc_mode=shared,
min_proc_units=0.3,
desired_proc_units=1.0,
max_proc_units=3.0,
min_procs=1,
desired_procs=3,
max_procs=3,
sharing_mode=uncap,
uncap_weight=128,
lpar_io_pool_ids=none,
boot_mode=norm,
conn_monitoring=0
auto_start=0,
power_ctrl_lpar_ids=none,
work_group_id=none,
shared_proc_pool_util_auth=1,
max_virtual_slots=20,
"virtual_fc_adapters=21/client/2/VIOS1/21//1,41/client/2/VIOS2/41//1,22/client/1/VIOS1/22//1,42/client/2/VIOS2/42//1",
"virtual_eth_adapters=196/0/200//1/1/ETHERNET0//all/none,197/0/201//1/1/ETHERNET0//all/none"

wmp
0
 
LVL 68

Expert Comment

by:woolmilkporc
ID: 36487266
Note:

You're setting max_virtual_slots to 20 but you're defining virtual slots with numbers 21, 41, 22, 42, 196 and 197.

That's wrong, because max_virtual_slots defines not only the number of slots but also the highest allowable slot number!

So either use lower virtual slot numbers or set max_virtual_slots at least to 197.
0
 
LVL 4

Author Closing Comment

by:popesy
ID: 36487511
Thanks wmp, I knew I wasn't far off!

JP
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In tuning file systems on the Solaris Operating System, changing some parameters of a file system usually destroys the data on it. For instance, changing the cache segment block size in the volume of a T3 requires that you delete the existing volu…
I have been running these systems for a few years now and I am just very happy with them.   I just wanted to share the manual that I have created for upgrades and other things.  Oooh yes! FreeBSD makes me happy (as a server), no maintenance and I al…
Learn how to find files with the shell using the find and locate commands. Use locate to find a needle in a haystack.: With locate, check if the file still exists.: Use find to get the actual location of the file.:
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

867 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

21 Experts available now in Live!

Get 1:1 Help Now