Managing HP Serviceguard for Linux, Tenth Edition, September 2012

graceful shutdown of the package that is followed by disabling automatic package startup
(see auto_run” (page 206)).
You cannot halt a multi-node or system multi-node package unless all the packages that
have a configured dependency on it are down. Use cmviewcl to check the status of
dependents. For example, if pkg1 and pkg2 depend on PKGa, both pkg1 and pkg2
must be halted before you can halt PKGa.
NOTE: If you use cmhaltpkg command with the-n <nodename> option, the package
is halted only if it is running on that node.
The cmmodpkg command cannot be used to halt a package, but it can disable switching
either on particular nodes or on all nodes. A package can continue running when its
switching has been disabled, but it will not be able to start on other nodes if it stops
running on its current node.
During Halt Script Execution
Once the package manager has detected the failure of a service or package that a
failover package depends on, or when the cmhaltpkg command has been issued for
a particular package, the package manager launches the halt script. That is, a package’s
control script or master control script is executed with the stop parameter. This script
carries out the following steps (also shown in Figure 21):
1. Halts all package services.
2. Executes any customer-defined halt commands (legacy packages only) or
external_scripts (modular packages only; see external_script
(page 223)).
3. Removes package IP addresses from the LAN card on the node.
4. Unmounts file systems.
5. Deactivates volume groups.
6. Exits with an exit code of zero (0).
7. Executes any external_pre_scripts (modular packages only; see
external_pre_script” (page 223)).
How Packages Run 65