| United States-English |
|
|
|
![]() |
Configuring OPS Clusters with ServiceGuard OPS Edition > Chapter 5 Building an OPS
Cluster ConfigurationConfiguring the Cluster |
|
This section describes how to define the basic cluster configuration. To do this in SAM, read the next section. If you want to use ServiceGuard commands, skip ahead to the section "“Using ServiceGuard Commands to Configure the Cluster”." To configure a high availability cluster, use the following steps on the configuration node (ftsys9):
Skip ahead to the section "“Installing Oracle Parallel Server ”." Use the cmquerycl command to specify a set of nodes to be included in the cluster and to generate a template for the cluster configuration file. Here is an example of the command as issued from node ftsys9:
The example creates an ASCII template file in the default cluster configuration directory, /etc/cmcluster. The ASCII file is partially filled in with the names and characteristics of cluster components on the two nodes ftsys9 and ftsys10. Edit the filled-in cluster characteristics as needed to define the desired cluster. It is strongly recommended that you edit the file to send heartbeat over all possible networks.
The following is an example of an ASCII configuration file generated with the cmquerycl command using the -w full option.
The man page for the cmquerycl command lists the definitions of all the parameters that appear in this file. Many are also described in the chapter "Chapter 4 “Planning and Documenting an OPS Cluster”." Modify the /etc/cmcluster/cmcl.config file to your requirements, using the data on the cluster configuration worksheet. In the file, keywords are separated from definitions by white space. Comments are permitted, and must be preceded by a pound sign (#) in the far left column. See the man page for the cmquerycl command for more details. The file includes entries for all package volume groups that are to be defined as cluster-aware, that is, those which can be accessed by packages running on different nodes in the cluster at different times. A separate VOLUME_GROUP line should appear for each volume group that will be activated by any package running in the cluster. To leave a volume group unmarked, remove the volume group name from the ASCII file.
The template file also includes entries for all LVM volume groups used by the Oracle Parallel Server that are accessed concurrently by the different nodes in the cluster. These volume groups are activated by the vgchange -a s command in the control script that activates each OPS instance. A separate OPS_VOLUME_GROUP line should appear for each LVM volume group that will be activated in shared mode. Volume groups that will be used by Oracle Parallel Server must be labeled OPS_VOLUME_GROUP.
In configuring a new cluster, if you are using volume groups that were used in a previous cluster configuration, you should ensure that they are not currently cluster aware (marked with a cluster id). You can use the following command to remove the cluster id if necessary:
The cluster ASCII file includes entries for IP addresses on the heartbeat subnet. It is recommended that you use a dedicated heartbeat subnet, but it is possible to configure heartbeat on other subnets as well, including the data subnet.
A cluster lock is required for two node clusters like the one in this example. The lock must be accessible to all nodes and must be powered separately from the nodes. Enter the lock disk information in the cluster ASCII file following the cluster name. The lock disk must be in an LVM volume group that is accessible to all the nodes in the cluster. The default FIRST_CLUSTER_LOCK_VG and FIRST_CLUSTER_LOCK_PV supplied in the ASCII template created with cmquerycl are the volume group and physical volume name of a disk chosen based on minimum failover time calculations. You should ensure that this disk meets your power wiring requirements. If necessary, choose a disk powered by a circuit which powers fewer than half the nodes in the cluster. To display the failover times of disks, use the cmquerycl command, specifying all the nodes in the cluster:
The output of the command lists the disks connected to each node together with the re-formation time associated with each.
If your configuration requires you to configure a second cluster lock, enter the following parameters in the cluster configuration file:
where the /dev/volume-group is the name of the second volume group and block-special-file is the physical volume name of a lock disk in the chosen volume group. These lines should be added for each node. To specify a quorum server instead of a lock disk, use the -q option of the cmquerycl command, specifying a Quorum Server host server. Example: # cmquerycl -n node1 -n node2 -q lp-qs The cluster ASCII file that is generated in this case contains parameters for defining the quorum server. This portion of the file is shown below:
Enter the QS_HOST, QS_POLLING_INTERVAL and, if desired, a QS_TIMEOUT_EXTENSION. ServiceGuard OPS Edition preallocates memory and threads at cluster startup time. It calculates these values based on the number of packages specified in the MAX_CONFIGURED_PACKAGES parameter in the cluster configuration file. This value must be equal to or greater than the number of packages currently configured in the cluster. The default is 0, which means that you must enter a value if you wish to use packages. The absolute maximum number of packages per cluster is 60. ServiceGuard reserves approximately 6MB plus about 80KB of memory for each package. When selecting a value for MAX_CONFIGURED_PACKAGES, be sure to include the CVM-VxVM-PKG as part of the total in MAX_CONFIGURED_PACKAGES if you will be using VERITAS CVM disk storage.
The cmquerycl command supplies default cluster timing parameters for HEARTBEAT_INTERVAL and NODE_TIMEOUT. Changing these parameters will directly impact the cluster's reformation and failover times. It is useful to modify these parameters if the cluster is reforming occasionally due to heavy system load or heavy network traffic. The default value of 2 seconds for NODE_TIMEOUT leads to a best case failover time of 30 seconds. If NODE_TIMEOUT is changed to 10 seconds, which means that the cluster manager waits 5 times longer to timeout a node, the failover time is increased by 5, to approximately 150 seconds. NODE_TIMEOUT must be at least 2*HEARTBEAT_INTERVAL. A good rule of thumb is to have at least two or three heartbeats within one NODE_TIMEOUT. SAM automatically checks the configuration you enter and reports any errors. If you have edited an ASCII cluster configuration file, use the following command to verify the content of the file:
This command or automatic verification in SAM both check the following:
If the cluster is online, SAM (or the cmcheckconf command) also verifies that all the conditions for the specific change in configuration have been met. After specifying all cluster parameters, you use SAM or HP-UX commands to apply the configuration. This action distributes the binary configuration file to all the nodes in the cluster. We recommend doing this separately before you configure packages (described in the next chapter, "Chapter 6 “Configuring Packages and Their Services”"). In this way, you can verify the cluster lock, heartbeat networks, and other cluster-level operations by using the cmviewcl command on the running cluster. Before distributing the configuration, ensure that your security files permit copying among the cluster nodes. See the section "“Preparing Your Systems ”" at the beginning of this chapter. When you have finished entering parameters in the Cluster Configuration subarea in SAM, you are asked to verify the copying of the files to all the nodes in the cluster. When you respond OK to the verification prompt, ServiceGuard copies the binary configuration file and the ASCII configuration file to all the nodes in the cluster. Use the following steps to generate the binary configuration file and distribute the configuration to all nodes in the cluster:
The cmapplyconf command creates a binary version of the cluster configuration file and distributes it to all nodes in the cluster. This action ensures that the contents of the file are consistent across all nodes. Note that the cmapplyconf command does not distribute the ASCII configuration file.
After creating the cluster configuration with SAM or with HP-UX commands, make a backup copy of the volume group configuration data by using the vgcfgbackup command for each cluster aware volume group you have created. If a disk in a volume group must be replaced, you can then restore the disk's metadata by using the vgcfgrestore command. The procedure is described in the section "“Replacing Disks”" in the chapter "Chapter 8 “Troubleshooting Your Cluster”." Be sure to use vgcfgbackup for all cluster and OPS volume groups, including the cluster lock volume group, when you first create the cluster. Use the command again for each new cluster aware volume group that you add with SAM or with HP-UX commands.
ServiceGuard Manager lets you see all the nodes and packages within a cluster and displays their current status. Refer to the section on "Using ServiceGuard Manager" in Chapter 7. The following are suggested using ServiceGuard Manager:
When you are sure the cluster is correctly configured, save a copy of the configuration data in a file for archival purposes. The data in this file can be compared with later versions of the cluster to understand the changes that are made over time. ServiceGuard also provides several commands for manual control of the cluster: You can use these commands to test cluster operation, as in the following:
Additional cluster testing is described in the chapter "Troubleshooting Your Cluster." Refer to the appendix "ServiceGuard OPS Edition Commands" for a complete list of ServiceGuard commands. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|||||||||||||||