Managing HP Serviceguard A.11.20.10 for Linux, December 2012

To create the package, follow the steps in the chapter Chapter 6: “Configuring Packages and Their
Services (page 163). Then use a command such as the following to verify the configuration of the
newly created pkg1 on a running cluster:
cmcheckconf -P $SGCONF/pkg1/pkg1conf.conf
Use a command such as the following to distribute the new package configuration to all nodes in
the cluster:
cmapplyconf -P $SGCONF/pkg1/pkg1conf.conf
If this is a legacy package, remember to copy the control script to the $SGCONF/pkg1 directory
on all nodes that can run the package.
7.8.6 Deleting a Package from a Running Cluster
Serviceguard will not allow you to delete a package if any other package is dependent on it. To
check for dependencies, use cmviewcl -v -l <package>. System multi-node packages cannot
be deleted from a running cluster.
You can use Serviceguard Manager to delete the package.
On the Serviceguard command line, you can (in most cases) delete a package from all cluster
nodes by using the cmdeleteconf command. This removes the package information from the
binary configuration file on all the nodes in the cluster. The command can only be executed when
the package is down; the cluster can be up.
The following example halts the failover package mypkg and removes the package configuration
from the cluster:
cmhaltpkg mypkg cmdeleteconf -p mypkg
The command prompts for a verification before deleting the files unless you use the -f option. The
directory $SGCONF/mypkg is not deleted by this command.
7.8.7 Resetting the Service Restart Counter
The service restart counter tracks the number of times a package service has been automatically
restarted. This value is used to determine when the package service has exceeded its maximum
number of allowable automatic restarts.
When a package service successfully restarts after several attempts, the package manager does
not automatically reset the restart count. You can reset the counter online using cmmodpkg -R
-s, for example:
cmmodpkg -R -s myservice pkg1
This sets the counter back to zero. The current value of the restart counter appears in the output of
cmviewcl -v.
7.8.8 Allowable Package States During Reconfiguration
In many cases, you can make changes to a package’s configuration while the package is running.
The table that follows shows exceptions — cases in which the package must not be running, or in
which the results might not be what you expect — as well as differences between modular and
legacy packages.
234 Cluster and Package Maintenance