4.Perform maintenance actions (for example, changing the configuration of the Tomcat instance, or making changes to the toolkit configuration file, hatomcat.conf. If this file is changed, remember to distribute the new file to all cluster nodes).

5.Start the tomcat instance again if it is stopped using cd /etc/cmcluster/pkg/ tomcat_pkg1/ $PWD/toolkit.sh start.

6.Allow monitoring scripts to continue normally as shown below:rm -f /etc/cmcluster/pkg/tomcat_pkg1/tomcat.debug

A message "Starting Tomcat toolkit monitoring again after maintenance" appears in the Serviceguard Package Control script log.

7.Enable the package failover: cmmodpkg -e tomcat_pkg1

NOTE: If the package fails during maintenance (for example, the node crashes), the package will not automatically fail over to an adoptive node. It is the responsibility of the user to start the package up on an adoptive node. See Managing ServiceGuard manual available at http:// www.hp.com/go/hpux-serviceguard-docs —>HP Serviceguard " for more details.

NOTE: This feature is enabled only when the configuration variable MAINTENANCE_FLAG is set to "yes" in the tomcat toolkit configuration file /etc/cmcluster/pkg/tomcat_pkg1/

hatomcat.conf.

Configuring Apache web server with Tomcat in a single package

NOTE: This section contains details on configuring Apache web server with Tomcat in a single package only for the legacy method of packaging. For configuring Apache and Tomcat in a single package using the modular method of packaging, see whitepaper Modular package support in Serviceguard for Linux and ECM Toolkits available at http://www.hp.com/go/ hpux-serviceguard-docs —>HP Serviceguard Enterprise Cluster Master Toolkit.

Tomcat can be setup in a stand alone configuration that allows web browsers to be connected directly to the tomcat servlet or through web server such as Apache. To integrate Tomcat with Apache, the JK Connector is used. The mod_jk component needs to be configured in Apache in order to make Apache work with Tomcat. When the user chooses this type of configuration and it needs to be deployed in a highly available Serviceguard environment then both the Apache and Tomcat toolkit need to be configured in a single package. The example below gives the steps for configuring such a package. This example assumes that both Apache and Tomcat server are configured on a single Volume group vg01 (in case of LVM) and a single mount point /share/pkg_1.

1.mkdir -p /etc/cmcluster/pkg/http_pkg1 /etc/cmcluster.2.Copy the Apache and Tomcat toolkits files into the respective directories.

3.Edit the user configuration files of both Apache and Tomcat and make suitable changes. See “Using an Apache Toolkit in a HP Serviceguard Cluster” (page 97) and “Using Tomcat Toolkit in a HP Serviceguard Cluster” (page 110)

4.cd /etc/cmcluster/pkg/tomcat_pkg15.Create the Serviceguard Package configuration and Package control scripts

cmmakepkg -p pkg1.ascii (Serviceguard Package configuration script) cmmakepkg -s pkg1.cntl (Serviceguard Package control script).

6.Edit the Package Configuration script "pkg1.ascii" and configure it. Also configure two services "http_pkg1.monitor" and "tomcat_pkg1.monitor" as shown below:

SERVICE_NAMEtomcat_pkg1.monitor

SERVICE_FAIL_FAST_ENABLED NO

SERVICE_HALT_TIMEOUT300

122 Using Tomcat Toolkit in a HP Serviceguard Cluster