User Tools

Site Tools


aix:hmc_cmd

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
aix:hmc_cmd [2021/11/17 10:53]
manu
aix:hmc_cmd [2024/03/29 11:49] (current)
manu
Line 9: Line 9:
 hmc@hscroot > mksysconn -o auto hmc@hscroot > mksysconn -o auto
 </​cli>​ </​cli>​
 +
 +
 +2. Server type, make and serial number do not update, vterm sessions fail to open.
 +Ensure you know the BMC admin password (Login to ASM). 
 +Remove the connection:
 +<cli prompt='#'>​
 +# rmsysconn -m <server name as shown in lssysconn -r all> -o r
 +</​cli>​
 +Add the connection back.
 +If the connection is DHCP private network:
 +<cli prompt='#'>​
 +# mksysconn -o auto
 +</​cli>​
 +Wait a few minutes, re-enter the password when prompted.
 +If the connection is static:
 +<cli prompt='#'>​
 +# mksysconn --ip <bmc ip> -u admin --passwd <admin password>​
 +</​cli>​
 +Wait several minutes for the VMI IP address to be discovered.
 +
 +3. System toggles from “Pending Authentication” to “No connection” and showing Password expired 0806-0000-00000000. ​ This is because the default user ID is admin and the default password is admin (the password is set to expired).
 +Set the ID and password that your HMC will use to authenticate and manage the system. This is the same ID and password that you will use to access the ASMI. To set the system password, select the BMC, then select Actions > Update System Password.
 +Helpful commands
 +
 +The lssysconn command will list both the eBMC and VMI IP addresses and connection states. ​ Each server must have a valid IP address for both.  The VMI address must show connected when the server is standby or operating.
 +<cli prompt='#'>​
 +# lssysconn -r all
 +resource_type=sys,​type_model_serial_num=9105-42A*13BEA00,​sp_type=ebmc,​ipaddr=192.168.128.215,​user_name=admin,​alt_ipaddr=unavailable,​state=Connected,​vmi_ipaddr=192.168.128.216,​vmi_state=Connected
 +</​cli>​
 +
 +To check the vmi configuration:​
 +<cli prompt='#'>​
 +# lssysconn -r vmi -m <server name>
 +resource_type=vmi,​type_model_serial_num=9105-42A*13BEA00,​interface=eth1,​ipv4addr=10.254.0.33,​gateway=0.0.0.0,​net_mask=255.255.255.0,​ipv4addr_orig=dhcp
 +resource_type=vmi,​type_model_serial_num=9105-42A*13BEA00,​interface=eth0,​ipv4addr=9.1.1.9,​gateway=9.1.1.1,​net_mask=255.255.255.0,​ipv4addr_orig=dhcp
 +</​cli>​
 +
 +To check for configuration errors:
 +<cli prompt='#'>​
 +lssyscfg -r sys -F name,​state,​state_detail
 +</​cli>​
 +
  
 ===== list UAK (update access key) on Power 8 and later ===== ===== list UAK (update access key) on Power 8 and later =====
Line 21: Line 63:
  
 ===== Basic command for HMC ===== ===== Basic command for HMC =====
 +
 +==== Open a virtual terminal on a LPAR/VIOS ====
  
 Open a terminal on a host using command line: Open a terminal on a host using command line:
 +
 +You can either use **vtmenu** easy to use, just select then the server and then the LPAR
 +
 +Or
 <cli prompt='#'>​ <cli prompt='#'>​
  ​mkvterm -m managed-system  ​mkvterm -m managed-system
Line 33: Line 81:
        Exit the Vterm using ~~.  or  ~.        Exit the Vterm using ~~.  or  ~.
 </​cli>​ </​cli>​
 +
 +==== List commands ====
 +
 +=== Power servers connected to the HMC ===
  
 To get the names of server(s) managed by an HMC: To get the names of server(s) managed by an HMC:
-<code>+<cli prompt='>'​>
 hscroot@sfohmc1:​~>​ lssyscfg -r sys -F name hscroot@sfohmc1:​~>​ lssyscfg -r sys -F name
 Server-9133-55A-SN062EEBH Server-9133-55A-SN062EEBH
 Server-9406-MMA-SN103A7C0 Server-9406-MMA-SN103A7C0
 Server-8233-E8B-SN0623B7P Server-8233-E8B-SN0623B7P
-</code>+</cli>
  
 To list LPAR names and LPAR profile names: To list LPAR names and LPAR profile names:
Line 51: Line 103:
 </​code>​ </​code>​
  
-  * Add a virtual FC adapter on VIOs and the targeted ​LPAR (Commands from the HMC+==== Add/remove an adapter on LPAR/VIOS ==== 
-  For the VIO + 
-(DLPAR vfc "server" ​on LABVIO01 into slot 34, for LPAR labaix01 ​slot 14)+<​code>​ 
 +Variable ​                                 Information needed: 
 +$MACHINE_NAME ​             Server-9009-22A-SN8675309 
 +$VIOS_NAME ​                       VIOS1 
 +$LPAR_NAME ​                      ​nim01 
 +$VIRTUAL_SLOT ​                 315 
 +$REMOTE_SLOT ​                 315 
 +$DEVICE TYPE                      fc (fibre), eth (ethernet), scsi (SCSI
 +$ADD_OR_REMOVE ​           a (add), r (remove) 
 +$SERVER_OR_CLIENT ​       ​server ​(Adding ​on VIOS), client (Adding on LPAR) 
 +</​code>​ 
 + 
 +List virtual ​slot type **fc** 
 +<cli prompt='>'>​ 
 +hscroot@sfohmc1:​~>​ lshwres -r virtualio --rsubtype fc --level lpar -m Server-8233-E8B-SN0623B7P 
 +lpar_name=vio1,​lpar_id=2,​slot_num=31,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=4,​remote_lpar_name=lpar1,​remote_slot_num=21 
 +lpar_name=vio1,​lpar_id=2,​slot_num=32,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=5,​remote_lpar_name=lpar2,​remote_slot_num=21 
 +lpar_name=vio1,​lpar_id=2,​slot_num=33,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=6,​remote_lpar_name=lpar3,​remote_slot_num=21 
 +lpar_name=vio1,​lpar_id=2,​slot_num=34,adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=7,​remote_lpar_name=lpar4,​remote_slot_num=21 
 +lpar_name=vio2,​lpar_id=3,​slot_num=31,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=4,​remote_lpar_name=lpar1,​remote_slot_num=22 
 +lpar_name=vio2,​lpar_id=3,​slot_num=32,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=5,​remote_lpar_name=lpar2,​remote_slot_num=22 
 +lpar_name=vio2,​lpar_id=3,​slot_num=33,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=6,​remote_lpar_name=lpar3,​remote_slot_num=22 
 +lpar_name=vio2,​lpar_id=3,​slot_num=34,​adapter_type=server,​state=1,​is_required=0,​remote_lpar_id=7,​remote_lpar_name=lpar4,​remote_slot_num=22 
 +lpar_name=lpar1,​lpar_id=4,​slot_num=21,​adapter_type=client,​state=1,​is_required=0,​remote_lpar_id=2,​remote_lpar_name=vio1,​remote_slot_num=31,"​wwpns=c0507602f66f0000,​c0507602f66f0001"​ 
 +lpar_name=lpar1,​lpar_id=4,​slot_num=22,​adapter_type=client,​state=1,​is_required=0,​remote_lpar_id=3,​remote_lpar_name=vio2,​remote_slot_num=31,"​wwpns=c0507602f66f0002,​c0507602f66f0003"​ 
 +</​cli>​ 
 + 
 +Adding a virtual fibre channel device to an LPAR:  
 +<cli prompt='#'>​ 
 +# chhwres -r virtualio -m $MACHINE_NAME -o $ADD_OR_REMOVE -p $VIOS_NAME --rsubtype $DEVICE TYPE -s $VIRTUAL_SLOT -a "​adapter_type=$SERVER_OR_CLIENT,​remote_lpar_name=$LPAR_NAME,​remote_slot_num=$REMOTE_SLOT"​ 
 +  
 +# chhwres -r virtualio -m Server-9009-22A-SN8675309 -o a -p VIOS1 --rsubtype fc -s 315 -a "​adapter_type=client,​remote_lpar_name=nim01,​remote_slot_num=315"​ 
 +</​cli>​ 
 + 
 +Adding a virtual fibre channel device to a VIO: 
 +<cli prompt='#'>​ 
 +# chhwres -r virtualio -m $MACHINE_NAME -o $ADD_OR_REMOVE -p $VIOS_NAME --rsubtype $DEVICE TYPE -s $VIRTUAL_SLOT -a "​adapter_type=$SERVER_OR_CLIENT,​remote_lpar_name=$LPAR_NAME,​remote_slot_num=$REMOTE_SLOT"​ 
 +  
 +# chhwres -r virtualio -m Server-9009-22A-SN8675309 -o a -p VIOS1 --rsubtype fc -s 315 -a "​adapter_type=server,​remote_lpar_name=nim01,​remote_slot_num=315"​ 
 +</​cli>​ 
 + 
 +Removing a virtual adapter in slot 315 from an LPAR or VIOS: 
 +<cli prompt='#'>​ 
 +# chhwres -r virtualio -m $MACHINE_NAME -o $ADD_OR_REMOVE -p $LPAR_NAME -s $VIRTUAL_SLOT 
 +  
 +# chhwres -r virtualio -m Server-9009-22A-SN8675309 -o r -p nim01 -s 315 
 +</​cli>​ 
 + 
 +Now save the runing config (it overwrites profile with actual running config) 
 +<cli prompt='#'>​ 
 +# mksyscfg -r prof -m <​MAN_SYS>​ -o save -p <​LPAR_NAME>​ -n <​PROFILE_NAME>​ --force ​      
 +</​cli>​ 
 + 
 +Removing a virtual adapter in slot 31 from an VIOS: 
 +<cli prompt='#'>​ 
 +# chhwres -r virtualio -m $MACHINE_NAME -o $ADD_OR_REMOVE -p $LPAR_NAME -s $VIRTUAL_SLOT 
 +  
 +# chhwres -r virtualio -m Server-9009-22A-SN8675309 -o r -p vios01 -s 31 
 +</​cli>​ 
 + 
 +Now save the runing config (it overwrites profile with actual running config)
 <cli prompt='#'>​ <cli prompt='#'>​
-chhwres ​-r virtualio ​-m lab-01-p740 -o a -s 34 -p LABVIO01 ​--rsubtype fc -a "​adapter_type=server,​remote_lpar_name=labaix01,​remote_slot_num=14"​+mksyscfg ​-r prof -m Server-9009-22A-SN8675309 ​-o save -p vios01 ​-n vios --force      ​
 </​cli>​ </​cli>​
  
-(Same into the profile of the VIOS)+Same into the profile of the VIOS (static applies only after profile is applied, when LPAR restart)
 <cli prompt='#'>​ <cli prompt='#'>​
 # chsyscfg -r prof -m lab-01-p740 -i '​name=vios,​lpar_id=1,"​virtual_fc_adapters+=""​34/​server/​6//​14//​1"""'​ # chsyscfg -r prof -m lab-01-p740 -i '​name=vios,​lpar_id=1,"​virtual_fc_adapters+=""​34/​server/​6//​14//​1"""'​
Line 68: Line 180:
 </​cli>​ </​cli>​
  
 +==== List commands ====
 <​code>​ <​code>​
-cybroot@sfohmc1:​~>​ lshwres -r virtualio --rsubtype fc --level lpar -m Server-8233-E8B-SN0623B7P -F lpar_name,​wwpns --header --filter lpar_names=lpar2+hscroot@sfohmc1:​~>​ lshwres -r virtualio --rsubtype fc --level lpar -m Server-8233-E8B-SN0623B7P -F lpar_name,​wwpns --header --filter lpar_names=lpar2
 lpar_name,​wwpns lpar_name,​wwpns
 lpar2,"​c0507602f66f0004,​c0507602f66f0005"​ lpar2,"​c0507602f66f0004,​c0507602f66f0005"​
Line 755: Line 868:
 name=normal,​lpar_name=NIM01,​lpar_id=11,​lpar_env=aixlinux,​all_resources=0,​min_mem=4096,​desired_mem=4096,​max_mem=8192,​min_num_huge_pages=0,​desired_num_huge_pages=0,​max_num_huge_pages=0,​mem_mode=ded,​hpt_ratio=1:​64,​proc_mode=shared,​min_proc_units=0.1,​desired_proc_units=0.2,​max_proc_units=2.0,​min_procs=1,​desired_procs=2,​max_procs=2,​sharing_mode=uncap,​uncap_weight=128,​shared_proc_pool_id=0,​shared_proc_pool_name=DefaultPool,​affinity_group_id=none,​io_slots=none,​lpar_io_pool_ids=none,​max_virtual_slots=20,"​virtual_serial_adapters=0/​server/​1/​any//​any/​1,​1/​server/​1/​any//​any/​1",​virtual_scsi_adapters=4/​client/​3/​VIOS03/​11/​1,"​virtual_eth_adapters=2/​0/​2//​0/​1/​ETHERNET0//​all/​none,​3/​0/​2//​0/​1/​ETHERNET0//​all/​none",​virtual_eth_vsi_profiles=none,​vtpm_adapters=none,"​virtual_fc_adapters=""​5/​client/​3/​VIOS03/​21/​c050760522210000,​c050760522210001/​1"",""​6/​client/​3/​VIOS03/​31/​c050760522210002,​c050760522210003/​1""",​hca_adapters=none,​boot_mode=norm,​conn_monitoring=0,​auto_start=0,​power_ctrl_lpar_ids=none,​work_group_id=none,​redundant_err_path_reporting=0,​bsr_arrays=0,​lhea_logical_ports=none,​lhea_capabilities=none,​lpar_proc_compat_mode=default,​electronic_err_reporting=null name=normal,​lpar_name=NIM01,​lpar_id=11,​lpar_env=aixlinux,​all_resources=0,​min_mem=4096,​desired_mem=4096,​max_mem=8192,​min_num_huge_pages=0,​desired_num_huge_pages=0,​max_num_huge_pages=0,​mem_mode=ded,​hpt_ratio=1:​64,​proc_mode=shared,​min_proc_units=0.1,​desired_proc_units=0.2,​max_proc_units=2.0,​min_procs=1,​desired_procs=2,​max_procs=2,​sharing_mode=uncap,​uncap_weight=128,​shared_proc_pool_id=0,​shared_proc_pool_name=DefaultPool,​affinity_group_id=none,​io_slots=none,​lpar_io_pool_ids=none,​max_virtual_slots=20,"​virtual_serial_adapters=0/​server/​1/​any//​any/​1,​1/​server/​1/​any//​any/​1",​virtual_scsi_adapters=4/​client/​3/​VIOS03/​11/​1,"​virtual_eth_adapters=2/​0/​2//​0/​1/​ETHERNET0//​all/​none,​3/​0/​2//​0/​1/​ETHERNET0//​all/​none",​virtual_eth_vsi_profiles=none,​vtpm_adapters=none,"​virtual_fc_adapters=""​5/​client/​3/​VIOS03/​21/​c050760522210000,​c050760522210001/​1"",""​6/​client/​3/​VIOS03/​31/​c050760522210002,​c050760522210003/​1""",​hca_adapters=none,​boot_mode=norm,​conn_monitoring=0,​auto_start=0,​power_ctrl_lpar_ids=none,​work_group_id=none,​redundant_err_path_reporting=0,​bsr_arrays=0,​lhea_logical_ports=none,​lhea_capabilities=none,​lpar_proc_compat_mode=default,​electronic_err_reporting=null
 </​code>​ </​code>​
 +
 +==== Configure Kerberos ====
 +
 +<cli prompt='>'>​
 +hscroot@hmc01:​~>​ chhmc -c kerberos -s remove –realm <​kerberos_hostname>​ -a <​kerberos_ip>​
 +hscroot@hmc01:​~>​ chhmc -c kerberos -s add --realm <​kerberos_hostname>​ -a <​kerberos_ip>​
 +</​cli>​
 +
 +==== Led management ====
 +
 +Turn off / on a LED on a server
 +<cli prompt='>'>​
 +hscroot@hmc01:​~>​ lssyscfg -r sys -F name
 +Power10_01_siteA
 +</​cli>​
 +
 +Check to see if the attention LED is active
 +<cli prompt='>'>​
 +hscroot@hmc01:​~>​ lsled -r sa -t phys -m Power10_01_siteA
 +state=on
 +</​cli>​
 +
 +Use the chled command to turn off the system attention LED
 +<cli prompt='>'>​
 +hscroot@hmc01:​~>​ chled -r sa -t phys -m Power10_01_siteA -o off
 +</​cli>​
 +
 +To check the status of system attention LED you can use the lsled
 +<cli prompt='>'>​
 +hscroot@hmc01:​~>​ lsled -r sa -t phys -m Power10_01_siteA ​
 +state=off
 +</​cli>​
 +
 +On partitions:
 +<cli prompt='>'>​
 +hscroot@hmc01:​~>​ lsled -r sa -t virtuallpar -m Power10_01_siteA ​
 +lpar_id=22,​lpar_name=AIXA001,​state=off
 +lpar_id=17,​lpar_name=AIXA002,​state=off
 +lpar_id=13,​lpar_name=AIXA003,​state=off
 +</​cli>​
 +
aix/hmc_cmd.1637142808.txt.gz · Last modified: 2021/11/17 10:53 by manu