Operating System - HP-UX
1821592 Members
3366 Online
109633 Solutions
New Discussion юеВ

HPUX 11.0 MC/Serviceguard "cmgetconf" command

 
SOLVED
Go to solution
LG Porter
Frequent Advisor

HPUX 11.0 MC/Serviceguard "cmgetconf" command

I have three N4000 class servers running HPUX 11.0 with MCSG 11.09 installed configured in as "active-active" configuration. The "cmviewcl" command reveals the cluster name as "edi_online" with pkga_oracle running on node A, pkgb running on node B and pkgc_oracle running on node C. The cluster was previously configured by another source at the time of original installation and the cluster ascii configuration /etc/cmcluser/cmclconf.ascii is not available, only the binary file. Questions: A) Can the "cmgetconf" command be used to reconstruct a high availability cluster configuration file for this cluster? B) If so, what would be the correct syntax to use for this three node cluster? Thanks
7 REPLIES 7
Michael Steele_2
Honored Contributor
Solution

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command


Use the following command to store a current copy of the existing cluster configuration in a temporary file:

# cmgetconf -C /tmp/temp.asciicmgetconf -v -c mycluster temp.ascii

# cmquerycl -n n1 -n n2 -C cmclconf.ascii

Combine temp.ascii with cmclconf.ascii

cmcheckconf and cmapplyconf
Support Fatherhood - Stop Family Law
Michael Steele_2
Honored Contributor

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command

Ooops, typo:

# cmgetconf -C /tmp/temp.ascii
-or-
# cmgetconf -v -c mycluster temp.ascii
Support Fatherhood - Stop Family Law
Pramod_4
Trusted Contributor

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command

You can create a ascii cluster configuration file from the existing cmclconfig binary file by using cmgetconf command.

# cmgetconf > /etc/cmcluster/cluster.ascii

Remove all lines starting with "Warning" from /etc/cmcluster/cluster.ascii file.

If you modify any thing in that ascii file, do the following to enure that the ascii file is has correct syntax:

# cmcheckconf -C /etc/cmcluster/cluster.ascii

If you have made any changes, do a cmmaplyconf:

#cmapplyconf -C /etc/cmcluster/cluster.ascii
Sanjay_6
Honored Contributor

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command

Hi,

Use,

cmgetconf [-v] [-c cluster_name] [-p package_name] [output_filename]

# cmgetconf cluster.ascii

# cmgetconf -p (pkg_name) (config.pkg1_name)

Verify that the conf file is good.

# cmcheckconf -C cluster.ascii

Hope this helps.

Regds
LG Porter
Frequent Advisor

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command

Sanjay, Michael

In this case, since this cluster has three different packages running..that is, a different package on each node in the cluster, each package would need to be specified as part of the command syntax, right? Thanks
Michael Steele_2
Honored Contributor

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command

Absolutely. You've got three different package configuration files and control files right?

'package.cntl' and 'package.conf' files are bound together in pairs. For this command use the 'package.conf' file.
Support Fatherhood - Stop Family Law
Stephen Doud
Honored Contributor

Re: HPUX 11.0 MC/Serviceguard "cmgetconf" command

The following script automates the process.


#!/sbin/sh
# This script automates the recreation of the cluster and package
# configuration files based on the cluster binary present on the server
# If the cluster binary is out of date with the current hardware
# configuration, the configuration files may not succeed a cmcheckconf
# or cmapplyconf.

PATH=/sbin:/usr/sbin:/usr/bin
export PATH
print "Reconstituting the cluster configuration file. This may take some time..."
cmgetconf /etc/cmcluster/CLUSTER.ASCII 1>/dev/null
print "Saved it at /etc/cmcluster/CLUSTER.ASCII"
for PKG in `cmviewconf | grep "package name" | cut -f 4,4` ; do
cmgetconf -p $PKG /etc/cmcluster/$PKG.config
print "Recreated package $PKG configuration file at /etc/cmcluster/$PKG.config"
done
else
print "No cluster binary on this server."
exit
=============

sd