HMC
To list HMC version info:
$ lshmc -v
To list HMC network info:
$ lshmc -v
To list HMC users:
$ lshmcusr
To create an HMC user. e.g.
$ mkhmcusr -u devnull -a hmcsuperadmin
Note: you can use a default role like hmcsuperadmin, hmcoperator, etc. or a custom taskrole you created before
To change an HMC user's password. e.g.
$ chhmcusr -u devnull -t passwd
To change an HMC user's role:
$ chhmcusr -u devnull -t taskrole -v hmcoperator -r
Managed Systems
To list all managed systems under HMC control and all their details:
$ lssyscfg -r sys
To see details of a single managed system, use -m. e.g.
$ lssyscfg -r sys -m ibm-p550-01
To see only certain details, you can use -F. e.g.
$ lssyscfg -r sys -m ibm-p550-01 -F "name,serial_num,state"
Note: you can use a separator other than ‘,' between fields.
To add a header (it helps at times), use --headers when using -F. e.g.
$ lssyscfg -r sys -m ibm-p550-01 -F "name,serial_num,state,ipaddr" --headers
To power on a system. e.g.
$ chsysstate -r sys -m ibm-p550-01 -o on
To power off a system. e.g.
$ chsysstate -r sys -m ibm-p550-01 -o off
Note: If you really have to, you can use the --immed flag for a fast power off.
To restart a system. e.g.
$ chsysstate -r sys -m ibm-p550-01 -o off --restart
Note: If you really have to, you can use the --immed flag for a fast power off.
LPARs
To list all the LPARs of a system, and all their details. e.g.
$ lssyscfg -r lpar -m ibm-p550-01
Note: Don't forget -F and/or --filter
To open up a virtual console for the LPAR. e.g.
$ mkvterm -m ibm-p550-01 -p lpar-01
Alternatively, you can use the interactive command:
$ vtmenu
To activate a profile and power on an LPAR. e.g.
$ chsysstate -r lpar -m ibm-p550-01 -o on -n lpar-01 -f profile-01
To power on an LPAR using its current profile. e.g.
$ chsysstate -r lpar -m ibm-p550-01 -o on -n lpar-01
To power off an LPAR. e.g.
$ chsysstate -r lpar -m ibm-p550-01 -o shutdown -n lpar-01
Note: you can use --immed for a fast power off
To restart an LPAR. e.g.
$ chsysstate -r lpar -m ibm-p550-01 -o shutdown -n lpar-01 --restart
Note: you can use --immed for a fast power off
To list all profiles of a specific LPAR. e.g.
$ lssyscfg -r prof -m ibm-p550 --filter "lpar_names=lpar-01″
To list a specific profile of a specific LPAR. e.g.
$ lssyscfg -r prof -m ibm-p550 --filter "lpar_names=lpar-01,profile_names=profile-01″
To change the default profile of an LPAR. e.g.
$ chsyscfg -r lpar -m ibm-p550 -i "name=lpar-01,default_profile=profile-02″
To create another profile based on the current profile of an LPAR. e.g.
$ mksyscfg -r prof -m ibm-p550-01 -o save -p lpar-01 -n profile-03
LPAR Profile changes
To change settings on an LPAR profile, use chsyscfg.
This could be your min/desired/max memory, processor units, or virtual processor settings, sharing mode, uncap weight, etc.
Here are a few examples:
Processor unit changes
$ chsyscfg -r prof -m ibm-p550-01 -i "name=profile-03,lpar_name=lpar-01,min_proc_units=0.5,desired_proc_units=1,max_proc_units=6″
Virtual processor changes
$ chsyscfg -r prof -m ibm-p550-01 -i "name=profile-03,lpar_name=lpar-01,min_procs=1,desired_procs=1,max_procs=6″
Memory changes
$ chsyscfg -r prof -m ibm-p550-01 -i "name=profile-03,lpar_name=lpar-01,min_mem=3072,desired_mem=3840,max_mem=6144″
Auto_start changes
$ chsyscfg -r prof -m ibm-p550-01 -i "name=profile-03,lpar_name=lpar-01,auto_start=1″
Dynamic changes to LPARs
Enough about profiles, let's make some dynamic changes now, but first, let's see what we have:
To list processor resources for the managed system. e.g.
$ lshwres -r proc -m ibm-p550-01 --level sys
To list memory resources for the managed system. e.g.
$ lshwres -r mem -m ibm-p550-01 --level sys
To list processor resources used by LPARs. e.g.
$ lshwres -r proc -m ibm-p550-01 --level lpar -F "lpar_name,curr_proc_units"
Note: Feel free to filter, or not filter data with -F.
To list memory resources used by LPARs. e.g.
$ lshwres -r mem -m ibm-p550-01 --level lpar -F "lpar_name,curr_mem"
Now, let's make changes. It all happens with the chhwres command.
There are 3 basic types of dynamic changes:
- add resources (-o a)
- remove resources (-o r)
- move resources between LPARs (-o m)
Here are some examples.
Dynamic changes to processing units:
To add 0.2 processing units to an LPAR. e.g.
$ chhwres -r proc -m ibm-p550-01 -o a -p lpar-01 -procunits 0.2
To remove 0.1 processing units from an LPAR. e.g.
$ chhwres -r proc -m ibm-p550-01 -o r -p lpar-01 -procunits 0.1
To move 0.1 processing units from lpar-01 to to lpar-02. e.g.
$ chhwres -r proc -m ibm-p550-01 -o m -p lpar-01 -t lpar-02 -procunits 0.1
Dynamic changes to dedicated processors:
To add 2 dedicated processor to an LPAR. e.g.
$ chhwres -r proc -m ibm-p550-01 -o a -p lpar-01 -procs 2
To remove 1 dedicated processor from an LPAR. e.g.
$ chhwres -r proc -m ibm-p550-01 -o r -p lpar-01 -procs 1
To move 1 dedicated processor from lpar-01 to to lpar-02. e.g.
$ chhwres -r proc -m ibm-p550-01 -o m -p lpar-01 -t lpar-02 -procs 1
Dynamic changes to memory:
To add 2048MB to an LPAR. e.g.
$ chhwres -r proc -m ibm-p550-01 -o a -p lpar-01 -q 2048
To remove 1024MB from an LPAR. e.g.
$ chhwres -r proc -m ibm-p550-01 -o r -p lpar-01 -q 1024
To move 2048MB from lpar-01 to to lpar-02. e.g.
$ chhwres -r proc -m ibm-p550-01 -o m -p lpar-01 -t lpar-02 -q 2048
Restoring LPAR resources
To restore LPAR resources back to the current profile settings, rsthwres is your friend.
Some examples:
To restore the processing resources of an LPAR according to its current profile. e.g.
$ rsthwres -r proc -m ibm-p550-01 -p lpar-01
To restore the memory resources of an LPAR according to its current profile. e.g.
$ rsthwres -r mem -m ibm-p550-01 -p lpar-01
To restore the processing resources of ALL LPARs according to their profile. e.g.
$ rsthwres -r proc -m ibm-p550-01
To restore the memory resources of ALL LPARs according to their profile. e.g.
$ rsthwres -r mem -m ibm-p550-01
'IBM > AIX' 카테고리의 다른 글
AIX 계정 패스워드 변경후 접속시 변경 (0) | 2015.12.14 |
---|---|
ssh 키젠 (rsa 키 교환) (0) | 2015.10.26 |
alt_disk_install (0) | 2013.09.09 |
vio 명령어 (0) | 2013.08.14 |
aix hosts 검색 순서 (netsvc.conf) (0) | 2013.07.18 |