|Skip Navigation Links|
|Exit Print View|
|Oracle Solaris Cluster Geographic Edition System Administration Guide Oracle Solaris Cluster 4.1|
Before You Begin
Ensure that the following conditions are met:
The local cluster is a member of a partnership.
The protection group you are creating does not already exist, if you are going to create the MySQL configuration.
The protection group exists if you want to do anything other than create the MySQL configuration.
You must be assigned the Geo Management RBAC rights profile to complete this procedure. For more information, see Geographic Edition Software and RBAC.
cl1-phys-node1 # cp /opt/SUNWscmys/geocontrol/util/mysql_geo_config /temp
PS=mysql-ps PG=mysql-pg REPCOMP=mysql.sbp REPRS=mysql-rep-rs REPRG=mysql-rep-rg DESC="mysql replication pg" CONFIGFILE=/geo-config/sbpconfig REALMYSRG=nyc-rg,sfo-rg REALMYSRS=nyc-mys-rs,sfo-mys-rs READONLY= APPRG=usa-rg LONGPING= SHORTPING=
For example, assuming that the nodes of cluster one are cl1-phys-node1 and cl1-phys-node2, on each node of cluster one, you would issue the following commands:
cl1-phys-node1 # mkdir /geo-config cl1-phys-node1 # echo "mysql.sbp|any|cl1-phys-node1,cl1-phys-node2">/geo-config/sbpconfig
Assuming that the nodes of cluster two are cl2-phys-node3 and cl2-phys-node4, on each node of cluster two, you would issue the following commands:
cl2-phys-node1 # mkdir /geo-config cl2-phys-node1 # echo "mysql.sbp|any|cl2-phys-node3,cl2-phys-node4">/geo-config/sbpconfig
cl1-phys-node1 # ksh /opt/SUNWscmys/geocontrol/util/mysql_geo_register -f /temp/mysql_geo_config
The final messages of the registration script outline the required geopg get command. You must log in to one node of the partner cluster and execute that exact command.
cl2-phys-node3 # geopg get --partnership mysql-ps mysql-pg
If the partner cluster contains a protection group with the same name, the geopg set-propcommand also propagates the new configuration information to the partner cluster.
Use the following command to modify a MySQL protection group:
# geopg set-prop -p property[-p...] protection-group
In this syntax, -p property specifies the properties of the protection group, and protection-group specifies the name of the protection group.
For more information about the properties you can set, see Property Descriptions for Script-Based Plug-Ins.
The geopg set-propcommand revalidates the protection group with the new configuration information. If the validation 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 validation is unsuccessful on the partner cluster, the configuration status is set to Error on the partner cluster.
For information about the names and values that are supported, see Appendix B, Legal Names and Values of Geographic Edition Entities.
For more information about the geopg command, refer to the geopg(1M) man page.
Example F-1 Modifying the Timeout Property of a Protection Group
The following example shows how to modify the timeout property of a protection group.
# geopg set-prop -p Timeout=300 mysql-pg
When the configuration status of a protection group is displayed as Error in the geoadm status output, you can validate the configuration by using the geopg validatecommand. This command checks the current status 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 validatecommand finds an error in the configuration files, then the command displays an error message, and the configuration remains in the Error state. In such a case, you can fix the error in the configuration, and rerun the geopg validatecommand.
The geopg validatecommand validates the configuration of the protection group on the local cluster only. To validate the protection group configuration on the partner cluster, rerun the command on the partner cluster.
Before validating the configuration of a protection group, 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.
Validate the configuration of the protection group.
Use the following command to validate the configuration of a protection group on the local cluster only:
# geopg validate protection-group
In this syntax, protection-group specifies a unique name that identifies a single protection group.
In the following example, the configuration of a protection group is validated:
# geopg validate mysql-pg
During protection group validation, the MySQL data replication layer validates the application resource groups and the data replication entities by verifying that an application resource group in the protection group has its Auto_start_on_new_cluster property set to false.
When you bring a protection group online on the primary cluster, bring the application resources groups participating in that protection group online only on the same primary cluster. Setting the Auto_start_on_new_cluster property to false prevents the Oracle Solaris Cluster resource group manager from automatically starting the application resource groups. In this case, the startup of resource groups is reserved for the Geographic Edition software.
Application resource groups should be online only on the primary cluster when the protection group is activated.
The MySQL geocontrol module supplies a script that is used by the script-based plug-in module. The script entry points require the same set of arguments. These arguments are validated for semantics and completeness. The following validation checks are performed:
Are all of the mandatory arguments defined?
Is the configured MySQL database resource defined?
Is the specified replication resource configured with a correct start command, if the resource exists already?
Are the long and short ping intervals numeric?
When the validation is complete, the Geographic Edition software creates and brings online the replication resource group and its resources if they don't already exist. If a resource group or resource of the same name already exists, the Geographic Edition software might modify its properties. The software cannot create a new resource group or a resource of the same name if one already exists. After creating the necessary resources, the software adds the application resource group to the protection group.