Create a Cluster Packages within HP Serviceguard on Linux

Create a Cluster Packages on Linux, create HP Serviceguard Cluster packages, create a serviceguard cluster, create linux cluster package step by step

Create a Cluster Packages within the HP Serviceguard Cluster on Linux
This post will guide you to create cluster packages within the HP Serviceguard Cluster on Linux.

Already we have seen the cluster installation and cluster creation in the previous article. Checkout the link

Our Cluster Example Setup:
Primary Node Server :
Hostname : node1.learnitguide.net
OS : RHEL 5.4
Node 1 Lan Port 1 : 10.10.10.10 (Connected to swtich for administrator use to manage the server)
Node 1 Lan Port 2 : 172.19.1.10 (Connected directly to Node 2 Lan Port 2 to have a heartbeat link)
MC Service GUARD : Evaluation version 11.19
Secondary Node Server :
Hostname : node2.learnitguide.net
OS : RHEL 5.4
Node 2 Lan Port 1 : 10.10.10.11 (Connected to swtich for administrator use to manage the server)
Node 2 Lan Port 2 : 172.19.1.11 (Connected directly to Node 1 Lan Port 2 to have a heartbeat link)
MC Service GUARD : Evaluation version 11.19

1. Create a dedicated folder for each packages under the default serviceguard installed directory (usr/local/cmcluster)
[root@node1 ~] cd usr/local/cmcluster/
[root@node1 cmcluster] mkdir mypkg1
[root@node1 cmcluster] chmod 700 mypkg1
2. Create package configuration and script templates.
[root@node1 cmcluster] cmmakepkg -p mypkg1/pkg1.conf
[root@node1 cmcluster] cmmakepkg -s mypkg1/pkg1.sh
3. Edit the package configuration mypkg1/pkg1.conf.
Make the required changes as per our requirement as below like package name, type, node names, run and halt script, policy, service name, timeout.
PACKAGE_NAME mypkg1
PACKAGE_TYPE FAILOVER
NODE_NAME node1
NODE_NAME node2
AUTO_RUN YES
NODE_FAIL_FAST_ENABLED NO
RUN_SCRIPT /usr/local/cmcluster/mypkg1/pkg1.sh
HALT_SCRIPT /usr/local/cmcluster/mypkg1/pkg1.sh
RUN_SCRIPT_TIMEOUT 800
HALT_SCRIPT_TIMEOUT 800
SUCCESSOR_HALT_TIMEOUT 800
FAILOVER_POLICY CONFIGURED_NODE
FAILBACK_POLICY MANUAL
PRIORITY NO_PRIORITY
SERVICE_NAME myservice1
SERVICE_FAIL_FAST_ENABLED no
SERVICE_HALT_TIMEOUT 300
4. Edit the package script mypkg1/pkg1.sh.
Here in this file, we include our Package IP address, service names, commands as below.
# IP ADDRESSES
IP[0]="10.10.10.20"
SUBNET[0]="10.10.10.0"
# SERVICE NAMES AND COMMANDS.
SERVICE_NAME[0]="myservice1"
SERVICE_CMD[0]="/usr/bin/xload -display 10.10.10.50 -label `uname -n`:myservice"
SERVICE_RESTART[0]="-R"
where 10.10.10.50 is our X server for testing purpose, hence we are not using any shared disk lun. If you planned for oracle cluster package, include your shared lun disk to be available in all nodes, oracle package scripts. We will discuss the oracle package creation and configuration in the upcoming topics. Same way we can use the HP Serviceguard high-availability cluster software for nfs, samba and many other services.

5. Copy the necessary files to the other nodes.
[root@node1 cmcluster] scp -r /usr/local/cmcluster/mypkg1 node2:/usr/local/cmcluster/
6. Verify the cluster package configuration for errors.
[root@node1 cmcluster] cmcheckconf -P mypkg1/pkg1.conf
If you get any errors, please fix the errors.
If you dont see any errors, please go for applying the package cluster configuration.

7. Apply the Cluster Package configuration.
[root@node1 cmcluster] cmapplyconf -v -P mypkg1/pkg1.conf
8. Enable the autostart to the package.
[root@node1 cmcluster] cmmodpkg -e mypkg1
8. Check the Cluster Package status from both nodes.
[root@node1 cmcluster] cmviewcl -v -P mypkg1
We are done the cluster package creation. we can create 'N' number of packages in a single cluster.
You may come in a situtation to modify the running cluster packages, we will discuss in the upcoming article.

We appreciate your feedback and Leave your comments if any.
Subscribe us on youtube channel for practical video tutorials and follow us on social networking sites to not miss any updates. Create a Cluster Packages on Linux, create HP Serviceguard Cluster packages, How to Configure Linux Cluster with 2 Nodes on RedHat, Building a Linux Cluster, setting up a servicegaurd cluster package, create a cluster package step by step with examples, Reconfiguring a Package on a Running Cluster, Cluster Create MC Serviceguard Cluster on linux, serviceguard cluster commands, serviceguard cluster configuration
October 16, 2015

Post a Comment

[disqus][facebook][blogger]

Contact Form

Name

Email *

Message *

Powered by Blogger.
Javascript DisablePlease Enable Javascript To See All Widget