Skip Navigation Links | |
Exit Print View | |
![]() |
Oracle Solaris Cluster Data Service for Sun Java System Web Server Guide |
1. Installing and Configuring Oracle Solaris Cluster HA for Sun Java System Web Server
Planning the Installation and Configuration
Installing and Configuring a Sun Java System Web Server
How to Install a Sun Java System Web Server
How to Configure a Sun Java System Web Server
Installing the HA for Sun Java System Web Server Packages
How to Install the HA for Sun Java System Web Server Packages
Registering and Configuring Oracle Solaris Cluster HA for Sun Java System Web Server
Setting Oracle Solaris Cluster HA for Sun Java System Web Server Extension Properties
Setting IP Addresses and Port Numbers for the Sun Java System Web Server Application
How to Register and Configure HA for Sun Java System Web Server in a Scalable Configuration
Tuning the Oracle Solaris Cluster HA for Sun Java System Web Server Fault Monitor
Operations by the Fault Monitor During a Probe
Upgrading the HA for Sun Java System Web Server Resource Type
Information for Registering the New Resource Type Version
Information for Migrating Existing Instances of the Resource Type
You can configure Oracle Solaris Cluster HA for Sun Java System Web Server as a failover data service or as a scalable data service. You must include some additional steps to configure Sun Java System Web Server as a scalable data service. In the first procedure in this section, these additional steps begin with a notation that they are required for scalable services only. Individual examples of a failover service and a scalable service follow the procedure.
The sections that follow contain instructions for registering and configuring Oracle Solaris Cluster HA for Sun Java System Web Server resources. For information about the extension properties, see Appendix A, HA for Sun Java System Web Server Extension Properties. The Tunable entry indicates when you can update a property.
See Appendix A, Standard Properties, in Oracle Solaris Cluster Data Services Planning and Administration Guide for details on all the Oracle Solaris Cluster properties.
To set an extension property of a resource, include the following option in the clresource(1CL) command that creates or modifies the resource:
-p property=value
Identifies the extension property that you are setting.
Specifies the value to which you are setting the extension property.
You can also use the procedures in Chapter 2, Administering Data Service Resources, in Oracle Solaris Cluster Data Services Planning and Administration Guide to configure resources after the resources are created.
Set the Monitor_Uri_List extension property if you want the web server fault monitor to probe an arbitrary list of applications (URIs) served by the web server. This extension property provides extended probing functionality and is useful if you are layering services in addition to your web server. The Monitor_Uri_List extension property is not supported with a secure Sun Java System Web Server instance. If you do not set the Monitor_Uri_List extension property , the fault monitor will perform basic probing. See Tuning the Oracle Solaris Cluster HA for Sun Java System Web Server Fault Monitor for details. The following examples show how to set the Monitor_Uri_List extension property when you add the Sun Java System Web Server instance to your configuration.
Example 1-1 Setting Monitor_Uri_List for Scalable Sun Java System Web Server Instance
(Add an insecure Sun Java System Web Server instance with default load balancing.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_List=/opt/SUNwbsrv/https-Sun-app-insecure-1 \ -p Scalable=True -p Resource_dependencies=schost-1 \ -p Port_list=8000/tcp \ -p Monitor_Uri_list=http://schost-1:8000/servlet/monitor web-not-secure-1
Example 1-2 Setting Monitor_Uri_List for Failover Sun Java System Web Server Instance
(Add an insecure Sun Java System Web Server application resource instance.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_list=/opt/SUNwbsrv/conf -p Scalable=False \ -p Resource_dependencies=schost-1 -p Port_list=80/tcp \ -p Monitor_Uri_list=http://schost-1:80/servlet/monitor web-not-secure-1
Example 1-3 Setting Monitor_Uri_List for Failover Sun Java System Web Proxy Server Instance
(Add an insecure Sun Java System Web Proxy Server application resource instance.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_list=/opt/SUNwbproxy/conf -p Scalable=False \ -p Resource_dependencies=schost-1 -p Port_list=80/tcp \ -p Monitor_Uri_list=http://schost-1:80/servlet/monitor Sun-app-insecure-1
The Resource_dependencies setting on the Sun Java System Web Server application resource determines the set of IP addresses that Sun Java System Web Server uses. The Port_list setting on the resource determines the list of port numbers that Sun Java System Web Server uses. The fault monitor assumes that the Sun Java System Web Server daemon is listening on all combinations of IP and port. You can configure the server.xml file for the Sun Java System Web Server to listen on different port numbers (in addition to port 80). The fault monitor attempts to probe all such combinations and starts to fail if the Sun Java System Web Server is not listening on a particular IP address-port combination. If the Sun Java System Web Server does not serve all IP address-port combinations, you must break the Sun Java System Web Server into separate instances that do.
This procedure describes how to use the Oracle Solaris Cluster maintenance commands to register and configure Oracle Solaris Cluster HA for Sun Java System Web Server in a failover configuration.
Note - Other options also enable you to register and configure the data service. See Tools for Data Service Resource Administration in Oracle Solaris Cluster Data Services Planning and Administration Guide for details about these options.
To perform this procedure, you must have the following information.
The name of the resource type for Oracle Solaris Cluster HA for Sun Java System Web Server. This name is SUNW.iws.
The names of the cluster nodes that master the data service. For a failover service, only one node can master a data service at a time.
The logical hostname (for failover services) or shared address (for scalable services) that clients use to access the data service.
The path to the Sun Java System binaries. You can install the binaries on the local disks or the cluster file system. See Configuration Guidelines for Oracle Solaris Cluster Data Services in Oracle Solaris Cluster Data Services Planning and Administration Guide for a discussion of the advantages and disadvantages of each location.
Note - The Resource_dependencies setting on the Sun Java System application resource determines the set of IP addresses that Sun Java System Web Server uses. The Port_list setting on the resource determines the list of port numbers that Sun Java System Web Server uses. The fault monitor assumes that the Sun Java System Web Server daemon is listening on all combinations of IP and port. You can configure the server.xml file for the Sun Java System Web Server to listen on different port numbers (in addition to port 80). The fault monitor attempts to probe all such combinations and starts to fail if the Sun Java System Web Server is not listening on a particular IP address-port combination. If the Sun Java System Web Server does not serve all IP address-port combinations, you must break the Sun Java System Web Server into separate instances that do.
Note - Perform this procedure on any cluster member.
# clresourcetype register SUNW.iws
You can optionally select the set of nodes or zones on which the data service can run with the -n option.
# clresourcegroup create [-n node-zone-list] resource-group
Specifies the name of the failover resource group. This name can be your choice but must be unique for resource groups within the cluster.
Specifies a comma-separated, ordered list of zones that can master this resource group. The format of each entry in the list is node. In this format, node specifies the node name and zone specifies the name of a non-global Solaris zone. To specify the global zone, or to specify a node without non-global zones, specify only node.
This list is optional. If you omit this list, the global zone of each cluster node can master the resource group.
You should have performed this verification during the Oracle Solaris Cluster installation. See the planning chapter in the Solaris Cluster Software Installation Guide for Solaris OS for details.
Note - To avoid any failures because of name service lookup, ensure that all logical hostnames and shared addresses are present in the server's and client's /etc/inet/hosts file. Configure name service mapping in /etc/nsswitch.conf on the servers to first check the local files before trying to access NIS or NIS+.
# clreslogicalhostname create -g resource-group \ -h logical-hostname,… \ [-p auxnodelist=node] [-N netiflist] resource
Specifies the name of the failover resource group.
Specifies a comma-separated list of logical hostnames that this resource is to make available.
Specifies an optional comma-separated list of physical node IDs that identify cluster nodes that can host the shared address but never serve as a primary if failover occurs. These nodes are mutually exclusive with the nodes identified in nodelist for the resource group, if specified.
Specifies the name of the resource group. This name can be your choice but must be unique for resource groups within the cluster.
Specifies an optional, comma-separated list that identifies the IP Networking Multipathing groups that are on each node or zone. The format of each entry in the list is netif@node. The replaceable items in this format are as follows:
Specifies an IPMP group name, such as sc_ipmp0, or a public network interface card (NIC). If you specify a public NIC, Oracle Solaris Cluster attempts to create the required IPMP groups.
Specifies the name or ID of a node. To specify the global zone, or to specify a node without non-global zones, specify only node.
This list is optional. If you omit this list, Oracle Solaris Cluster attempts to create the required IPMP groups.
Note - If you require a fully qualified hostname, you must specify the fully qualified name with the -h option and you cannot use the fully qualified form in the resource name.
Note - Oracle Solaris Cluster does not currently support using the adapter name for netif.
Specifies the name of the resource.
You can repeat this step to add multiple application resources (such as secure and insecure versions) to the same resource group.
# clresource create -g resource-group \ -t resource-type \ -p Confdir_list=config-directory \ -p Resource_dependencies=logical-hostname-list,.. \ -p Port_list=port-number/protocol resource
Specifies the name of the failover resource group into which the resources are to be placed.
Specifies the type of the resource to add.
Specifies the location of the Sun Java System configuration files. The Confdir_list file for failover services must have exactly one entry only. The config-directory must contain a directory called config. Oracle Solaris Cluster HA for Sun Java System Web Server requires this extension property.
Specifies a comma-separated list of network resources that identify the logical hosts that the data service uses.
Specifies the port number and protocol to use, for example, 80/tcp. Port_list for failover services must have exactly one entry only because of the one-to-one mapping rule between Port_list and Confdir_list.
Specifies the name of the resource to add.
The resource is created in the enabled state.
Note - Optionally, you can set additional extension properties that belong to the Oracle Solaris Cluster HA for Sun Java System Web Server to override the default values of the properties. See Appendix A, HA for Sun Java System Web Server Extension Properties for a list of these properties.
# clresourcegroup online resource-group
Specifies the name of the failover resource group.
Example 1-4 Registering a Failover Oracle Solaris Cluster HA for Sun Java System Web Server on a Two-Node Cluster
Cluster Information Node names: phys-schost-1, phys-schost-2 Logical hostname: schost-1 Resource group: resource-group-1 (for all resources) Resources: schost-1 (logical hostname), Sun-app-insecure-1 (insecure application resource), Sun-app-secure-1 (secure application resource) (Add the resource group to contain all resources.) # clresourcegroup create resource-group-1 (Add the logical hostname resource to the resource group.) # clreslogicalhostname create -g resource-group-1 -h schost-1 (Register the resource type for the Oracle Solaris Cluster HA for Sun Java System Web Server.) # clresourcetype register SUNW.iws (Add an insecure application resource instance.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_list=/opt/SUNwbsrv/conf -p Scalable=False \ -p Resource_dependencies=schost-1 -p Port_list=80/tcp Sun-app-insecure-1 \ (Add a secure application resource instance.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_List=/opt/SUNwbsrv/https-Sun-app-secure-1 -p Scalable=False \ -p Resource_dependencies=schost-1 -p Port_list=443/tcp Sun-app-secure-1 \ (Bring the failover resource group online.) # clresourcegroup online resource-group-1
Example 1-5 Registering a Failover Oracle Solaris Cluster HA for Sun Java System Web Proxy Server on a Two-Node Cluster
Cluster Information Node names: phys-schost-1, phys-schost-2 Logical hostname: schost-1 Resource group: resource-group-1 (for all resources) Resources: schost-1 (logical hostname), Sun-app-insecure-1 (insecure application resource), Sun-app-secure-1 (secure application resource) (Add the resource group to contain all resources.) # clresourcegroup create resource-group-1 (Add the logical hostname resource to the resource group.) # clreslogicalhostname create -g resource-group-1 -h schost-1 (Register the resource type for the Oracle Solaris Cluster HA for Sun Java System Web Proxy Server.) # clresourcetype register SUNW.iws (Add an insecure application resource instance.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_list=/opt/SUNwbproxy/proxy-insecure-1 -p Scalable=False \ -p Resource_dependencies=schost-1 -p Port_list=80/tcp Sun-app-insecure-1 \ (Add a secure application resource instance.) # clresource create -g resource-group-1 -t SUNW.iws \ -p Confdir_List=/opt/SUNwbproxy/proxy-secure-1 -p Scalable=False \ -p Resource_dependencies=schost-1 -p Port_list=443/tcp Sun-app-secure-1 \ (Bring the failover resource group online.) # clresourcegroup online resource-group-1
In this example, it is assumed that the global file system is being used. If a failover file system is used, you must set the dependency on the HAStoragePlus resource using the Resource_dependencies extension property during resource creation.
# clresourcetype register SUNW.iws
You can optionally select the set of nodes or zones on which the data service can run with the -n option.
# clresourcegroup create [-n node-zone-list] resource-group
Specifies the name of the failover resource group. This name can be your choice but must be unique for resource groups within the cluster.
Specifies a comma-separated, ordered list of zones that can master this resource group. The format of each entry in the list is node. In this format, node specifies the node name and zone specifies the name of a non-global Solaris zone. To specify the global zone, or to specify a node without non-global zones, specify only node.
This list is optional. If you omit this list, the global zone of each cluster node can master the resource group.
You should have performed this verification during the Oracle Solaris Cluster installation. See the planning chapter in the Solaris Cluster Software Installation Guide for Solaris OS for details.
Note - To avoid any failures because of name service lookup, ensure that all logical hostnames and shared addresses are present in the server's and client's /etc/inet/hosts file. Configure name service mapping in /etc/nsswitch.conf on the servers to first check the local files before trying to access NIS or NIS+.
# clressharedaddress create -g resource-group \ -h shared-address,… \ [-p auxnodelist=node] [-N netiflist] resource
Specifies the name of the failover resource group.
Specifies a comma-separated list of shared addresses that this resource is to make available.
Specifies an optional comma-separated list of physical node IDs that identify cluster nodes that can host the shared address but never serve as a primary if failover occurs. These nodes are mutually exclusive with the nodes identified in nodelist for the resource group, if specified.
Specifies the name of the resource group. This name can be your choice but must be unique for resource groups within the cluster.
Specifies an optional, comma-separated list that identifies the IP Networking Multipathing groups that are on each node or zone. The format of each entry in the list is netif@node. The replaceable items in this format are as follows:
Specifies an IPMP group name, such as sc_ipmp0, or a public network interface card (NIC). If you specify a public NIC, Oracle Solaris Cluster attempts to create the required IPMP groups.
Specifies the name or ID of a node. To specify the global zone, or to specify a node without non-global zones, specify only node.
This list is optional. If you omit this list, Oracle Solaris Cluster attempts to create the required IPMP groups.
Note - Oracle Solaris Cluster does not currently support using the adapter name for netif.
Specifies the name of the resource.
Create a resource group to hold a data service application resource. You must specify the maximum and desired number of primary nodes as well as a dependency between this resource group and the failover resource group that you created in Step 3. This dependency ensures that in the event of failover, the resource manager starts the network resource before starting any data services that depend on the network resource.
# clresourcegroup create \ -p Maximum_primaries=m -p Desired_primaries=n \ -p RG_dependencies=resource-group scalable-resource-group
Specifies the maximum number of active primary nodes allowed for this resource group. If you do not assign a value to this property, the default is 1.
Specifies the desired number of active primary nodes allowed for this resource group. If you do not assign a value to this property, the default is 1.
Identifies the resource group that contains the shared address resource on which the resource group being created depends.
Specifies the scalable resource group.
You can repeat this step to add multiple application resources, such as secure and insecure versions, to the same resource group.
To set load balancing for the data service, use the two standard resource properties Load_balancing_policy and Load_balancing_weights. See Appendix A, Standard Properties, in Oracle Solaris Cluster Data Services Planning and Administration Guide for a description of these properties. Additionally, see the examples that follow this section.
# clresource create -g scalable-resource-group \ -t resource-type -p Confdir_list=config-directory,… \ -p Resource_dependencies=shared-address,… \ -p Port_list=port-number/protocol,… \ -p Scalable=True resource
Specifies the name of the scalable resource group into which the resources are to be placed.
Specifies the type of the resource to add.
Specifies a comma-separated list of the locations of the Sun Java System configuration files. Oracle Solaris Cluster HA for Sun Java System Web Server requires this extension property.
Specifies a comma-separated list of network resources that identify the shared addresses that the data service uses.
Specifies a comma-separated list of port numbers and protocol to be used, for example, 80/tcp,81/tcp.
Specifies a Boolean that is required for scalable services.
Specifies the name of the resource to add.
The resource is created in the enabled state.
Note - A one-to-one mapping applies for Confdir_List and Port_List. Each value in one list must correspond to the value in the other list in the specified order.
# clresourcegroup online resource-group
Specifies the name of the failover resource group.
# clresourcegroup online resource-group
Specifies the name of the scalable resource group.
Example 1-6 Registering a Scalable Oracle Solaris Cluster HA for Sun Java System Web Server
Cluster Information Node names: phys-schost-1, phys-schost-2 Shared address: schost-1 Resource groups: sa-resource-group-1 (for shared addresses), iws-resource-group-1 (for scalable application resources) Resources: schost-1 (shared address), Sun-app-insecure-1 (insecure application resource), Sun-app-secure-1 (secure application resource) (Add a failover resource group to contain shared addresses.) # clresourcegroup create sa-resource-group-1 (Add the shared address resource to the failover resource group.) # clressharedaddress create -g sa-resource-group-1 -h schost-1 sa-resource (Add a scalable resource group.) # clresourcegroup create -p Maximum_primaries=2 \ -p Desired_primaries=2 \ -p RG_dependencies=sa-resource-group-1 iws-resource-group-1 (Register the resource type for the Oracle Solaris Cluster HA for Sun Java System Web Server.) # clresourcetype register SUNW.iws (Add an insecure application instance with default load balancing.) # clresource create -g iws-resource-group-1 -t SUNW.iws \ -p Confdir_List=/opt/SUNwbsrv/https-Sun-app-insecure-1 \ -p Scalable=True -p Resource_dependencies=schost-1 \ -p Port_list=80/tcp Sun-app-insecure-1 (Add a secure application instance with sticky IP load balancing.) # clresource create -g iws-resource-group-1 -t SUNW.iws \ -p Confdir_List=/opt/SUNwbsrv/https-Sun-app-secure-1 \ -p Scalable=True -p Resource_dependencies=schost-1 \ -p Port_list=443/tcp -p Load_balancing_policy=LB_STICKY \ -p Load_balancing_weights=40@1,60@2 Sun-app-secure-1 (Bring the failover resource group online.) # clresourcegroup online sa-resource-group-1 (Bring the scalable resource group online.) # clresourcegroup online iws-resource-group-1
The SUNW.HAStoragePlus resource type was introduced in Sun Cluster 3.0 5/02. This new resource type performs the same functions as SUNW.HAStorage, and synchronizes actions between HA storage and the data service.
SUNW.HAStoragePlus also has an additional feature to make a local file system highly available.
See the SUNW.HAStoragePlus(5) man page and Relationship Between Resource Groups and Device Groups in Oracle Solaris Cluster Data Services Planning and Administration Guide for background information. See Synchronizing the Startups Between Resource Groups and Device Groups in Oracle Solaris Cluster Data Services Planning and Administration Guide for the procedure. (If you are using a Sun Cluster 3.0 version prior to 5/02, you must set up SUNW.HAStorage instead of SUNW.HAStoragePlus. See Synchronizing the Startups Between Resource Groups and Device Groups in Oracle Solaris Cluster Data Services Planning and Administration Guide for New Resources for the procedure.)