HMC & CMC

 View Only

HMC Management Enhancements in HMC V9 R1 M92x

By Karthikeyan Palanisamy posted Mon June 15, 2020 05:19 AM

  

With the introduction of POWER9 E950 & E980 systems, corresponding updates were made to HMC levels with V9 R1 M920/920.1/921. There were many enhancements done in the HMC V9 R1 M92x releases including HMC Management Enhancements. In this blog, we will talk in detail about some of the HMC Management Enhancements, most of which were to address customer requested Enhancements via RFE's (Request for Enhancement). 

Command Line Interface for Data Replication

Ever since the HMC had data replication functionality, there hasn’t been command line interface to configure data replication. As the number of HMC's increase in data centers, there is a need to automate some of the management functions with data replication being one of them. To address the requirement of automation and also to address RFE 91187 , starting from version V9 R1 M920, HMC supports command line interface for data replication. The two commands -chdatarep and lsdatarep have been introduced in HMC to configure data replication via CLI.

 

chdatarep - Change data replication settings for the HMC.

lsdatarep  - Lists data replication status and configuration of the HMC.

In this blog, we will go through all the settings of data replication in GUI and explain how the settings can be done using CLI.

Enable/Disable Data Replication:


HMC panel to enable and disable data replication

Enable or disable of data replication can be done using chdatarep command:

Enable data replication: 

chdatarep -o enable

Disable data replication: 

chdatarep -o disable

 

You can see the current state of data replication using lsdatarep command:

lsdatarep -t local

is_enabled=1,curr_warning_data_types=none,"avail_warning_data_types=pwdpolicy,user,kerberos,ldap,mfa"

Add or remove Data Source:

Panel to show the add and delete data source

chdatarep command can be used to add or delete data sources.

Add data source: chdatarep -o add -h vhmccloudvm110 

Delete data source: chdatarep -o remove -h vhmccloudvm110

 

You can view the list of all data sources using lsdatarep:

lsdatarep -t source

hmc_name=vhmccloudvm110,"hmc_ipaddrs=9.3.147.154,fe80:0:0:0:5054:ff:fe52:1148%eth0",is_communicating=1,curr_data_types=none,"avail_data_types=pwdpolicy,user,kerberos,ldap"

 

This command can be used with filter to list particular data sources:

lsdatarep -t source --filter "\"hmc_names=vhmccloudvm110\""

Configure customizable data types for a data source:


Panel to show the datas to be replicated

Customizable data types can be configured for a data source using chdatarep:

chdatarep -o set -h vhmccloudvm110 -i “\"data_types=user\””

Add additional data types: chdatarep -o set -h vhmccloudvm110 -i "data_types+=ldap,kerberos"

Remove a configured data types: chdatarep -o set -h vhmccloudvm110 -i "data_types-=kerberos”

 

You can also set the customizable data types while adding data source itself using:

chdatarep -o add -h  vhmccloudvm110 -i "\”data_types=user,ldap\”"

 

You can see the list of configurable and also configured customizable data types for all data sources using lsdatarep command:

lsdatarep -t source

hmc_name=vhmccloudvm110,"hmc_ipaddrs=9.3.147.154,fe80:0:0:0:5054:ff:fe52:1148%eth0",is_communicating=1,"curr_data_types=user,ldap","avail_data_types=pwdpolicy,user,kerberos,ldap"

 

curr_data_types: shows list of data types that are configured for the data source

avail_data_types: shows list of all the data types that can be configured for the data source

Configure local customizable data change warnings:

Panel to show local data replcation warning

This can be achieved in CLI through chdatarep:

chdatarep -o set -i "\"warning_data_types=user,ldap\""

Add additional data change warnings: chdatarep -o set -i "\"warning_data_types+=kerberos\""

Remove data change warnings: chdatarep -o set -i "\"warning_data_types-=kerberos\""

 

You can also set the data change warnings at the time of enabling data replication.

chdatarep -o enable -i ""warning_data_types=ldap,user""

 

You can see the list of all local customizable data change warnings and also configured data change warnings using lsdatarep command:

lsdatarep -t local

is_enabled=1,"curr_warning_data_types=user,ldap","avail_warning_data_types=pwdpolicy,user,kerberos,ldap,mfa"

 

curr_warning_data_types: shows list of data types that are configured for data change warnings

avail_warning_data_types: shows list of all the data types that can be configured for data change warnings

Status:


Status of the data replicaton.

The status of data sources and data can be seen using lsdatarep command. 

Communication status of data source (portion A in above picture) can be seen using: 

lsdatarep -t source

hmc_name=vhmccloudvm110,"hmc_ipaddrs=9.3.147.154,fe80:0:0:0:5054:ff:fe52:1148%eth0",is_communicating=1,"curr_data_types=user,ldap","avail_data_types=pwdpolicy,user,kerberos,ldap"

The data status and the slave HMCs that are out of sync can be seen using: 

lsdatarep -t data

data_type=pwdpolicy,level=0,updated_since_start=0,not_in_sync_slaves=

data_type=user,level=0,updated_since_start=1,updated_time=09/25/2018 15:50:18,source_hmc_name=vhmccloudvm110,not_in_sync_slaves=

data_type=kerberos,level=0,updated_since_start=0,not_in_sync_slaves=

data_type=ldap,level=0,updated_since_start=1,updated_time=09/25/2018 15:50:18,source_hmc_name=vhmccloudvm110,not_in_sync_slaves=

data_type=mfa,level=0,updated_since_start=0,not_in_sync_slaves=

Push and sync:


Panel to show the options to push data to master/slave

Push to Slaves and Sync from Master are used when the data is out of sync. 

Push is used from master HMC to push the latest data to all slaves. The command to push the data to slaves is:

chdatarep -o push

 

Sync is used from slave HMC to get the latest data from the master HMC. The command to sync the data from master is:

chdatarep -o sync

Save/Restore across platform (x86/ppc64le) and Hardware appliance/vHMC

It's great that you can manage your Power Systems with an Hardware Management Console that is hosted on a POWER platform, starting with HMC version 8.8.7.  But here the challenge is how can you seamlessly transition from managing your systems with x86 HMC to Power HMC without having to create all the HMC settings or configurations from scratch.  In order to help you with the transition, HMC version V9 R1 M920 has come up with enhanced saveupgdata and rstupgdata commands which you can use to easily migrate HMC’s data to different HMC appliance. Please note that minimum level required to use this function is HMC V9 R1 M940. 

 

Enhanced command syntax of saveupgdata and rstupgdata

saveupgdata:

saveupgdata -r disk | diskusb | diskftp | disksftp

                         [-h <host name>]

                         [-u <user ID>]

                         [--passwd <password>]

                         [-k <SSH private key>]

                         [-d <remote directory>]

                         [--migrate]

                         [-i <additional data>]

                         [--force]

                         [--help]

 

Saves Hardware Management Console (HMC) upgrade data.

 

    -r                                          - the location where the upgrade data will be saved:

                                                       disk         - HMC hard drive only

                                                       diskusb  - USB data storage device and HMC hard

                                                                          drive

                                                       diskftp   - FTP server and HMC hard drive

                                                       disksftp - secure FTP (SFTP) server and HMC hard

                                                                          drive

    -h <host name>               - the host name or IP address of the remote server

                                                    where the upgrade data will be saved

    -u <user ID>                     - the user ID to use to log in to the remote server

    --passwd <password>   - the password to use to log in to the remote server

    -k <SSH private key>     - the SSH private key file

    -d <remote directory>  - the directory on the remote server where the

                                                    upgrade data will be saved

    --migrate                          - include data for migrating the HMC to another HMC

    -i <additional data>    - additional data to include in the migration data

                                                         netcfg      - network configuration data

                                                         perfmon - performance monitoring data

    --force                                - force the migration operation for an HMC managing

                                                    a Power enterprise pool

    --help                                  - prints this help

 

The new parameter - ‘--migrate tells HMC to save HMC Configuration data in order to migrate to another HMC appliance.  By default, the command doesn’t save network configuration and performance monitoring data when you use with --migrate.  If you want to migrate network settings and performance monitoring data, you need to use ‘-i’ parameter.  ‘-i network’ to save network data, ‘-i perfom’ to save performance monitoring data and ‘-i “network,perfmon” ’ to save both network and performance monitoring data.

 

 ‘--force’ parameter will be handy in case the HMC is managing CoD pool.  If HMC is a managing a CoD pool, then ‘saveupgdata --migrate’ shows a warning message saying “This HMC is a managing HMC for a Power enterprise pool. Please remove this HMC from the pool prior to performing the save upgrade data operation unless you want this HMC to continue managing the pool. After performing the restore upgrade data operation on the Power HMC, you can add the Power HMC to the Power enterprise pool.” and continues to save the HMC data required for migration.  But if HMC is the master HMC managing a CoD pool, then ‘saveupgdata --migrate’ fails with an error “This HMC is a master HMC for a Power enterprise pool. Please set a new master HMC for the pool and remove this HMC from the pool prior to performing the save upgrade data operation unless you want this HMC to continue managing the pool. After performing the restore upgrade data operation on the Power HMC, you can add the Power HMC to the Power enterprise pool and set it as the master HMC for the pool.”.  In this case where HMC is a master HMC of a CoD pool and still you want to go ahead with migrating the data to another HMC appliance, ‘--force’ can be used to force the operation.

 

rstupgdata:

rstupgdata -r dvd | usb | ftp | sftp

                        [-h <host name>]

                        [-u <user ID>]

                        [--passwd <password>]

                        [-k <SSH private key>]

                        [-d <remote directory>]

                        [--migrate]

                        [--help]

 

Restores Hardware Management Console (HMC) upgrade data.

 

    -r                                        - the location from where the upgrade data will be

                                                  retrieved:

                                                      dvd  - DVD-RAM media

                                                      usb  - USB data storage device

                                                      ftp  - FTP server

                                                      sftp - secure FTP (SFTP) server

    -h <host name>              - the host name or IP address of the remote server

                                                   from where the upgrade data will be retrieved

    -u <user ID>                    - the user ID to use to log in to the remote server

    --passwd <password>  - the password to use to log in to the remote server

    -k <SSH private key>    - the SSH private key file

    -d <remote directory> - the directory on the remote server from where the

                                                  upgrade data will be retrieved

    --migrate                          - include data for migrating the HMC to another HMC

    --help                                 - prints this help

 

The new parameter ‘--migrate’ tells the HMC to deploy the data that has been collected on different appliance.

How to migrate HMC data from one appliance to another:

In order to migrate data from one HMC appliance to another, you need to make sure that the both HMC appliances are installed with HMC level V9 R1 M920.1 (PTF MH01787/MH01788) or higher.  Now follow the below steps to migrate HMC data from one appliance to other:

Step 1: Run  ‘saveupgdata’ command with ‘--migrate’ to save HMC data from source HMC. (Do not forget to add -i “network,perfmon” if you want to include network and performance monitoring data)

Step 2: On the target HMC, run ‘rstupgdata’ command including the details where the data has been saved (in Step 1) along with ‘--migrate’.

Step 3: Restart destination HMC using ‘hmcshutdown -r -t now’.  After reboot, destination HMC appliance will have all the data/settings of source HMC.

 

Using these 3 simple steps, you can easily migrate settings from your x86 appliance to Power based HMC appliance (either hardware or virtual)

Network Redundancy in HMC through Network Bonding

What is Network Bonding?

Bonding is a software way of achieving network redundancy by enabling two or more network interfaces to act as one, simultaneously increasing the bandwidth and providing redundancy. This is a great way of achieving redundancy to a server. If one physical NIC is down or unplugged, it will automatically move resource to other NIC card. Bonding will work with the help of bonding driver in kernel.

 

Below Figure shows a bond adapter bond1 is created with interfaces eth0 and eth1


Image to show the bond concept

How to configure Network Bonding in HMC:

HMC supports configuring network bonding via GUI and CLI.

Configuring Network Bond through Change Network Settings Panel:

In 'Change Network Settings Panel (HMC Management > Console Settings > Change Network Settings)', there is a new tab added called Bond LAN Adapters.  When you click on this tab, you will be able to see the list of bond adapters in HMC if it is configured and options to create, edit and delete a bond adapter.


Panel to show the list of bond adaptersWhen no bond is configured the list will be empty like shown in above figure, with only create button enabled to create a new bond. When you click on the Create button, a new pop-up will appear as shown in Figure below to enter the new bond details.
Panel to modify the bond adapter details

In this panel we have two lists - one on the left side is "List of Bonds" holds the list of interfaces to be added as part of new network bond. The other list “List of Available Adapters” has the list of available interfaces in the HMC. You can select any interface from "List of Available Adapters" and click "Add" to make it part of the Network Bond. After adding the desired interfaces to the bond, next step is to assign the IP address and network mask for the bond. This configuration can be taken from one of the configured interfaces by "Choosing Obtain an IP address from Interface" and selecting one of the interfaces in the selected list. Or you can specify new values by choosing "Specify an IP address" option. In this same panel there is one more tab 'Firewall Settings', which is used to configure the firewall settings for the new bond interface.

 

Panel to edit the firewall details of the bond adapter

After selecting the firewall options, which is like the LAN Adapter configuration, and clicking on "OK" button, the bond configuration will be added to the 'Bond LAN Adapter' panel and again clicking "OK" in 'Bond LAN Adapter' panel will create and configured the Network Bond Interface.

Creating the Network Bonding through CLI:

chhmc command is enhanced to perform bond creation, modify and remove operations. 

Creating a network bond Interface:

chhmc -c netbond -s add -i <comma separated list of interfaces> [-nm <Netmask> -g <gateway>  -a <IPv4-address>][--source <interface>]

           -i : accept comma separated values of the interfaces which is to be the part of bond, like eth0,eth1

 

We can configure the netmask, gateway and ip address for bonding either by mentioning the values using -nm , -g and -a parameters or by mentioning --source with a configured interface name, from where the ip address , netmask and gateways values can be taken. 

Modifying a network bond Interface:

chhmc -c netbond -s modify -b <bondName> [-i <comma separated list of interfaces>] [-nm <Netmask> -g <gateway> -a {IPv4-address}]

            -b <bondName>: The bond name which we are going to modify 

            -i <interfaces>: The new list of interfaces for the bond

Removing a network bond Interface:

To remove a existing bonding, use the below command; in "-b" mention the bond name which need to be removed.

chhmc -c netbond -s remove -b <bondname>

Listing Network Bond Interfaces:

To list the details of bond interface, use the below command

lshmc --netbond

Contacting the PowerVM Team

Have questions for the PowerVM team or want to learn more? Follow our discussion group on LinkedIn IBM PowerVM

 

0 comments
38 views

Permalink