Go to main content

Oracle® Solaris Cluster 4.3 Data Services Planning and Administration Guide

Exit Print View

Updated: April 2016
 
 

How to Add a Scalable Application Resource to a Resource Group

A scalable application resource is an application resource that uses the network load balancing features of Oracle Solaris Cluster software. The scalable application resource is in a multi-mastered resource group and has a dependency on one or more shared-address resources. The shared-address resources are in a failover resource group.


Note -  Perform this procedure from any cluster node.

Before You Begin

Ensure that you have the following information.

  • The name of the scalable resource group to which you are adding the resource

  • The name of the resource type for the resource

  • The shared address resources that the scalable service resource uses, which are the shared addresses that you previously included in a failover resource group


Note -  This procedure also applies to proxy resources.
  1. On a cluster member, assume the root role that provides solaris.cluster.modify RBAC authorization.
  2. Add a scalable application resource to the resource group.
    # clresource create -S -g resource-group -t resource-type \
    -p Resource_dependencies=network-resource[,network-resource...] \
    -p Scalable=True
    [-p "extension-property[{node-specifier}]"=value,…] [-p standard-property=value,…] resource
    –S

    Specifies that the resource group is to be multi-mastered. If the –p Maximum_primaries and –p Desired_primaries options are omitted, both properties are set to the number of nodes in the resource group's node list.

    –g resource-group

    Specifies the name of a scalable service resource group that you previously created.

    –t resource-type

    Specifies the name of the resource type for this resource.

    –p Resource_dependencies=network-resource[,network-resource…]

    Specifies the list of network resources (shared addresses) on which this resource depends.

    –p Scalable=True

    Specifies that this resource uses the network load balancing feature of Oracle Solaris Cluster software.

    –p "extension-property[{node-specifier}]"=value,…

    Specifies a comma-separated list of extension properties that you are setting for the resource. The extension properties that you can set depend on the resource type. To determine which extension properties to set, see the documentation for the resource type.

    The node-specifier is an optional qualifier to the –p and –x options. This qualifier indicates that the extension property or properties on only the specified node or nodes are to be set when the resource is created. The specified extension properties on other nodes in the cluster are not set. If you do not include node-specifier, the specified extension properties on all nodes in the cluster are set. You can specify a node name or a node identifier for node-specifier. Examples of the syntax of node-specifier include the following:

    -p "myprop{phys-schost-1}"

    The braces ({ }) indicate that you are setting the specified extension property on only node phys-schost-1. For most shells, the double quotation marks (“) are required.

    –p standard-property=value,…

    Specifies a comma-separated list of standard properties that you are setting for the resource. The standard properties that you can set depend on the resource type. For scalable services, you typically set the Port_list, Load_balancing_weights, and Load_balancing_policy properties. To determine which standard properties to set, see the following man pages: cluster(1CL), rt_properties(5), rg_properties(5), r_properties(5), and property_attributes(5).

    resource

    Specifies your choice of the name of the resource to add.

    The resource is created in the enabled state.

  3. Verify that the scalable application resource has been added and validated.
    # clresource show resource
Example 12  Adding a Scalable Application Resource to a Resource Group

This example shows the addition of a resource (resource-1) to a resource group (resource-group-1). Note that resource-group-1 depends on the failover resource group that contains the network addresses that are in use (schost-1 and schost-2 in the following example). The resource depends on shared address resources (schost-1, schost-2), which must reside in one or more failover resource groups that you defined previously.

# clresource create -S -g resource-group-1 -t resource-type-1 \
-p Resource_dependencies=schost-1,schost-2 resource-1 \
-p Scalable=True
# clresource show resource-1

=== Resources ===

Resource:                                        resource-1
Type:                                            resource-type-1
Type_version:
Group:                                           resource-group-1
R_description:
Resource_project_name:                           default
Enabled{phys-schost-1}:                          False
Enabled{phys-schost-2}:                          False
Monitored{phys-schost-1}:                        True
Monitored{phys-schost-2}:                        True

Next Steps

After you add a scalable application resource, follow the procedure How to Bring Resource Groups Online to enable the resource.

Troubleshooting

Adding a resource causes the Oracle Solaris Cluster software to validate the resource. If the validation fails, the clresource command prints an error message and exits. To determine why the validation failed, check the syslog on each node for an error message. The message appears on the node that performed the validation, not necessarily the node on which you ran the clresource command.

See Also

The clresource(1CL) man page.