Sun Cluster Geographic Edition Data Replication Guide for Hitachi TrueCopy and Universal Replicator

Chapter 2 Administering Hitachi TrueCopy and Universal Replicator Protection Groups

This chapter contains the procedures for configuring and administering data replication with Hitachi TrueCopy and Universal Replicator software. The chapter contains the following sections:

Strategies for Creating Hitachi TrueCopy and Universal Replicator Protection Groups

Before you begin creating protection groups, consider the following strategies:

The following sections describe the steps for each strategy.

Creating a Protection Group While the Application Is Offline

To create a protection group while the application resource group is offline, complete the following steps.

Creating a Protection Group While the Application Is Online

To add an existing application resource group to a new protection group without taking the application offline, complete the following steps on the cluster where the application resource group is online.

Complete the following steps on the other cluster.


Example 2–1 Creating a Hitachi TrueCopy or Universal Replicator Protection Group While the Application Remains Online

This example creates a protection group without taking the application offline.

In this example, the apprg1 resource group is online on the cluster-paris cluster.

  1. Create the protection group on cluster-paris.


    phys-paris-1# geopg create -d truecopy -p Nodelist=phys-paris-1,phys-paris-2 \
    -o Primary -s paris-newyork-ps tcpg
    Protection group "tcpg" has been successfully created
  2. Add the device group, tcdg, to the protection group.


    phys-paris-1# geopg add-device-group -p fence_level=async tcdg tcpg
    
  3. Activate the protection group locally.


    phys-paris-1# geopg start -e local tcpg
    Processing operation.... this may take a while....
    Protection group "tcpg" successfully started.
  4. Add to the protection group an application resource group that is already online.


    phys-paris-1# geopg add-resource-group apprg1 tcpg
    Following resource groups were successfully inserted:
    			"apprg1"
  5. Verify that the application resource group was added successfully.


    phys-paris-1# geoadm status
    Cluster: cluster-paris
    
       Partnership "paris-newyork-ps"    : OK
          Partner clusters               : newyork
          Synchronization                : OK
          ICRM Connection                : OK
    
          Heartbeat "hb_cluster-paris~cluster-newyork" monitoring \
    "paris-newyork-ps" OK
             Plug-in "ping-plugin"       : Inactive
             Plug-in "tcp_udp_plugin"    : OK
    
       Protection group "tcpg"           : Degraded
          Partnership                    : paris-newyork-ps
          Synchronization                : OK
    
          Cluster cluster-paris          : Degraded
             Role                        : Primary
             Configuration               : OK
             Data replication            : Degraded
             Resource groups             : OK
    
          Cluster cluster-newyork        : Unknown
             Role                        : Unknown
             Configuration               : Unknown
             Data Replication            : Unknown
             Resource Groups             : Unknown
  6. On a node of the partner cluster, retrieve the protection group.


    phys-newyork-1# geopg get -s paris-newyork-ps tcpg
    Protection group "tcpg" has been successfully created.
  7. Activate the protection group locally on the partner cluster.


    phys-newyork-1# geopg start -e local tcpg
    Processing operation.... this may take a while....
    Protection group "tcpg" successfully started.
  8. Verify that the protection group was successfully created and activated.

    Running the geoadm status command on cluster-paris produces the following output:


    phys-paris-1# geoadm status
    Cluster: cluster-paris
    
       Partnership "paris-newyork-ps"        : OK
          Partner clusters                   : newyork
          Synchronization                    : OK
          ICRM Connection                    : OK
    
          Heartbeat "hb_cluster-paris~cluster-newyork" monitoring \
    "paris-newyork-ps": OK 			
             Plug-in "ping-plugin"           : Inactive
             Plug-in "tcp_udp_plugin"        : OK
    
       Protection group "tcpg"               : Degraded
          Partnership                        : paris-newyork-ps
          Synchronization                    : OK
    
          Cluster cluster-paris              : Degraded
             Role                            : Primary
             Configuration                   : OK
             Data replication                : Degraded
             Resource groups                 : OK
    
          Cluster cluster-newyork            : Degraded
             Role                            : Secondary
             Configuration                   : OK
             Data Replication                : Degraded
             Resource Groups                 : OK

Creating, Modifying, Validating, and Deleting a Hitachi TrueCopy or Universal Replicator Protection Group

This section contains procedures for the following tasks:


Note –

You can create protection groups that are not configured to use data replication. To create a protection group that does not use a data replication subsystem, omit the -d datareplicationtype option when you use the geopg command. The geoadm status command shows a state for these protection groups of Degraded.

For more information, see Creating a Protection Group That Does Not Require Data Replication in Sun Cluster Geographic Edition System Administration Guide.


ProcedureHow to Create and Configure a Hitachi TrueCopy or Universal Replicator Protection Group That Does Not Use Oracle Real Application Clusters

Use the steps in this task to create and configure a Hitachi TrueCopy or Universal Replicator protection group. If you want to use Oracle Real Application Clusters, see How to Create a Protection Group for Oracle Real Application Clusters.

Before You Begin

Before you create a protection group, ensure that the following conditions are met:


Note –

Protection group names are unique in the global Sun Cluster Geographic Edition namespace. You cannot use the same protection group name in two partnerships on the same system.


You can also replicate the existing configuration of a protection group from a remote cluster to the local cluster. For more information, see Replicating the Hitachi TrueCopy or Universal Replicator Protection Group Configuration to a Secondary Cluster.

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Create a new protection group by using the geopg create command.

    This command creates a protection group on all nodes of the local cluster.


    # geopg create -s partnershipname -o localrole -d truecopy [-p property [-p…]] \
    protectiongroupname
    
    -s partnershipname

    Specifies the name of the partnership.

    -o localrole

    Specifies the role of this protection group on the local cluster as either primary or secondary.

    -d truecopy

    Specifies that the protection group data is replicated by the Hitachi TrueCopy or Universal Replicator software.

    -p propertysetting

    Specifies the properties of the protection group.

    You can specify the following properties:

    • Description – Describes the protection group.

    • Timeout – Specifies the timeout period for the protection group in seconds.

    • Nodelist – Lists the host names of the machines that can be primary for the replication subsystem.

    • Ctgid – Specifies the consistency group ID (CTGID) of the protection group.

    • Cluster_dgs – Lists the device groups where the data is written. The Sun Cluster device groups must exist and have the same name on both the primary cluster and the secondary cluster.

    For more information about the properties you can set, see Appendix A, Standard Sun Cluster Geographic Edition Properties, in Sun Cluster Geographic Edition System Administration Guide.

    protectiongroupname

    Specifies the name of the protection group.

    For information about the names and values that are supported by Sun Cluster Geographic Edition software, see Appendix B, Legal Names and Values of Sun Cluster Geographic Edition Entities, in Sun Cluster Geographic Edition System Administration Guide.

    For more information about the geopg command, refer to the geopg(1M) man page.


Example 2–2 Creating and Configuring a Hitachi TrueCopy or Universal Replicator Protection Group

This example creates a Hitachi TrueCopy or Universal Replicator protection group on cluster-paris, which is set as the primary cluster.


# geopg create -s paris-newyork-ps -o primary -d truecopy \
-p Nodelist=phys-paris-1,phys-paris-2 tcpg


Example 2–3 Creating a Hitachi TrueCopy or Universal Replicator Protection Group for Application Resource Groups That Are Online

This example creates a Hitachi TrueCopy or Universal Replicator protection group, tcpg, for an application resource group, resourcegroup1, that is currently online on cluster-newyork.

  1. Create the protection group without the application resource group.


    # geopg create -s paris-newyork-ps -o primary -d truecopy \
    -p nodelist=phys-paris-1,phys-paris-2 tcpg
    
  2. Activate the protection group.


    # geopg start -e local tcpg
    
  3. Add the application resource group.


    # geopg add-resource-group resourcegroup1 tcpg
    

Ensuring Data Consistency for Hitachi Universal Replicator in Asynchronous Mode

This section describes the protection group configuration that is required in the Sun Cluster Geographic Edition 3.2 11/09 software to guarantee data consistency in asynchronous mode replication. Asynchronous mode replication is implemented by using the async fence level of Hitachi Universal Replicator. The following discussion therefore applies only to the async fence level and to Hitachi Universal Replicator as implemented in the Sun Cluster Geographic Edition module.

Understanding Data Consistency in Sun Cluster Geographic Edition

With Sun Cluster 3.2 11/09 software, the Sun Cluster Geographic Edition module supports Hitachi TrueCopy and Universal Replicator device groups in asynchronous mode replication. Routine operations for both Hitachi TrueCopy and Universal Replicator provide data consistency in asynchronous mode. However, in the event of a temporary loss of communications or of a “rolling disaster” where different parts of the system fail at different times, only Hitachi Universal Replicator software can prevent loss of consistency of replicated data for asynchronous mode. In addition, Hitachi Universal Replicator software can only ensure data consistency with the configuration described in this section and in Configuring the /etc/horcm.conf File on the Nodes of the Primary Cluster and Configuring the /etc/horcm.conf File on the Nodes of the Secondary Cluster.

In Hitachi Universal Replicator software, the Hitachi storage arrays replicate data from primary storage to secondary storage. The application that produced the data is not involved. Even so, to guarantee data consistency, replication must preserve the application's I/O write ordering, regardless of how many disk devices the application writes.

During routine operations, Hitachi Universal Replicator software on the storage secondary array pulls data from cache on the primary storage array. If data is produced faster than it can be transferred, Hitachi Universal Replicator can commit backlogged I/O and a sequence number for each write to a journal volume on the primary storage array. The secondary storage array pulls that data from primary storage and commits it to its own journal volumes, from where it is transferred to application storage. If communications fail and are later restored, the secondary storage array begins to resynchronize the two sites by continuing to pull backlogged data and sequence numbers from the journal volume. Sequence numbers control the order in which data blocks are committed to disk so that write ordering is maintained at the secondary site despite the interruption. As long as journal volumes have enough disk space to record all data that is generated by the application that is running on the primary cluster during the period of failure, consistency is guaranteed.

In the event of a rolling disaster, where only some of the backlogged data and sequence numbers reach the secondary storage array after failures begin, sequence numbers determine which data should be committed to data LUNs to preserve consistency.


Note –

In the Sun Cluster Geographic Edition module with Hitachi Universal Replicator, journal volumes are associated with application storage in the /etc/horcm.conf file. That configuration is described in Journal Volumes and Configuring the /etc/horcm.conf File on the Nodes of the Primary Cluster. For information about how to configure journal volumes on a storage array, see the Hitachi documentation for that array.


Using Consistency Group IDs to Ensure Data Consistency

Along with journal volumes, consistency group IDs (CTGIDs) ensure data consistency even if the storage for an application data service includes devices in multiple Hitachi device groups. A CTGID is an integer that is assigned to one or more Hitachi device groups. It designates those devices that must be maintained in a state of replication consistent with each other. Consistency is maintained among all devices with the same CTGID whether the devices are members of a single Hitachi device group or several Hitachi device groups. For example, if Hitachi Universal Replicator stops replication on the devices of one device group that is assigned the CTGID of 5, it stops replication on all other devices in device groups with the CTGID of 5.

To ensure data consistency, an exact correspondence must therefore exist between the device groups that are used by a single application data service and a CTGID. All device groups that are used by a single data service must have the same unique CTGID. No device group can have that CTGID unless it is used by the data service.

To ensure this correspondence, the Sun Cluster Geographic Edition 3.2 11/09 software allows the administrator to set a CTGID property on each protection group. The device groups that are added to the protection group must all have the same CTGID as the protection group. If other device groups are assigned the same CTGID as the device groups in the protection group, the Sun Cluster Geographic Edition software generates an error. For example, if the protection group app1-pg has been assigned the CTGID of 5, all device groups included in app1-pg must have the CTGID of 5. Moreover, all CTGIDs of device groups that are included in app1-pg must have the CTGID of 5.

You are not required to set a CTGID on a protection group. The Hitachi storage software will automatically assign a unique CTGID to an asynchronously replicated device group when it is initialized. Thereafter, the pairs in that device group will be maintained in a state of consistency with each other. Thus, if an application data service in a protection group uses storage in just one asynchronously replicated Hitachi device group, you can let the Hitachi storage array assign the device group's CTGID. You do not have to also set the CTGID of the protection group.

Similarly, if you do not need data consistency, or if your application does not write asynchronously to your Hitachi device groups, then setting the CTGID on the protection group has little use. However, if you do not assign a CTGID to a protection group, any later configuration changes to the device group or to the protection group might lead to conflicts. Assignment of a CTGID to a protection group provides the most flexibility for later changes and the most assurance of device group consistency.

ProcedureConfiguring Consistency Group IDs for Hitachi Universal Replicator Device Groups in Asynchronous Mode

You can assign a consistency group ID (CTGID) to a protection group by setting the property ctgid=consistency-group-ID as an option to the geopg create command. You can assign CTGID values to device groups in one of two ways:

The following procedure demonstrates these two methods of setting the CTGID for the devices that are used by an application data service. The procedure configures a protection group named app1-pg with a CTGID of 5. This protection group contains the app1-rg resource group and the Hitachi Universal Replicator devgroup1 device group, which uses the async fence level.

Before You Begin
  1. On the primary cluster, create the Sun Cluster Geographic Edition protection group with a specified CTGID, and add the resource group.


    phys-paris-1# geopg create -s paris-newyork-ps -o primary -d truecopy -p ctgid=5 \
    -p nodelist=phys-paris-1,phys-paris-2 app1-pg
    

    phys-paris-1# geopg add-resource-group app1-rg app1-pg
    
  2. Add device groups to the protection group by using one of the following methods:

    • Add device groups that have been configured in the /etc/horcm.conf file but have not been initialized by using the paircreate command.


      phys-paris-1# geopg add-device-group -p fence_level=async devgroup1 app1-pg
      
    • Assign CTGIDs to device groups when they are initialized by using the Hitachi paircreate command, and add the device groups to the protection group that has the same value for the CTGID property.

      In the following example, a device group is initialized with the CTGID of 5 and then added to the app1-pg protection group:


      phys-paris-1# paircreate -g devgroup1 -vl -f async 5
      

      phys-paris-1# geopg add-device-group -p fence_level=async devgroup1 app1-pg
      
  3. Start the protection group.


    phys-paris-1# geopg start -e local app1-pg
    

    Uninitialized device groups, if any, are initialized and assigned the CTGID of 5.

Requirements to Support Oracle Real Application Clusters With Data Replication Software

Sun Cluster Geographic Edition software supports Oracle Real Application Clusters with Hitachi TrueCopy and Universal Replicator software. Observe the following requirements when you configure Oracle Real Application Clusters:

ProcedureHow to Create a Protection Group for Oracle Real Application Clusters

Before You Begin

Before you create a protection group for Oracle Real Application Clusters (RAC), ensure that the following conditions are met:

When a cluster and the Veritas Volume Manager cluster feature software restart, the RAC framework automatically tries to import all cluster feature device groups that were imported already before cluster went down. Therefore, the attempt to import the device groups to the original primary fails.

  1. Log in to a cluster node on the primary cluster.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Create a new protection group by using the geopg create command.

    This command creates a protection group on all nodes of the local cluster.


    # geopg create -s partnershipname -o localrole -d truecopy  \
    -p External_Dependency_Allowed=true [-p property [-p…]] protectiongroupname
    
    -s partnershipname

    Specifies the name of the partnership.

    -o localrole

    Specifies the role of this protection group on the local cluster as primary.

    -d truecopy

    Specifies that the protection group data is replicated by the Hitachi TrueCopy or Universal Replicator software.

    -p propertysetting

    Specifies the properties of the protection group.

    You can specify the following properties:

    • Description – Describes the protection group.

    • External_Dependency_Allowed - Specifies whether to allow any dependencies between resource groups and resources that belong to this protection group and resource groups and resources that do not belong to this protection group. For RAC, set this property to true.

    • Timeout – Specifies the timeout period for the protection group in seconds.

    • Nodelist – Lists the host names of the machines that can be primary for the replication subsystem.

    • Ctgid – Specifies the consistency group ID (CTGID) of the protection group.

    • Cluster_dgs – Specifies the Veritas Volume Manager cluster feature disk group where the data is written.

    For more information about the properties you can set, see Appendix A, Standard Sun Cluster Geographic Edition Properties, in Sun Cluster Geographic Edition System Administration Guide.

    protectiongroupname

    Specifies the name of the protection group.

    For information about the names and values that are supported by Sun Cluster Geographic Edition software, see Appendix B, Legal Names and Values of Sun Cluster Geographic Edition Entities, in Sun Cluster Geographic Edition System Administration Guide.

    For more information about the geopg command, refer to the geopg(1M) man page.

  3. Add a Hitachi TrueCopy or Universal Replicator device group to the protection group.


    # geopg add-device-group [-p property [-p…]] protectiongroupname
    
    -p propertysetting

    Specifies the properties of the protection group.

    You can specify the Fence_level properties which defines the fence level that is used by the disk device group. The fence level determines the level of consistency among the primary and secondary volumes for that disk device group. You must set this to never.


    Caution – Caution –

    To avoid application failure on the primary cluster, specify a Fence_level of never or async. If the Fence_level parameter is not set to never or async, data replication might not function properly when the secondary site goes down.

    If you specify a Fence_level of never, the data replication roles do not change after you perform a takeover.

    Do not use programs that would prevent the Fence_level parameter from being set to data or status because these values might be required in special circumstances.

    If you have special requirements to use a Fence_level of data or status, consult your Sun representative.


    For more information about the properties you can set, see Appendix A, Standard Sun Cluster Geographic Edition Properties, in Sun Cluster Geographic Edition System Administration Guide.

    protectiongroupname

    Specifies the name of the protection group.

  4. Add to the protection group only the rac_server_proxy resource group and resource groups for device groups that are replicated.


    Note –

    Do not add the RAC framework resource group to the protection group. This ensures that, if the protection group becomes secondary on the node, the framework resource group does not become unmanaged. In addition, multiple RAC databases can be on the cluster, and the databases can be under Sun Cluster Geographic Edition control or not under its control.



    # geopg add-resource-group resourcegroup protectiongroupname
    
    resourcegroup

    Specifies a comma-separated list of resource groups to add to or delete from the protection group. The specified resource groups must already be defined.

    The protection group must be online before you add a resource group. The geopg add-resource-group command fails when a protection group is offline and the resource group that is being added is online.


    Note –

    If a protection group has already been started at the time that you add a resource group, the resource group remains unmanaged. You must start the resource group manually by running the geopg start command.


    protectiongroupname

    Specifies the name of the protection group.


Example 2–4 Creating a Protection Group for RAC

This example creates the protection group pg1 which uses RAC and the cluster feature.

A cluster feature disk group racdbdg controls the data which is replicated by the Hitachi TrueCopy or Universal Replicator device group VG01. The node list of the RAC framework resource group is set to all nodes of the cluster.

  1. Create the protection group on the primary cluster with the cluster feature disk group racdbdg.


    # geopg create -s pts1 -o PRIMARY -d Truecopy \
    -p cluster_dgs=racdbdg -p external_dependency_allowed=true pg1
    Protection group "pg1" successfully created.
  2. Add the Hitachi TrueCopy or Universal Replicator device group VG01 to protection group pg1.


    # geopg add-device-group --property fence_level=never VG01 pg1
    Device group "VG01" successfully added to the protection group "pg1".
  3. Add the rac_server_proxy-rg resource group and the replicated device-group resource groups, hasp4rac-rg and scaldbdg-rg, to the protection group.


    # geopg add-resource-group rac_server_proxy-rg,hasp4rac-rg,\
    scaldbdg-rg pg1
    

How the Data Replication Subsystem Validates the Device Group

Before creating the protection group, the data replication layer validates that the horcmd daemon is running.

The data replication layer validates that the horcmd daemon is running on at least one node that is specified in the Nodelist property.

If the Cluster_dgs property is specified, then the data replication layer verifies that the device group specified is a valid Sun Cluster device group. The data replication layer also verifies that the device group is of a valid type.


Note –

The device groups that are specified in the Cluster_dgs property must be written to only by applications that belong to the protection group. This property must not specify device groups that receive information from applications outside the protection group.


A Sun Cluster resource group is automatically created when the protection group is created.

This resource in this resource group monitors data replication. The name of the Hitachi TrueCopy or Universal Replicator data replication resource group is rg-tc-protectiongroupname.


Caution – Caution –

These automatically created replication resource groups are for Sun Cluster Geographic Edition internal implementation purposes only. Use caution when you modify these resource groups by using Sun Cluster commands.


ProcedureHow to Modify a Hitachi TrueCopy or Universal Replicator Protection Group

Before You Begin

Before modifying the configuration of your protection group, ensure that the protection group you want to modify exists locally.

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Modify the configuration of the protection group.

    This command modifies the properties of a protection group on all nodes of the local cluster. If the partner cluster contains a protection group of the same name, this command also propagates the new configuration information to the partner cluster.


    # geopg set-prop -p property [-p...] protectiongroupname
    
    -p propertysetting

    Specifies the properties of the protection group.

    For more information about the properties you can set, see Appendix A, Standard Sun Cluster Geographic Edition Properties, in Sun Cluster Geographic Edition System Administration Guide.

    protectiongroupname

    Specifies the name of the protection group.

    For information about the names and values that are supported by Sun Cluster Geographic Edition software, see Appendix B, Legal Names and Values of Sun Cluster Geographic Edition Entities, in Sun Cluster Geographic Edition System Administration Guide.

    For more information about the geopg command, refer to the geopg(1M) man page.


Example 2–5 Modifying the Configuration of a Protection Group

This example modifies the Timeout property of the protection group that was created in Example 2–2.


# geopg set-prop -p Timeout=400 tcpg

Validating a Hitachi TrueCopy or Universal Replicator Protection Group

During protection group validation, the Hitachi TrueCopy or Universal Replicator data replication subsystem validates the following:

When the geoadm status output displays that the Configuration status of a protection group is Error, you can validate the configuration by using the geopg validate command. This command checks the current state of the protection group and its entities.

If the protection group and its entities are valid, then the Configuration status of the protection groups is set to OK. If the geopg validate command finds an error in the configuration files, then the command displays a message about the error and the configuration remains in the error state. In such a case, you can fix the error in the configuration, and run the geopg validate command again.

ProcedureHow to Validate a Hitachi TrueCopy or Universal Replicator Protection Group

Before You Begin

Ensure that the protection group you want to validate exists locally and that the Common Agent Container is online on all nodes of both clusters in the partnership.

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Validate the configuration of the protection group.

    This command validates the configuration of the protection group on the local cluster only. To validate the protection group configuration on the partner cluster, run the command again on the partner cluster.


    # geopg validate protectiongroupname 
    
    protectiongroupname

    Specifies a unique name that identifies a single protection group


Example 2–6 Validating the Configuration of a Protection Group

This example validates a protection group.


# geopg validate tcpg

ProcedureHow to Delete a Hitachi TrueCopy or Universal Replicator Protection Group

Before You Begin

If you want to delete the protection group everywhere, you must run the geopg delete command on each cluster where the protection group exists.

Before deleting a protection group, ensure that the following conditions are met:


Note –

You must remove the application resource groups from the protection group in order to keep the application resource groups online while deleting the protection group. See Example 2–8 and Example 2–10 for examples of this procedure.


  1. Log in to a node on the primary cluster.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Delete the protection group.

    This command deletes the configuration of the protection group from the local cluster. The command also removes the replication resource group for each Hitachi TrueCopy or Universal Replicator device group in the protection group. This command does not alter the pair state of the Hitachi TrueCopy or Universal Replicator device group.


    # geopg delete protectiongroupname 
    
    protectiongroupname

    Specifies the name of the protection group

  3. To delete the protection group on the secondary cluster, repeat step 1 and step 2 on cluster-newyork.


Example 2–7 Deleting a Protection Group

This example deletes a protection group from both partner clusters.

cluster-paris is the primary cluster. For a reminder of the sample cluster configuration, see Example Sun Cluster Geographic Edition Cluster Configuration in Sun Cluster Geographic Edition System Administration Guide.


# rlogin phys-paris-1 -l root
phys-paris-1# geopg delete tcpg
# rlogin phys-newyork-1 -l root
phys-newyork-1# geopg delete tcpg


Example 2–8 Deleting a Hitachi TrueCopy or Universal Replicator Protection Group While Keeping Application Resource Groups Online

This example keeps online two application resource groups, apprg1 and apprg2, while deleting their protection group, tcpg. Remove the application resource groups from the protection group, then delete the protection group.


# geopg remove-resource-group apprg1,apprg2 tcpg
# geopg stop -e global tcpg
# geopg delete tcpg

Administering Hitachi TrueCopy and Universal Replicator Application Resource Groups

To make an application highly available, the application must be managed as a resource in an application resource group.

All the entities you configure for the application resource group on the primary cluster, such as application resources, installation, application configuration files, and resource groups, must be replicated to the secondary cluster. The resource group names must be identical on both clusters. Also, the data that the application resource uses must be replicated to the secondary cluster.

This section contains information about the following tasks:

ProcedureHow to Add an Application Resource Group to a Hitachi TrueCopy or Universal Replicator Protection Group

Before You Begin

You can add an existing resource group to the list of application resource groups for a protection group. Before you add an application resource group to a protection group, ensure that the following conditions are met:

The protection group can be activated or deactivated and the resource group can be either Online or Unmanaged.

If the resource group is Unmanaged and the protection group is Active after the configuration of the protection group has changed, the local state of the protection group becomes Degraded.

If the resource group to add is Online and the protection group is deactivated, the request is rejected. You must activate the protection group before adding an active resource group.

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Add an application resource group to the protection group.

    This command adds an application resource group to a protection group on the local cluster. Then the command propagates the new configuration information to the partner cluster if the partner cluster contains a protection group of the same name.


    # geopg add-resource-group resourcegrouplist protectiongroup
    
    resourcegrouplist

    Specifies the name of the application resource group. You can specify more than one resource group in a comma-separated list.

    protectiongroup

    Specifies the name of the protection group.

    For information about the names and values that are supported by Sun Cluster Geographic Edition software, see Appendix B, Legal Names and Values of Sun Cluster Geographic Edition Entities, in Sun Cluster Geographic Edition System Administration Guide.

    If the add operation is unsuccessful on the local cluster, the configuration of the protection group is not modified. Otherwise, the Configuration status is set to OK on the local cluster.

    If the Configuration status is OK on the local cluster, but the add operation is unsuccessful on the partner cluster, the Configuration status is set to Error on the partner cluster.

    After the application resource group is added to the protection group, the application resource group is managed as an entity of the protection group. Then the application resource group is affected by protection group operations such as start, stop, switchover, and takeover.


Example 2–9 Adding an Application Resource Group to a Protection Group

This example adds two application resource groups, apprg1 and apprg2, to tcpg.


# geopg add-resource-group apprg1,apprg2 tcpg

ProcedureHow to Delete an Application Resource Group From a Hitachi TrueCopy or Universal Replicator Protection Group

You can remove an application resource group from a protection group without altering the state or contents of an application resource group.

Before You Begin

Ensure that the following conditions are met:

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Remove the application resource group from the protection group.

    This command removes an application resource group from the protection group on the local cluster. If the partner cluster contains a protection group of the same name, then the command removes the application resource group from the protection group on the partner cluster.


    # geopg remove-resource-group resourcegrouplist protectiongroup
    
    resourcegrouplist

    Specifies the name of the application resource group. You can specify more than one resource group in a comma-separated list.

    protectiongroup

    Specifies the name of the protection group.

    If the remove operation is unsuccessful on the local cluster, the configuration of the protection group is not modified. Otherwise, the Configuration status is set to OK on the local cluster.

    If the Configuration status is OK on the local cluster, but the remove operation is unsuccessful on the partner cluster, the Configuration status is set to Error on the partner cluster.


Example 2–10 Deleting an Application Resource Group From a Protection Group

This example removes two application resource groups, apprg1 and apprg2, from tcpg.


# geopg remove-resource-group apprg1,apprg2 tcpg

Administering Hitachi TrueCopy and Universal Replicator Data Replication Device Groups

This section provides the following information about administering Hitachi TrueCopy and Universal Replicator data replication device groups:

For details about configuring a Hitachi TrueCopy or Universal Replicator data replication protection group, see How to Create and Configure a Hitachi TrueCopy or Universal Replicator Protection Group That Does Not Use Oracle Real Application Clusters.

ProcedureHow to Add a Data Replication Device Group to a Hitachi TrueCopy or Universal Replicator Protection Group

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Create a data replication device group in the protection group.

    This command adds a device group to a protection group on the local cluster and propagates the new configuration to the partner cluster if the partner cluster contains a protection group of the same name.


    # geopg add-device-group -p property [-p...] devicegroupname protectiongroupname
    
    -p property

    Specifies the properties of the data replication device group.

    You can specify the Fence_level property which defines the fence level that is used by the device group. The fence level determines the level of consistency among the primary and secondary volumes for that device group.

    You can set this property to data, status, never, or async. When you use a Fence_level of never or async, the application can continue to write to the primary cluster even after failure on the secondary cluster. However, when you set the Fence_level property to data or status, the application on the primary cluster might fail because the secondary cluster is not available for the following reasons:

    • Data replication link failure

    • Secondary cluster and storage is down

    • Storage on the secondary cluster is down


    Caution – Caution –

    To avoid application failure on the primary cluster, specify a Fence_level of never or async.

    If you specify a Fence_level of never, the data replication roles do not change after you perform a takeover.

    If you have special requirements to use a Fence_level of data or status, consult your Sun representative.


    The other properties you can specify depend on the type of data replication you are using. For details about these properties, see Appendix A, Standard Sun Cluster Geographic Edition Properties, in Sun Cluster Geographic Edition System Administration Guide.

    devicegroupname

    Specifies the name of the new data replication device group.

    protectiongroupname

    Specifies the name of the protection group that will contain the new data replication device group.

    For information about the names and values that are supported by Sun Cluster Geographic Edition software, see Appendix B, Legal Names and Values of Sun Cluster Geographic Edition Entities, in Sun Cluster Geographic Edition System Administration Guide.

    For more information about the geopg command, refer to the geopg(1M) man page.


    
    

Example 2–11 Adding a Data Replication Device Group to a Hitachi TrueCopy or Universal Replicator Protection Group

This example creates a Hitachi TrueCopy or Universal Replicator data replication device group in the tcpg protection group.


# geopg add-device-group -p Fence_level=data devgroup1 tcpg

Validations Made by the Data Replication Subsystem

When the Hitachi TrueCopy or Universal Replicator device group, configured as dev_group in the /etc/horcm.conf file, is added to a protection group, the data replication layer makes the following validations.

Hitachi TrueCopy or Universal Replicator Device Group Property 

Validation 

devicegroupname

Checks that the specified Hitachi TrueCopy or Universal Replicator device group is configured on all of the cluster nodes that are specified in the Nodelist property.

Fence_level

If a pair is already established for this Hitachi TrueCopy or Universal Replicator device group, the data replication layer checks that the specified Fence_level matches the already established fence level.

If a pair is not yet established, for example, if a pair is in the SMPL state, any Fence_level is accepted.

When a Hitachi TrueCopy or Universal Replicator device group is added to a protection group, a Sun Cluster resource is automatically created by this command. This resource monitors data replication. The name of the resource is r-tc-protectiongroupname-devicegroupname. This resource is placed in the corresponding Sun Cluster resource group, which is named rg-tc-protectiongroupname.


Caution – Caution –

You must use caution before you modify these replication resources with Sun Cluster commands. These resources are for internal implementation purposes only.


How the State of the Hitachi TrueCopy or Universal Replicator Device Group Is Validated

For validation purposes, Sun Cluster Geographic Edition gives each Hitachi TrueCopy or Universal Replicator device group a state according to the current state of its pair. This state is returned by the pairvolchk -g devicegroup -ss command.

The remainder of this section describes the individual device group states and how these states are validated against the local role of the protection group.

Determining the State of an Individual Hitachi TrueCopy or Universal Replicator Device Group

An individual Hitachi TrueCopy or Universal Replicator device group can be in one of the following states:

The state of a particular device group is determined by using the value that is returned by the pairvolchk -g devicegroup -ss command. The following table describes the device group state associated with the values returned by the pairvolchk command.

Table 2–1 Individual Hitachi TrueCopy and Universal Replicator Device Group States

Output of pairvolchk

Individual Device Group State 

11 = SMPL

SMPL

22 / 42 = PVOL_COPY

23 / 42 = PVOL_PAIR

26 / 46 = PVOL_PDUB

47 = PVOL_PFUL

48 = PVOL_PFUS

Regular Primary

24 / 44 = PVOL_PSUS

25 / 45 = PVOL_PSUE

For these return codes, determining the individual device group category requires that the horcmd process be active on the remote cluster so that the remote-pair-state for this device group can be obtained.

Regular Primary, if remote-cluster-state !=SSWS

or 

Takeover Secondary, if remote-cluster-state == SSWS

SSWS, when you use the pairdisplay -g devicegroup -fc command.

32 / 52 = SVOL_COPY

33 / 53 = SVOL_PAIR

35 / 55 = SVOL_PSUE

36 / 56 = SVOL_PDUB

57 = SVOL_PFUL

58 = SVOL_PFUS

Regular Secondary

34 / 54 = SVOL_PSUS

Regular Secondary, if local-cluster-state !=SSWS

or 

Takeover Primary, if local-cluster-state == SSWS

SSWS, when you use the pairdisplay -g devicegroup -fc command.

Determining the Aggregate Hitachi TrueCopy or Universal Replicator Device Group State

If a protection group contains only one Hitachi TrueCopy or Universal Replicator device group, then the aggregate device group state is the same as the individual device group state.

When a protection group contains multiple Hitachi TrueCopy or Universal Replicator device groups, the aggregate device group state is obtained as described in the following table.

Table 2–2 Conditions That Determine the Aggregate Device Group State

Condition 

Aggregate Device Group State 

All individual device group states are SMPL

SMPL

All individual device group states are either Regular Primary or SMPL

Regular Primary

All individual device group states are either Regular Secondary or SMPL

Regular Secondary

All individual device group states are either Takeover Primary or SMPL

Takeover Primary

All individual device group states are either Takeover Secondary or SMPL

Takeover Secondary

The aggregate device group state cannot be obtained for any other combination of individual device group states. This is considered a pair-state validation failure.

Validating the Local Role of the Protection Group Against the Aggregate Device Group State

The local role of a Hitachi TrueCopy or Universal Replicator protection group is validated against the aggregate device group state as described in the following table.

Table 2–3 Validating the Aggregate Device Group State Against the Local Role of a Protection Group

Aggregate Device Group State 

Valid Local Protection Group Role 

SMPL

primary or secondary

Regular Primary

primary

Regular Secondary

secondary

Takeover Primary

primary

Takeover Secondary

secondary


Example 2–12 Validating the Aggregate Device Group State

This example validates the state of a Hitachi TrueCopy or Universal Replicator device group against the role of the Hitachi TrueCopy or Universal Replicator protection group to which it belongs.

First, the protection group is created as follows:


phys-paris-1# geopg create -s paris-newyork-ps -o primary -d truecopy tcpg

A device group, devgroup1, is added to the protection group, tcpg, as follows:


phys-paris-1# geopg add-device-group -p fence_level=async devgroup1 tcpg

The current state of a Hitachi TrueCopy or Universal Replicator device group, devgroup1, is provided in the output of the pairdisplay command as follows:


phys-paris-1# pairdisplay -g devgroup1 
Group PairVol(L/R) (Port#,TID,LU),Seq#,LDEV#,P/S,Status,Fence,Seq#,P-LDEV# M 
devgroup1 pair1(L) (CL1-A , 0, 1) 12345   1..P-VOL PAIR ASYNC,54321  609   -
devgroup1 pair1(R) (CL1-C , 0, 20)54321 609..S-VOL PAIR ASYNC,-----   1    - 
devgroup1 pair2(L) (CL1-A , 0, 2) 12345   2..P-VOL PAIR ASYNC,54321  610   - 
devgroup1 pair2(R) (CL1-C , 0,21) 54321 610..S-VOL PAIR ASYNC,-----   2    -

The pairvolchk -g <DG> -ss command is run and returns a value of 23.


phys-paris-1# pairvolchk -g devgroup1 -ss
parivolchk : Volstat is P-VOL.[status = PAIR fence = ASYNC]
phys-paris-1# echo $?
23

The output of the pairvolchk command is 23, which corresponds in Table 2–1 to an individual device group state of Regular Primary. Because the protection group contains only one device group, the aggregate device group state is the same as the individual device group state. The device group state is valid because the local role of the protection group, specified by the -o option, is primary, as specified in Table 2–3.


ProcedureHow to Modify a Hitachi TrueCopy or Universal Replicator Data Replication Device Group

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Modify the device group.

    This command modifies the properties of a device group in a protection group on the local cluster. Then the command propagates the new configuration to the partner cluster if the partner cluster contains a protection group of the same name.


    # geopg modify-device-group -p property [-p...] TCdevicegroupname protectiongroupname
    
    -p property

    Specifies the properties of the data replication device group.

    For more information about the properties you can set, see Appendix A, Standard Sun Cluster Geographic Edition Properties, in Sun Cluster Geographic Edition System Administration Guide.

    TCdevicegroupname

    Specifies the name of the new data replication device group.

    protectiongroupname

    Specifies the name of the protection group that will contain the new data replication device group.


Example 2–13 Modifying the Properties of a Hitachi TrueCopy or Universal Replicator Data Replication Device Group

This example modifies the properties of a data replication device group that is part of a Hitachi TrueCopy or Universal Replicator protection group.


# geopg modify-device-group -p fence_level=async tcdg tcpg

ProcedureHow to Delete a Data Replication Device Group From a Hitachi TrueCopy or Universal Replicator Protection Group

Before You Begin

You might delete a data replication device group from a protection group if you added a data replication device group to a protection group. Normally, after an application is configured to write to a set of disks, you would not change the disks.

Deleting a data replication device group does not stop replication or change the replication status of the data replication device group.

For information about deleting protection groups, refer to How to Delete a Hitachi TrueCopy or Universal Replicator Protection Group. For information about deleting application resource groups from a protection group, refer to How to Delete an Application Resource Group From a Hitachi TrueCopy or Universal Replicator Protection Group.

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Remove the device group.

    This command removes a device group from a protection group on the local cluster. Then the command propagates the new configuration to the partner cluster if the partner cluster contains a protection group of the same name.


    # geopg remove-device-group devicegroupname protectiongroupname
    
    devicegroupname

    Specifies the name of the data replication device group

    protectiongroupname

    Specifies the name of the protection group

    When a device group is deleted from a Hitachi TrueCopy or Universal Replicator protection group, the corresponding Sun Cluster resource, r-tc-protectiongroupname-devicegroupname, is removed from the replication resource group. As a result, the deleted device group is no longer monitored. The resource group is removed when the protection group is deleted.


Example 2–14 Deleting a Replication Device Group From a Hitachi TrueCopy or Universal Replicator Protection Group

This example removes a Hitachi TrueCopy or Universal Replicator data replication device group.


# geopg remove-device-group tcdg tcpg

Replicating the Hitachi TrueCopy or Universal Replicator Protection Group Configuration to a Secondary Cluster

After you have configured data replication, resource groups, and resources on your primary and secondary clusters, you can replicate the configuration of the protection group to the secondary cluster.

ProcedureHow to Replicate the Hitachi TrueCopy or Universal Replicator Protection Group Configuration to a Secondary Cluster

Before You Begin

Before you replicate the configuration of a Hitachi TrueCopy or Universal Replicator protection group to a secondary cluster, ensure that the following conditions are met:

  1. Log in to phys-newyork-1.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

    phys-newyork-1 is the only node on the secondary cluster. For a reminder of which node is phys-newyork-1, see Example Sun Cluster Geographic Edition Cluster Configuration in Sun Cluster Geographic Edition System Administration Guide.

  2. Replicate the protection group configuration to the partner cluster by using the geopg get command.

    This command retrieves the configuration information of the protection group from the remote cluster and creates the protection group on the local cluster.


    phys-newyork-1# geopg get -s partnershipname [protectiongroup]
    
    -s partnershipname

    Specifies the name of the partnership from which the protection group configuration information should be retrieved and the name of the partnership where the protection will be created locally.

    protectiongroup

    Specifies the name of the protection group.

    If no protection group is specified, then all protection groups that exist in the specified partnership on the remote partner are created on the local cluster.


    Note –

    The geopg get command replicates Sun Cluster Geographic Edition related entities. For information about how to replicate Sun Cluster entities, see Replicating and Upgrading Configuration Data for Resource Groups, Resource Types, and Resources in Sun Cluster Data Services Planning and Administration Guide for Solaris OS.



Example 2–15 Replicating the Hitachi TrueCopy or Universal Replicator Protection Group to a Partner Cluster

This example replicates the configuration of tcpg from cluster-paris to cluster-newyork.


# rlogin phys-newyork-1 -l root
phys-newyork-1# geopg get -s paris-newyork-ps tcpg

Activating a Hitachi TrueCopy or Universal Replicator Protection Group

When you activate a protection group, the protection group assumes the role that you assigned to it during configuration. For more information about configuring protection groups, see How to Create and Configure a Hitachi TrueCopy or Universal Replicator Protection Group That Does Not Use Oracle Real Application Clusters.

You can activate a protection group in the following ways:

Activating a Hitachi TrueCopy or Universal Replicator protection group on a cluster has the following effect on the data replication layer:

Application handling proceeds only after data replication has been started successfully.

Activating a protection group has the following effect on the application layer:

The Hitachi TrueCopy or Universal Replicator command that is used to start data replication depends on the following factors:

The following table describes the Hitachi TrueCopy or Universal Replicator command that is used to start data replication for each of the possible combinations of factors. In the commands, dg is the device group name and fl is the fence level that is configured for the device group.

Table 2–4 Commands Used to Start Hitachi TrueCopy or Universal Replicator Data Replication

Aggregate Device Group State 

Valid Local Protection Group Role 

Hitachi TrueCopy or Universal Replicator Start Command 

SMPL

primary or secondary

paircreate -vl -g dg -f fl

paircreate -vl -g dg -f fl ctgid

paircreate -vr -g dg -f fl

paircreate -vr -g dg -f fl ctgid

All commands require that the horcmd process is running on the remote cluster. Device pairs can be started with or without a specified CTGID.

Regular Primary

primary

If the local state code is 22, 23, 25, 26, 29, 42, 43, 45, 46, or 47, no command is run because data is already being replicated. 

If the local state code is 24, 44, or 48, then the following command is run: pairresync -g dg [-l].

If the local state code is 11, then the following command is run: paircreate -vl -g dg -f fl.

Both commands require that the horcmd process is running on the remote cluster.

Regular Secondary

secondary

If the local state code is 32, 33, 35, 36, 39, 52, 53, 55, 56, or 57, no command is run because data is already being replicated. 

If the local state code is 34, 54, or 58, then the following command is run: pairresync -g dg

If the local state code is 11, the following command is run: paircreate -vr -g dg -f fl

Both commands require that the horcmd process is up on the remote cluster.

Takeover Primary

primary

If the local state code is 34 or 54, the following command is run: pairresync -swaps -g.

If the local state code is 11, then the following command is run: paircreate -vl -g dg -f fl.

The paircreate command requires that the horcmd process is running on the remote cluster.

Takeover Secondary

secondary

If the local state code is 24, 44, 25, or 45, the following command is run: pairresync -swapp -g dg.

If the local state code is 11, the following command is run: paircreate -vr -g dg -f fl.

Both commands require that the horcmd process is running on the remote cluster.

ProcedureHow to Activate a Hitachi TrueCopy or Universal Replicator Protection Group

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Activate the protection group.

    When you activate a protection group, its application resource groups are also brought online.


    # geopg start -e scope [-n] protectiongroupname 
    
    -e scope

    Specifies the scope of the command.

    If the scope is Local, then the command operates on the local cluster only. If the scope is Global, the command operates on both clusters that deploy the protection group.


    Note –

    The property values, such as Global and Local, are not case sensitive.


    -n

    Prevents the start of data replication at protection group startup.

    If you omit this option, the data replication subsystem starts at the same time as the protection group.

    protectiongroupname

    Specifies the name of the protection group.

    The geopg start command uses Sun Cluster commands to bring resource groups and resources online.


Example 2–16 How the Sun Cluster Geographic Edition Software Issues the Command to Start Replication

This example illustrates how the Sun Cluster Geographic Edition determines the Hitachi TrueCopy or Universal Replicator command that is used to start data replication.

First, the Hitachi TrueCopy or Universal Replicator protection group is created.


phys-paris-1# geopg create -s paris-newyork-ps -o primary -d truecopy tcpg

A device group, devgroup1, is added to the protection group.


phys-paris-1# geopg add-device-group -p fence_level=async devgroup1 tcpg

The current state of a Hitachi TrueCopy or Universal Replicator device group, devgroup1, is provided in the output of the pairdisplay command:


phys-paris-1# pairdisplay -g devgroup1
Group PairVol(L/R) (Port#,TID,LU),Seq#,LDEV#,P/S,Status,Fence,Seq#,P-LDEV# M 
devgroup1 pair1(L) (CL1-A , 0, 1) 12345   1..SMPL ----  ----, ----- ----   - 
devgroup1 pair1(R) (CL1-C , 0, 20)54321 609..SMPL ----  ----, ----- ----   - 
devgroup1 pair2(L) (CL1-A , 0, 2) 12345   2..SMPL ----  ----, ----- ----   - 
devgroup1 pair2(R) (CL1-C , 0,21) 54321 610..SMPL ----  ----, ----- ----   -

The aggregate device group state is SMPL.

Next, the protection group, tcpg, is activated by using the geopg start command.


phys-paris-1# geopg start -e local tcpg

The Sun Cluster Geographic Edition software runs the paircreate -g devgroup1 -vl -f async command at the data replication level. If the command is successful, the state of devgroup1 is provided in the output of the pairdisplay command:


phys-paris-1# pairdisplay -g devgroup1
Group PairVol(L/R) (Port#,TID,LU),Seq#,LDEV#,P/S,Status,Fence,Seq#,P-LDEV# M 
devgroup1 pair1(L) (CL1-A , 0, 1) 12345   1..P-VOL COPY ASYNC,54321  609   - 
devgroup1 pair1(R) (CL1-C , 0, 20)54321 609..S-VOL COPY ASYNC,-----   1    - 
devgroup1 pair2(L) (CL1-A , 0, 2) 12345   2..P-VOL COPY ASYNC,54321  610   - 
devgroup1 pair2(R) (CL1-C , 0,21) 54321 610..S-VOL COPY ASYNC,-----   2    -


Example 2–17 Activating a Hitachi TrueCopy or Universal Replicator Protection Group Globally

This example activates a protection group globally.


# geopg start -e global tcpg

The protection group, tcpg, is activated on both clusters where the protection group is configured.



Example 2–18 Activating a Hitachi TrueCopy or Universal Replicator Protection Group Locally

This example activates a protection group on a local cluster only. This local cluster might be a primary cluster or a secondary cluster, depending on the role of the cluster.


# geopg start -e local tcpg

Deactivating a Hitachi TrueCopy or Universal Replicator Protection Group

You can deactivate a protection group on the following levels:

Deactivating a Hitachi TrueCopy or Universal Replicator protection group on a cluster has the following effect on the data replication layer:

Deactivating a protection group has the following effect on the application layer:

The Hitachi TrueCopy or Universal Replicator command that is used to stop data replication depends on the following factors:

The following table describes the Hitachi TrueCopy or Universal Replicator command used to stop data replication for each of the possible combinations of factors. In the commands, dg is the device group name.

Table 2–5 Commands Used to Stop Hitachi TrueCopy or Universal Replicator Data Replication

Aggregate Device Group State 

Valid Local Protection Group Role 

Hitachi TrueCopy or Universal ReplicatorStop Command 

SMPL

primary or secondary

No command is run because no data is being replicated. 

Regular Primary

primary

If the local state code is 22, 23, 26, 29, 42, 43, 46, or 47, then the following command is run: pairsplit -g dg [-l].

If the local state code is 11, 24, 25, 44, 45, or 48, then no command is run because no data is being replicated. 

Regular Secondary

secondary

If the local state code is 32, 33, 35, 36, 39, 52, 53, 55, 56, or 57, the following command is run: pairsplit -g dg.

If the local state code is 33 or 53 and the remote state is PSUE, no command is run to stop replication.

If the local state code is 11, 34, 54, or 58, then no command is run because no data is being replicated. 

Takeover Primary

primary

No command is run because no data is being replicated. 

Takeover Secondary

secondary

No command is run because no data is being replicated. 

ProcedureHow to Deactivate a Hitachi TrueCopy or Universal Replicator Protection Group

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Deactivate the protection group.

    When you deactivate a protection group, its application resource groups are also unmanaged.


    # geopg stop -e scope [-D] protectiongroupname
    
    -e scope

    Specifies the scope of the command.

    If the scope is Local, then the command operates on the local cluster only. If the scope is Global, the command operates on both clusters where the protection group is deployed.


    Note –

    The property values, such as Global and Local, are not case sensitive.


    -D

    Specifies that only data replication should be stopped and the protection group should be online.

    If you omit this option, the data replication subsystem and the protection group are both stopped.

    protectiongroupname

    Specifies the name of the protection group.


Example 2–19 How the Sun Cluster Geographic Edition Software Issues the Command to Stop Replication

This example illustrates how the Sun Cluster Geographic Edition software determines the Hitachi TrueCopy or Universal Replicator command that is used to stop data replication.

The current state of the Hitachi TrueCopy or Universal Replicator device group, devgroup1, is provided in the output of the pairdisplay command:


phys-paris-1# pairdisplay -g devgroup1
Group PairVol(L/R) (Port#,TID,LU),Seq#,LDEV#,P/S,Status,Fence,Seq#,P-LDEV# M 
devgroup1 pair1(L) (CL1-A , 0, 1) 12345   1..P-VOL PAIR ASYNC,54321  609   - 
devgroup1 pair1(R) (CL1-C , 0, 20)54321 609..S-VOL PAIR ASYNC,-----   1    - 
devgroup1 pair2(L) (CL1-A , 0, 2) 12345   2..P-VOL PAIR ASYNC,54321  610   - 
devgroup1 pair2(R) (CL1-C , 0,21) 54321 610..S-VOL PAIR ASYNC,-----   2    -

A device group, devgroup1, is added to the protection group as follows:


phys-paris-1# geopg add-device-group -p fence_level=async devgroup1 tcpg

The Sun Cluster Geographic Edition software runs the pairvolchk -g <DG> -ss command at the data replication level, which returns a value of 43.


# pairvolchk -g devgroup1 -ss
Volstat is P-VOL.[status = PAIR fence = ASYNC]
phys-paris-1# echo $?
43

Next, the protection group, tcpg, is deactivated by using the geopg stop command.


phys-paris-1# geopg stop -s local tcpg

The Sun Cluster Geographic Edition software runs the pairsplit -g devgroup1 command at the data replication level.

If the command is successful, the state of devgroup1 is provided in the output of the pairdisplay command:


phys-paris-1# pairdisplay -g devgroup1
Group PairVol(L/R) (Port#,TID,LU),Seq#,LDEV#,P/S,Status,Fence,Seq#,P-LDEV# M
devgroup1 pair1(L) (CL1-A , 0, 1) 12345   1..P-VOL PSUS ASYNC,54321  609   - 
devgroup1 pair1(R) (CL1-C , 0, 20)54321 609..S-VOL SSUS ASYNC,-----   1    - 
devgroup1 pair2(L) (CL1-A , 0, 2) 12345   2..P-VOL PSUS ASYNC,54321  610   - 
devgroup1 pair2(R) (CL1-C , 0,21) 54321 610..S-VOL SSUS ASYNC,-----   2    -


Example 2–20 Deactivating a Protection Group on All Clusters

This example deactivates a protection group on all clusters.


# geopg stop -e global tcpg


Example 2–21 Deactivating a Protection Group on a Local Cluster

This example deactivates a protection group on the local cluster.


# geopg stop -e local tcpg


Example 2–22 Stopping Data Replication While Leaving the Protection Group Online

This example stops only data replication on a local cluster.


# geopg stop -e local -D tcpg

If the administrator decides later to deactivate both the protection group and its underlying data replication subsystem, the administrator can rerun the command without the -D option:


# geopg stop -e local tcpg


Example 2–23 Deactivating a Hitachi TrueCopy or Universal Replicator Protection Group While Keeping Application Resource Groups Online

This example keeps two application resource groups, apprg1 and apprg2, online while deactivating their protection group, tcpg, on both clusters.

  1. Remove the application resource groups from the protection group.


    # geopg remove-resource-group apprg1,apprg2 tcpg
    
  2. Deactivate the protection group.


    # geopg stop -e global tcpg
    

Resynchronizing a Hitachi TrueCopy or Universal Replicator Protection Group

You can resynchronize the configuration information of the local protection group with the configuration information that is retrieved from the partner cluster. You need to resynchronize a protection group when its Synchronization status in the output of the geoadm status command is Error.

For example, you might need to resynchronize protection groups after booting the cluster. For more information, see Booting a Cluster in Sun Cluster Geographic Edition System Administration Guide.

Resynchronizing a protection group updates only entities that are related to Sun Cluster Geographic Edition software. For information about how to update Sun Cluster entities, see Replicating and Upgrading Configuration Data for Resource Groups, Resource Types, and Resources in Sun Cluster Data Services Planning and Administration Guide for Solaris OS.

ProcedureHow to Resynchronize a Protection Group

Before You Begin

The protection group must be deactivated on the cluster where you are running the geopg update command. For information about deactivating a protection group, see Deactivating a Hitachi TrueCopy or Universal Replicator Protection Group.

  1. Log in to a cluster node.

    You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Resynchronize the protection group.


    # geopg update protectiongroupname
    
    protectiongroupname

    Specifies the name of the protection group


Example 2–24 Resynchronizing a Protection Group

This example resynchronizes a protection group.


# geopg update tcpg

Checking the Runtime Status of Hitachi TrueCopy and Universal Replicator Data Replication

You can obtain an overall view of the status of replication, as well as a more detailed runtime status of the Hitachi TrueCopy or Universal Replicator replication resource groups. The following sections describe the procedures for checking each status.

Displaying a Hitachi TrueCopy or Universal Replicator Runtime Status Overview

The status of each Hitachi TrueCopy or Universal Replicator data replication resource indicates the status of replication on a particular device group. The status of all the resources under a protection group are aggregated in the replication status. This replication status is the second component of the protection group state. For more information about the states of protection groups, refer to Monitoring the Runtime Status of the Sun Cluster Geographic Edition Software in Sun Cluster Geographic Edition System Administration Guide.

To view the overall status of replication, look at the protection group state as described in the following procedure.

ProcedureHow to Check the Overall Runtime Status of Replication

  1. Access a node of the cluster where the protection group has been defined.

    You must be assigned the Basic Solaris User RBAC rights profile to complete this procedure. For more information about RBAC, see Sun Cluster Geographic Edition Software and RBAC in Sun Cluster Geographic Edition System Administration Guide.

  2. Check the runtime status of replication.


    # geoadm status
    

    Refer to the Protection Group section of the output for replication information. The information that is displayed by this command includes the following:

    • Whether the local cluster is enabled for partnership participation

    • Whether the local cluster is involved in a partnership

    • Status of the heartbeat configuration

    • Status of the defined protection groups

    • Status of current transactions

  3. Check the runtime status of data replication for each Hitachi TrueCopy or Universal Replicator device group.


    # clresource status
    

    Refer to the Status and Status Message fields for the data replication device group you want to check.

See Also

For more information about these fields, see Table 2–6.

Displaying a Detailed Hitachi TrueCopy or Universal Replicator Runtime Status

The Sun Cluster Geographic Edition software internally creates and maintains one replication resource group for each protection group. The name of the replication resource group has the following format:


rg-tc_truecopyprotectiongroupname

If you add a Hitachi TrueCopy or Universal Replicator device group to a protection group, Sun Cluster Geographic Edition software creates a resource for each device group. This resource monitors the status of replication for its device group. The name of each resource has the following format:


r-tc-truecopyprotectiongroupname-truecopydevicegroupname

You can monitor the status of replication of this device group by checking the Status and Status Message of this resource. Use the clresource status command to display the resource status and the status message.

The following table describes the Status and Status Message values that are returned by the clresource status command when the State of the Hitachi TrueCopy or Universal Replicator replication resource group is Online.

Table 2–6 Status and Status Messages of an Online Hitachi TrueCopy or Universal Replicator Replication Resource Group

Status 

Status Message 

Online 

P-Vol/S-Vol:PAIR 

Online 

P-Vol/S-Vol:PAIR:Remote horcmd not reachable 

Online 

P-Vol/S-Vol:PFUL 

Online 

P-Vol/S-Vol:PFUL:Remote horcmd not reachable 

Degraded 

SMPL:SMPL 

Degraded 

SMPL:SMPL:Remote horcmd not reachable 

Degraded 

P-Vol/S-Vol:COPY 

Degraded 

P-Vol/S-Vol:COPY:Remote horcmd not reachable 

Degraded 

P-Vol/S-Vol:PSUS 

Degraded 

P-Vol/S-Vol:PSUS:Remote horcmd not reachable 

Degraded 

P-Vol/S-Vol:PFUS 

Degraded 

P-Vol/S-Vol:PFUS:Remote horcmd not reachable 

Faulted 

P-Vol/S-Vol:PDFUB 

Faulted 

P-Vol/S-Vol:PDUB:Remote horcmd not reachable 

Faulted 

P-Vol/S-Vol:PSUE 

Faulted 

P-Vol/S-Vol:PSUE:Remote horcmd not reachable 

Degraded 

S-Vol:SSWS:Takeover Volumes 

Faulted 

P-Vol/S-Vol:Suspicious role configuration. Actual Role=x, Config Role=y 

For more information about these values, refer to the Hitachi TrueCopy or Universal Replicator documentation.

For more information about the clresource status command, see the clresource(1CL) man page.