HP 9000 Containers A.03.01 on HP Integrity Server Administrator Guide HP-UX 11i v3 (5900-3112, June 2013)

Configuring SG package
Configuration from the HP 9000 server can be reused with minor modifications as long as the
configuration is compatible with the SG version on the host system. For more information about
how to migrate older packages, see Migrating packages from legacy to modular style at
www.hp.com/go/hpux-SG-docs.
1. Use the srp_su command for starting and monitoring applications:
a. For HP 9000 system container, use the following configuration:
service_cmd ““/opt/hpsrp/bin/srp_su <srp_name> <user name>\
c <command line>””
b. For HP 9000 classic container, to run the command as root user:
service_cmd /opt/hpsrp/bin/srp_su <srp_name> root c \
chroot <hp9000_root> <command line>””
c. For HP 9000 classic container, to run the command as a non-root user:
service_cmd /opt/hpsrp/bin/srp_su <srp_name> root \
chroot <hp9000_root> /usr/bin/su - <user> -c \
<command line>””
2. Configure the package to create default routes for container IP addresses managed by SG
(the package IPs):
For example,
# srp_route_script configures the required source based
# routing entries for the SG managed IP addresses
external_script /etc/cmcluster/pkg1/srp_route_script
A reference implementation of this script is available in the /opt/hpsrp/example/
serviceguard/srp_as_sg_package/srp_route_script file.
10.6 Copying and applying package configuration
Copy the package configuration in the failover node. Apply configuration on the primary node
and test failover using the following commands:
$ cmcheckconf P <package configuration>
$ cmapplyconf P <package configuration>
$ cmrunpkg v n <primary node name> <package>
Test the SG failover by manually stopping an application.
10.6 Copying and applying package configuration 71