Monday, 15 April 2013

HMC Tips II - Partitions and Profiles


1. To list all machines configured in a hmc

# lssyscfg -r sys

2. To list all lpars(partitions) in a power machine

# lssyscfg -r lpar -m Managed_System

3. To activate/start an LPAR :

# chsysstate -r lpar -m Managed_System -o on -n LPAR_Name -f Profile_ name

4. To deactivate/shutdown an LPAR :

# chsysstate -r lpar -m Managed_System -o shutdown --immed -n LPAR_Name

5. To open the console of a partition :

# mkvterm -m Managed_System -p LPAR_Name

6. To close the console of a partition: 

# rmvterm -m Managed_System -p LPAR_Name

7. To list the profile of a partition:

# lssyscfg -r prof -m Managed_System --filter "lpar_names=LPAR_Name,profile_names=Profile_Name"

8. To change the min/desired/maximum memory settings of a partition profile :

# chsyscfg -r prof -m Managed_System -i "name=Profile_Name,lpar_name=LPAR_Name,min_mem=512,desired_mem=19456,max_mem=20480"

9. To change the min/desired/maximum processor units of a partition profile :

# chsyscfg -r prof -m Managed_System -i "name=Profile_Name,lpar_name=LPAR_Name,min_proc_units=0.2,desired_proc_units=0.5,max_proc_units=2.0"

10. To change the min/desired/maximum virtual processor of a partition profile :

# chsyscfg -r prof -m Managed_System -i "name=Profile_Name,lpar_name=LPAR_Name,min_procs=1,desired_procs=2,max_procs=6"

11. To change capped/uncapped setting in a partition profile :


# chsyscfg -r prof -m Managed_System -i "name=Profile_Name,lpar_name=LPAR_Name,sharing_mode=uncap,uncap_weight=128"

Possible values for sharing_mode are cap and uncap.
Possible values for uncap_weight are from 0 to 128.

12. To change the name of a partition profile :

# chsyscfg -r prof -m Managed_System -i "name=Profile_Name,lpar_name=LPAR_Name,new_name=New_Profile_Name"

13. To change the name of a partition :

# chsyscfg -r lpar -m Managed_System -i "name=LPAR_Name,new_name=New_LPAR_Name"

14. To change the default profile of a partition :

# chsyscfg -r lpar -m Managed_System -i "name=LPAR_Name,default_profile=Partition_Profile_Name"

15. To set "power off the machine after all partitions are shutdown" for a power machine :

# chsysscfg -r sys -m Managed_System -i "power_off_policy=0"

Possible values are

0 -> Power off after all partitions are shutdown
1 -> Do not power off after all partitions are shutdown

16. To rename a system profile :

# chsyscfg -r sysprof -m Managed_System -i name=Sys_Prof_Name,new_name=New_Sys_Prof_Name"

17. To add 2 more partition profiles to a system profile :

# chsyscfg -r sysprof -m Managed_System -i "name=,"lpar_names+=partition3,partition4",
"profile_names+=profile3,profile4""

0 blogger-disqus:

Post a Comment