This procedure assumes that you installed the data service package during your initial Sun Cluster HA for Sun Java System Application Server installation. If you did not install the Sun Java System Application Server package as part of your initial installation, go to Installing the Sun Cluster HA for Sun Java System Application Server Package to install the data service package.
Before you begin to register and configure Sun Cluster HA for Sun Java System Application Server as a service mastered on multiple nodes at the same time, consider the following requirements.
You must have the Sun Java System Web Server Plugin installed and configured. See Configuring the Sun Java System Web Server Plugin.
You must specify at least one entry for the Monitor_URI_List extension property. If there are no deployed applications that need to be monitored, use a simple Uniform Resource Identifier (URI) such as http://localhost/.
See Multiple Masters Configuration Overview for conceptual information related to this procedure.
Do not use the Sun Java System Application Server command-line or GUI administrative tools to start or stop the Sun Java System Application Server instances. The Sun Java System Application Server administrative server might not display the correct status of an application server instance that is configured as a service mastered on multiple nodes.
Become superuser on one of the nodes in the cluster that hosts the application server.
Add a scalable resource group for the Sun Java System Application Server.
# scrgadm -a -g resource-group \ -y Maximum_primaries=value \ -y Desired_primaries=value [-h nodelist] |
Register the resource type for the Sun Java System Application Server.
# scrgadm -a -t SUNW.s1as |
Add the Sun Java System Application Server resource instance to the resource group.
# scrgadm -a -j resource -g resource-group -t SUNW.s1as \ -x Confdir_list=install-directory/domains/domain/server \ -x Monitor_Uri_List=http://localhost[:port][/path] |
Specifies the Sun Java System Application Server application resource name.
Specifies the type of resource to add.
Specifies a path for your Sun Java System Application Server configuration directory. The Confdir_list extension property is required and must have exactly one entry.
Specifies URIs from which Sun Cluster HA for Sun Java System Application Server makes requests. The Monitor_Uri_List extension property is required.
Bring the scalable resource group online.
# scswitch -Z -g resource-group |
Brings the resource group online.
Specifies the name of the application resource group to bring online.
This example shows how to register Sun Cluster HA for Sun Java System Application Server as a service mastered on two nodes at the same time.
Cluster Information
Node names: phys-schost-1, phys-schost-2
Resource group: appsrv-rg (for all resources)
To create a scalable resource group, the following command is run.
# scrgadm -a -g appserv-rg \ -y Maximum_primaries=2 \ -y Desired_primaries=2 \ -h phys-schost-1,phys-schost-2 |
To register the SUNW.s1as resource type, the following command is run.
# scrgadm -a -t SUNW.s1as |
To create a Sun Java System Application Server resource and add it to the resource group, the following command is run.
# scrgadm -a -j appsrv-rs -g appsrv-rg -t SUNW.s1as \ -x Confdir_list=/global/appserver/domains/scdomain/server1 \ -x Monitor_Uri_List=http://localhost:8000/servlet/monitor |
To bring online the application resource group, the following command is run.
# scswitch -Z -g appsrv-rg |