HP Serviceguard Contributed Toolkit Suite Version A.04.02.02 on Linux User Guide (December, 2012)
5. Validate the configuration using the cmcheckconf command:
# cmcheckconf -P pgsql_pkg.conf
6. Create the package using the cmapplyconf command, if the cmcheckconf command does
not report any errors:
# cmapplyconf -P pgsql_pkg.conf
Managing packages
You can manage packages by running, maintaining, halting, and deleting them.
Running packages
To start a package:
# cmrunpkg <package_name>
Maintaining packages
HP Serviceguard normally monitors critical processes, but there might be situations when a planned
maintenance task (for example, changing the configuration) is required that affects those monitored
processes. The maintenance flag can be used to signal to Serviceguard that it must not failover the
instance to an adoptive node.
For easy comprehension, the following naming conventions are used in this section:
• Package name: pg_pkg1
• Package directory: $SGCONF/pg_pkg1
• Shared configuration on a file system: /pgsql1
To set a PostgreSQL toolkit package to the maintenance mode:
1. Enable the maintenance for the package during package creation.
To enable the maintenance mode, set the MAINTENANCE_FLAG to yes in the package
configuration file or in the PostgreSQL toolkit configuration file, and then apply the configuration
running the cmapplyconf command.
2. Create an empty file to pause the monitoring of PostgreSQL server processes script
$SGCONF/pg_pkg1/pgsql.debug as shown below:
touch $SGCONF/pg_pkg1/pgsql.debug
The toolkit monitoring script stops monitoring the PostgreSQL daemons running for the instance
configured for the package. The following message is logged in the package control script:
PostgreSQL toolkit pausing, monitoring, and entering maintenance
mode.
3. Perform the maintenance actions.
For example, you can change the configuration of the PostgreSQL instance, or install a
PostgreSQL patch.
4. To start the monitoring process, run the following command:
# rm -f $SGCONF/pg_pkg1/pgsql.debug
The following message is recorded in the Serviceguard package control script log:
Starting PostgreSQL toolkit monitoring again after maintenance.
NOTE: Ensure that the PostgreSQL server instance is up and running before removing the
pgsql.debug file.
34 PostgreSQL Toolkit