Managing HP Serviceguard for Linux, Eighth Edition, March 2008

Understanding Serviceguard Software Components
Responses to Failures
Chapter 3 91
Responses to Package and Service Failures
In the default case, the failure of the package or of a service within a
package causes the package to shut down by running the control script
with the 'stop' parameter, and then restarting the package on an
alternate node. A package will also fail if it is configured to have a
dependency on another package, and that package fails.
You can modify this default behavior by specifying that the node should
halt (system reset) before the transfer takes place. You do this by setting
failfast parameters in the package configuration file.
In cases in which package shutdown might hang, leaving the node in an
unknown state, failfast options can provide a quick failover, after which
the node will be cleaned up on reboot. Remember, however, that a system
reset causes all packages on the node to halt abruptly.
The settings of the failfast parameters in the package configuration file
determine the behavior of the package and the node in the event of a
package or resource failure:
•If service_fail_fast_enabled is set to yes in the package
configuration file, Serviceguard will reboot the node if there is a
failure of that specific service.
•If node_fail_fast_enabled is set to yes in the package
configuration file, and the package fails, Serviceguard will halt
(reboot) the node on which the package is running.
For more information about configuring packages, see “Package
Configuration Planning” on page 119 and “Configuring Packages and
Their Services” on page 199.
Service Restarts
You can allow a service to restart locally following a failure. To do this,
you indicate a number of restarts for each service in the package control
script. When a service starts, the variable RESTART_COUNT is set in the
service’s environment. The service, as it executes, can examine this
variable to see whether it has been restarted after a failure, and if so, it
can take appropriate action such as cleanup.