Jump to content United States-English
HP.com Home Products and Services Support and Drivers Solutions How to Buy
» Contact HP
More options
HP.com home
Designing Disaster Tolerant High Availability Clusters: > Chapter 4 Building a Metropolitan Cluster Using MetroCluster/SRDF

Configuring MC/ServiceGuard Packages for Automatic Disaster Recovery

» 

Technical documentation

Complete book in PDF
» Feedback
Content starts here

 » Table of Contents

 » Glossary

 » Index

Before you can implement these procedures you must:

  • Configure your cluster according to disaster tolerant architecture guidelines outlined in “Designing a Disaster Tolerant Architecture for use with MetroCluster/SRDF”.

  • Configure the MC/ServiceGuard cluster according to the procedures outlined in Managing MC/ServiceGuard (part number B3936-90024).

  • Create the SymCLI database, and build Symmetrix device groups, consistency groups, and gatekeepers for each package. Export exclusive volume groups for each package as described in “Preparing a Cluster for MetroCluster/SRDF”. This must be done on each node that will potentially run the package.

  • Install the MetroCluster with EMC SRDF product on all nodes according to the instructions in the MetroCluster with EMC SRDF Release Notes.

When you have completed these steps, packages will be able to automatically fail over to an alternate node in another data center and still have access to the data it needs to function.

This procedure must be repeated on all the cluster nodes for each MC/ServiceGuard application package so the application can failover to any of the nodes in the cluster. Customizations include setting environment variables and supplying customer-defined run and halt commands, as appropriate. The package control script must also be customized for the particular application software that it will control. Consult Managing MC/ServiceGuard for more detailed instructions on how to start, halt, and move packages and their services between nodes in a cluster.

For ease of troubleshooting, you may want to configure and test one package at a time.

  1. Create a directory /etc/cmcluster/package_name for each package and copy /opt/cmcluster/toolkits/SGSRDF/srdfpkg.cntl to the package directory:

    # cp /opt/cmcluster/toolkits/SGSRDF/srdfpkg.cntl /etc/cmcluster/package_name

    If you haven't already, copy the scripts in the Samples directory to another directory (e.g., /etc/cmcluster/SGSRDF). Change the name of srdfpkg.cntl to package_name.cntl.

  2. Create an MC/ServiceGuard package configuration file with the commands:

    # cd /etc/cmcluster/package_namecmmakepkg -p package_name.ascii

    Each package should have its own directory and uniquely named control script.

    NOTE: Do not create an MC/ServiceGuard package control script template with the cmmakepkg -s command or by using SAM. The package control script template included with this product (/opt/cmcluster/toolkits/SGSRDF/srdfpkg.cntl) should be copied to the package directory and used instead.
  3. In the package_name.ascii file, list the node names in the order in which you want the package to fail over. It is recommended for performance reasons, that you have the package fail over locally first, then to the remote data center. Be sure to set the MAX_CONFIGURED_PACKAGES parameter to 1 or more, depending on the number of packages that will run on the cluster.

    This toolkit may increase package startup time by 5 minutes or more. Packages with many disk devices will take longer to start up than those with fewer devices due to the time needed to get device status from the Symmetrix. Clusters with multiple packages that use devices on the Symmetrix will all cause package startup time to increase when more than one package is starting at the same time.

    The value of RUN_SCRIPT_TIMEOUT in the package ASCII file should be set to NO_TIMEOUT or to a large enough value to take into consideration the extra startup time due to getting status from the Symmetrix.

  4. Customize the control script as appropriate to your application using the guidelines in Managing MC/ServiceGuard. Standard MC/ServiceGuard package customizations include modifying the VG, LV, FS, IP, SUBNET, SERVICE_NAME, SERVICE_CMD and SERVICE_RESTART parameters. Be sure to set LV_UMOUNT_COUNT to 1 or greater.

  5. Further customize the control script for use with EMC SRDF as follows:

    1. Add the path where the SymCLI software binaries have been installed to the PATH environment variable. If the software is in the usual location, /usr/symcli/bin, you can just uncomment the line in the script.

    2. Uncomment AUTOR1RWNL, AUTOR1UIP, AUTOR2RWNL and AUTOR2WDNL environment variables. It is recommended that you retain the default values of these variables unless you have a specific business requirement to change them. See Appendix A for an explanation of these variables.

    3. Uncomment the PKGDIR variable and set it to the full path name of the directory where the control script has been placed. This directory must be unique for each package and is used for status data files. For example, set PKGDIR to /etc/cmcluster/package_name, removing any quotes around the file names.

    4. Uncomment the PKGR1SYMGRP and PKGR2SYMGRP variables and set them to the Symmetrix device group names for local and remote EMC Symmetrix disk arrays given in the symdg list command.

      NOTE: If you are using an M by N configuration, configure these variables PKGR1SYSMGRP and PKGR2SYSMGRP with the names of the consistency groups.
    5. Uncomment the R1HOST array variable and set the elements to the node names of the systems on the R1 side of the SRDF link. The order of the node names is not important.

    6. Uncomment the R2HOST array variable and set the elements to the node names of the systems on the R2 side of the SRDF link. The order of the node names is not important.

    7. Uncomment the RETRY and RETRYTIME variables. These variables are used to decide how often and how many times to retry the Symmetrix status commands. The defaults should be used for the first package. For other packages RETRYTIME should be altered to avoid contention when more than one package is starting on a node. RETRY * RETRYTIME should be approximately five minutes to keep package startup time under 5 minutes.

       RETRYTIMERETRY
      pkgA60 seconds5 attempts
      pkgB43 seconds7 attempts
      pkgC33 seconds9 attempts

    8. Uncomment the CLUSTERTYPE variable and set it to METRO. (The value CONTINENTAL is only for use with the ContinentalClusters product, described in Chapter 5.)

    9. If you are using an M by N configuration, be sure that the variable CONSISTENCYGROUPS is set to 1 in the control script:

      CONSISTENCYGROUPS=1

  6. Add customer-defined run and halt commands in the appropriate places by modifying the RUN_SCRIPT and HALT_SCRIPT parameters according to the needs of the application. Include the full pathname of the control script:

    /etc/cmcluster/package_name/package_name.cntl.

    See Managing MC/ServiceGuard for more information on these functions.

  7. Distribute MetroCluster with EMC SRDF control script files to other nodes in the cluster by using ftp or rcp:

    # rcp -p /etc/cmcluster/package_name/package_name.cntl \
    other_node:/etc/cmcluster/package_name/package_name.cntl

    See the example script ftpit to see how to semi-automate the copy using ftp. This script assumes the package directories already exist on all nodes.

  8. Split the SRDF logical links for the disks associated with the application package. See the script pre.cmquery for an example of how to automate this task. The script must be customized with the Symmetrix device group names.

    When using SRDF, the devices on the R2 side of the SRDF link are normally read-only. Before running cmquerycl and cmapplyconf, you must first split the SRDF logical link for all disk devices that are to be configured in MC/ServiceGuard packages. The links are then re-established once the new configuration has been applied.

  9. Check the configuration using the cmcheckconf -P package_name.ascii, then apply the MC/ServiceGuard configuration using the cmapplyconf -P package_name.ascii command or SAM.

  10. Restore the SRDF logical links for the disks associated with the application package. See the script Samples/post.cmapply for an example of how to automate this task. The script must be customized with the Symmetrix device group names. You may want to redirect the output of this script to a file for debugging purposes.

  11. Verify that each node in the MC/ServiceGuard cluster has the following files in the directory /etc/cmcluster/package_name:

    package_name.cntl (MC/ServiceGuard package control script)

    package_name.ascii (MC/ServiceGuard package ASCII config file)

    Any other scripts you use to manage MC/ServiceGuard packages.

The cluster is ready to switch packages automatically to nodes in remote data centers using MetroCluster/SRDF.

Printable version
Privacy statement Using this site means you accept its terms Feedback to webmaster
© Hewlett-Packard Development Company, L.P.