Managing HP Serviceguard A.11.20.20 for Linux, March 2014

You can use Serviceguard Manager to start a package, or Serviceguard commands as shown
below.
Use the cmrunpkg command to run the package on a particular node, then use the cmmodpkg
command to enable switching for the package; for example:
cmrunpkg -n ftsys9 pkg1
cmmodpkg -e pkg1
This starts up the package on ftsys9, then enables package switching. This sequence is necessary
when a package has previously been halted on some node, since halting the package disables
switching.
7.4.1.1 Starting a Package that Has Dependencies
Before starting a package, it is a good idea to use the cmviewcl command to check for package
dependencies.
You cannot start a package unless all the packages that it depends on are running. If you try, you’ll
see a Serviceguard message telling you why the operation failed, and the package will not start.
If this happens, you can repeat the run command, this time including the package(s) this package
depends on; Serviceguard will start all the packages in the correct order.
7.4.2 Halting a Package
You halt a package when you want to stop the package but leave the node running.
Halting a package has a different effect from halting the node. When you halt the node, its packages
may switch to adoptive nodes (assuming that switching is enabled for them); when you halt the
package, it is disabled from switching to another node, and must be restarted manually on another
node or on the same node.
System multi-node packages run on all cluster nodes simultaneously; halting these packages stops
them running on all nodes. A multi-node package can run on several nodes simultaneously; you
can halt it on all the nodes it is running on, or you can specify individual nodes.
You can use Serviceguard Manager to halt a package, or cmhaltpkg; for example:
cmhaltpkg pkg1
This halts pkg1 and disables it from switching to another node.
7.4.2.1 Halting a Package that Has Dependencies
Before halting a package, it is a good idea to use the cmviewcl command to check for package
dependencies.
You cannot halt a package unless all the packages that depend on it are down. If you try, you’ll
see a Serviceguard message telling you why the operation failed, and the package will remain
up.
If this happens, you can repeat the halt command, this time including the dependent package(s);
Serviceguard will halt the all the packages in the correct order. First, use cmviewcl to be sure
that no other running package has a dependency on any of the packages you are halting.
7.4.2.2 Handling Failures During Package Halt
When you halt a package using cmhaltpkg, sometimes errors may occur for various reasons
resulting in the failure of the command. Serviceguard provides an option so that packages can be
halted in a way that when errors occur the halting process is aborted.
When you halt a package, if one of the non-native Serviceguard modules fails with an exit status
of 3, the halt is aborted and the package is moved to a partially_down status in a
halt_aborted state. For information about package status and state, see “Package Status and
State” (page 200).
218 Cluster and Package Maintenance