Managing HP Serviceguard for Linux, Tenth Edition, September 2012

before_package_start. If not specified, default during_package_start is
considered.
during_package_start means the status of generic resources are evaluated
during the course of start of the package.
before_package_start means resource monitoring must be started before
the package start and all the configured resources have to be UP on a given
node for the package to be started on that node.
generic_resource_up_criteria: defines a criterion to determine the 'up'
condition for a generic resource. It also determines whether a generic resource is
a simple resource or an extended resource. This parameter requires an operator
and a value. The operators ==, !=, >, <, >=, and <= are allowed. Values must be
positive integer values ranging from 1 to 2147483647.
The following is an example of how to configure simple and extended resources.
Simple generic resource:
generic_resource_name sfm_disk
generic_resource_evaluation_type before_package_start
Extended generic resource:
generic_resource_name cpu_lan
generic_resource_evaluation_type during_package_start
generic_resource_up_criteria <50
For more information on the generic resource parameters, see “Package Parameter
Explanations” (page 205).
Configuring a Generic Resource
This section describes the step-by-step procedure to configure generic resources. You can
also configure generic resources from the Serviceguard Manager. See the online help
for instructions on how to configure from Serviceguard Manager.
1. Create a package configuration file that contains the generic resource module:
cmmakepkg $SGCONF/pkg1/pkg1.conf
Package template is created.
This file must be edited before it can be used.
NOTE: To generate a configuration file adding the generic resource module to an
existing package (enter the command all on one line):
cmmakepkg -i $SGCONF/pkg1/pkg1.conf -m sg/generic_resource
2. Edit the package configuration file and specify the generic resource parameters (as
shown in the snippet):
service_name sfm_disk_monitor
service_cmd /etc/cmcluster/pkg1/sample_generic_resource_disk_monitor.sh
service_halt_timeout 10
126 Planning and Documenting an HA Cluster