Go to main content

Administering the Disaster Recovery Framework for Oracle® Solaris Cluster 4.4

Exit Print View

Updated: June 2019
 
 

Configuring a Protection Group to Run a Script at Switchover or Takeover

After you have created a script, you must configure the protection group to run the script when a switchover or takeover occurs. If a switchover or takeover occurs, the script runs on the cluster that is becoming the new primary cluster.

How to Configure a Protection Group to Run a Script at Switchover or Takeover

  1. Log in to a cluster node.

    You must be assigned the Geo Management rights profile to complete this procedure. For more information, see Disaster Recovery Framework Rights Profiles in Installing and Configuring the Disaster Recovery Framework for Oracle Solaris Cluster 4.4.

  2. Configure the RoleChange_ActionCmd and RoleChange_ActionArgs properties of the protection group.
    # geopg set-prop -p RoleChange_ActionCmd=fully-qualified-script \
    -p RoleChange_ActionArgs=script-arguments protection-group-name
    –p property-setting

    Specifies the properties of the protection group.

    Specify the path to the command by using the RoleChange_ActionCmd property. This path should be valid on all nodes of all partner clusters that can host the protection group.

    Define the arguments that you want to append to the command line when the action command is run by using the RoleChange_ActionArgs property.

    For more information about the properties you can set, see Standard Disaster Recovery Framework Properties.

    protection-group

    Specifies the name of the protection group.

Example 35  Configuring a Protection Group to Run a Command at Cluster Switchover or Takeover

This example configures a protection group to run a custom command called newDNS.

# geopg set-prop -p RoleChange_ActionCmd=/usr/bin/newDNS \
-p RoleChange_ActionArgs=domain=example.com,ip=192.0.2.4 avspg