Use MC/ServiceGuard cluster system commands to register the package and to check that it has been registered correctly.
Refer to the MC/ServiceGuard manual for details on these commands.
Procedure
This section explains the procedure for registering the package and checking that it has been registered correctly.
1) Store the script files
Package configuration scripts can be stored on either the active node or the standby node, but package control scripts and package monitoring scripts must be stored on all nodes (active and standby).
Store the package control script in the location specified in the package configuration file, and save the package monitoring script in the location specified in the package control script, as shown in the following example.
For 1:1 active/standby configurations
Package configuration file
Active node "hp01": "/etc/cmcluster/omgr/omgr.conf"
Package control script
Active node "hp01": "/etc/cmcluster/omgr/omgr.sh"
Standby node "hp02": "/etc/cmcluster/omgr/omgr.sh"
Package monitoring script
Active node "hp01": "/etc/cmcluster/omgr/omgr.fmonitor"
Standby node "hp02": "/etc/cmcluster/omgr/omgr.fmonitor"
For N:1 active/standby configurations (if there are three active nodes)
Package configuration file
Active node "hp01": "/etc/cmcluster/omgr/omgr1.conf"
Active node "hp02": "/etc/cmcluster/omgr/omgr2.conf"
Active node "hp03": "/etc/cmcluster/omgr/omgr3.conf"
Package control script
Active node "hp01": "/etc/cmcluster/omgr/omgr1.sh"
Active node "hp02": "/etc/cmcluster/omgr/omgr2.sh"
Active node "hp03": "/etc/cmcluster/omgr/omgr3.sh"
Standby node "hpsub": "/etc/cmcluster/omgr/omgr1.sh"
Standby node "hpsub": "/etc/cmcluster/omgr/omgr2.sh"
Standby node "hpsub": "/etc/cmcluster/omgr/omgr3.sh"
Package monitoring script
Active node "hp01": "/etc/cmcluster/omgr/omgr1.fmonitor"
Active node "hp02": "/etc/cmcluster/omgr/omgr2.fmonitor"
Active node "hp03": "/etc/cmcluster/omgr/omgr3.fmonitor"
Standby node "hpsub": "/etc/cmcluster/omgr/omgr1.fmonitor"
Standby node "hpsub": "/etc/cmcluster/omgr/omgr2.fmonitor"
Standby node "hpsub": "/etc/cmcluster/omgr/omgr3.fmonitor"
For dual node mutual standby configurations
Package configuration file
Active node "hp01": "/etc/cmcluster/omgr/omgr1.conf"
Active node "hp02": "/etc/cmcluster/omgr/omgr2.conf"
Package control script
Active node "hp01": "/etc/cmcluster/omgr/omgr1.sh"
Active node "hp02": "/etc/cmcluster/omgr/omgr2.sh"
Standby node "hp02": "/etc/cmcluster/omgr/omgr1.sh"
Standby node "hp01": "/etc/cmcluster/omgr/omgr2.sh"
Package monitoring script
Active node "hp01": "/etc/cmcluster/omgr/omgr1.fmonitor"
Active node "hp02": "/etc/cmcluster/omgr/omgr2.fmonitor"
Standby node "hp02": "/etc/cmcluster/omgr/omgr1.fmonitor"
Standby node "hp01": "/etc/cmcluster/omgr/omgr2.fmonitor"
2) Verify the package configuration file
Execute the MC/ServiceGuard cmcheckconf command on the node where the package configuration file has been saved to check whether the package configuration file is correct.
# cmcheckconf -P /etc/cmcluster/omgr/omgr.conf
3) Register the package configuration file
Execute the MC/ServiceGuard cmapplyconf command on the node where the package configuration file has been saved to register the package configuration file.
# cmapplyconf -v -P /etc/cmcluster/omgr/omgr.conf
Enter "y" when the "Modify the package configuration ([y]/n)?" message is output.
This completes the package registration.
4) Check the registered information
Use the following command to check whether the information in the package configuration file has been registered correctly.
# cmviewconf
Check the display after "Package information:" to see whether the package name, package control script, package monitoring script, active node, and standby node have been registered correctly.
The following display example is for a 1:1 active/standby configuration.
Package information: package ID 56321: package name: omgr (omitted) package run script: /etc/cmcluster/omgr/omgr.sh package run timeout: (No Timeout) package halt script: /etc/cmcluster/omgr/omgr.sh package halt timeout: (No Timeout) package primary node: hp01 package alternate node: hp02
Check the operation status of each node using the following command:
# cmviewcl
Make sure that the "STATUS" and "STATE" of each "NODE" are "up" and "running".
The following display example is for a 1:1 active/standby configuration.
CLUSTER STATUS cluster1 up NODE STATUS STATE hp01 up running hp02 up running PACKAGE STATUS STATE PKG_SWITCH NODE omgr down halted disabled unowned
Check the switch status of each node using the following command:
# cmviewcl -v -p omgr
Check the "Node_Switching_Parameters: " section and make sure that "SWITCHING" is enabled for each "NODE_TYPE ".
The following display example is for a 1:1 active/standby configuration.
PACKAGE STATUS STATE PKG_SWITCH NODE omgr down halted disabled unowned (omitted) Node_Switching_Parameters: NODE_TYPE STATUS SWITCHING NAME Primary up enabled hp01 Alternate up enabled hp02
Verify the entire cluster system by repeating steps 2) through 4) "N" times for N:1 active/standby configurations and twice for dual node mutual standby configurations on the nodes where the package configuration files have been saved.