JavaScript is required to for searching.
Skip Navigation Links
Exit Print View
Oracle GlassFish Server 3.1-3.1.1 High Availability Administration Guide
search filter icon
search icon

Document Information

Preface

1.  High Availability in GlassFish Server

2.  Setting Up SSH for Centralized Administration

3.  Administering GlassFish Server Nodes

4.  Administering GlassFish Server Clusters

5.  Administering GlassFish Server Instances

6.  Administering Named Configurations

About Named Configurations

Types of Named Configurations

The default-config Configuration

Automatically Created Configurations

Directory for Configuration Synchronization

Creating, Listing, and Deleting Named Configurations

To Create a Named Configuration

To List the Named Configurations in a Domain

To List the Targets of a Named Configuration

To Delete a Named Configuration

Modifying Properties for Named Configurations and Instances

Properties for Port Numbers in a Named Configuration

To Modify a Named Configuration's Properties

To Modify Port Numbers of an Instance

7.  Configuring Web Servers for HTTP Load Balancing

8.  Configuring HTTP Load Balancing

9.  Upgrading Applications Without Loss of Availability

10.  Configuring High Availability Session Persistence and Failover

11.  Configuring Java Message Service High Availability

12.  RMI-IIOP Load Balancing and Failover

Index

Creating, Listing, and Deleting Named Configurations

GlassFish Server enables you to create configurations for use by clusters and instances, obtain information about configurations, and delete configurations that are no longer required.

The following topics are addressed here:

To Create a Named Configuration

Use the copy-config subcommand in remote mode to create a named configuration by copying an existing configuration.

GlassFish Server requires you to create a configuration by copying a configuration because a configuration contains many required settings. The newly created configuration is identical to the configuration that you copy until you change its configuration settings.


Tip - Create a named configuration only if you plan to share the configuration among multiple unclustered instances or clusters, or if you are using a configuration to preconfigure GMS settings. Otherwise, create clusters and instances without specifying an existing configuration. If no configuration is specified, GlassFish Server creates a copy of the default configuration for the cluster or instance.

For more information, see the following sections:


  1. Ensure that the DAS is running.

    Remote subcommands require a running server.

  2. Run the copy-config subcommand.

    Note - Only the options that are required to complete this task are provided in this step. For information about all the options for configuring the named configuration, see the copy-config(1) help page.


    asadmin> copy-config source-config-name destination-config-name
    source-config-name

    The name of the configuration that you are copying. You must specify a configuration to copy even if you are copying the default configuration. The configuration must already exist.

    destination-config-name

    Your choice of name for the configuration that you are creating by copying the source configuration.

Example 6-1 Creating a Named Configuration

This example creates the named configuration clusterpresets-config by copying the default configuration.

asadmin> copy-config default-config clusterpresets-config
Command copy-config executed successfully.

See Also

You can also view the full syntax and options of the subcommand by typing asadmin help copy-config at the command line.

To List the Named Configurations in a Domain

Use the list-configs subcommand in remote mode to list existing named configurations in a domain.

  1. Ensure that the DAS is running.

    Remote subcommands require a running server.

  2. Run the list-configs(1) subcommand.
    asadmin> list-configs

Example 6-2 Listing All Named Configurations in a Domain

This example lists all named configurations in the current domain.

asadmin> list-configs
server-config
default-config
ymlcluster-config
clusterpresets-config
Command list-configs executed successfully.

See Also

list-configs(1)

You can also view the full syntax and options of the subcommand by typing asadmin help list-configs at the command line.

To List the Targets of a Named Configuration

Use the list-clusters subcommand and the list-instances subcommand in remote mode to list the targets of a named configuration.

The targets of a named configuration are the clusters and GlassFish Server instances that reference the configuration.

  1. Ensure that the DAS is running.

    Remote subcommands require a running server.

  2. List the clusters that refer to the configuration.
    asadmin> list-clusters config-name
    config-name

    The name of the configuration whose targets you are listing.

  3. List the instances that refer to the configuration.
    asadmin> list-instances config-name
    config-name

    The name of the configuration whose targets you are listing.

Example 6-3 Listing the Targets of a Named Configuration

This example shows that the cluster ymlcluster and the instances yml-i1 and yml-i2 reference the named configuration ymlcluster-config.

asadmin> list-clusters ymlcluster-config
ymlcluster partially running
Command list-clusters executed successfully.
asadmin> list-instances ymlcluster-config
yml-i1   running      
yml-i2   not running  
Command list-instances executed successfully.

See Also

You can also view the full syntax and options of the subcommands by typing the following commands at the command line:

To Delete a Named Configuration

Use the delete-config subcommand in remote mode to delete an existing named configuration from the configuration of the DAS.

You cannot delete the default-config configuration.


Note - A standalone configuration that was created automatically for a cluster or a GlassFish Server instance is deleted when the cluster or instance is deleted.


Before You Begin

Ensure that no clusters or instances refer to the configuration. If a cluster or instance refers to the configuration and is no longer required, delete the cluster or instance. For information about how to delete an instance and how to delete a cluster, see the following sections:

  1. Ensure that the DAS is running.

    Remote subcommands require a running server.

  2. Confirm that no clusters refer to the configuration that you are deleting.
    asadmin> list-clusters config-name
    config-name

    The name of the configuration that you are deleting.

  3. Confirm that no instances refer to the configuration that you are deleting.
    asadmin> list-instances config-name
    config-name

    The name of the configuration that you are deleting.

  4. Run the delete-config(1) subcommand.
    asadmin> delete-config config-name
    config-name

    The name of the configuration that you are deleting.

Example 6-4 Deleting a Named Configuration

This example confirms that no clusters or instances refer to the configuration clusterpresets-config and then deletes the configuration.

asadmin> list-clusters clusterpresets-config
Nothing to list
Command list-clusters executed successfully.
asadmin> list-instances clusterpresets-config
Nothing to list.
Command list-instances executed successfully.
asadmin> delete-config clusterpresets-config
Command delete-config executed successfully.

See Also

You can also view the full syntax and options of the subcommands by typing the following commands at the command line: