HP Serviceguard Version A.11.19 Release Notes, October 2009
see the white paper Migrating Packages from Legacy to Modular Style at the address given
under “Documents for This Version ” (page 50).
NOTE: The cmmigratepkg command requires Perl version 5.8.3 or higher on the
system on which you run the command. It should already be on the system as part of
the HP-UX base product.
Other Package Changes First Introduced in Serviceguard A.11.18 Patches
NOTE: For information about legacy and modular packages, see Chapter 6 of Managing
Serviceguard.
Features first introduced in a patch to Serviceguard A.11.18 provide the following new
capabilities:
• Serviceguard now supplies information explaining why a package has shut down.
Serviceguard will set the new environment variable SG_HALT_REASON in the
package control script to one of the following values when the package halts:
— failure — set if the package halts because of the failure of a subnet, resource,
or service it depends on
— user_halt — set if the package is halted by a cmhaltpkg or cmhaltnode
command, or by corresponding actions in Serviceguard Manager
— automatic_halt — set if the package is failed over automatically because
of the failure of a package it depends on, or is failed back to its primary node
automatically (failback_policy = automatic)
You can add custom code to the package to interrogate this variable, determine
why the package halted, and take appropriate action. For legacy packages, put the
code in the customer_defined_halt_cmds() function in the CUSTOMER
DEFINED FUNCTIONS area of the package control script; for modular packages,
put the code in the package’s external script. (See Chapter 4 of Managing
Serviceguard for information about external scripts.)
For example, if a database package is being halted by an administrator
(SG_HALT_REASON set to user_halt) you would probably want the custom
code to perform an orderly shutdown of the database; on the other hand, a forced
shutdown might be needed if SG_HALT_REASON is set to failure,
indicating thatthe package is halting abnormally (for example because of the
failure of a service it depends on).
• cmviewcl -v -f line has a new field, last_halt_failed, that shows
whether the last invocation of the halt script of a package on a node succeeded or
failed. The value is no if the halt script ran successfully, or was not run since the
40 Serviceguard Version A.11.19 Release Notes