3 Managing Configurations

The first step toward creating a load-balanced service with Oracle Traffic Director is to create a configuration, which is a collection of metadata defining the run-time characteristics of an Oracle Traffic Director server. After creating a configuration, you can use it to create instances of Oracle Traffic Director servers on one or more administration nodes.

Note:

For the definitions of the Oracle Traffic Director terminology—configuration, administration node, and instance, see Section 1.4, "Oracle Traffic Director Terminology." For information about the relationship between configurations, administration nodes, and instances, see Chapter 1, "Getting Started with Oracle Traffic Director."

This chapter contains the following topics:

3.1 Creating a Configuration

You can create configurations by using either Fusion Middleware Control or the WLST.

Note:

For information about using WLST, see Section 1.7.1, "Accessing WebLogic Scripting Tool."


Before You Begin

Before you begin creating a configuration, decide the following:

  • A unique name for the configuration. Choose the name carefully; after creating a configuration, you cannot change its name.

    Note:

    The server user that you specify for a configuration must meet the following requirements:
    • When the administration server is running as root, the server user of a configuration must either be root or belong to the same group as the user that installed Oracle Traffic Director.

    • When the administration server is running as a non-root user, the server user of a configuration must be the same as the administration server's server user.

    Note that the nodes to which a configuration is deployed must be homogenous in terms of the user accounts and groups configured on those systems.

  • A unique listener host:port combination for the default virtual server that you will create as part of the configuration.

  • host:port addresses of the servers in the origin-server pool that you will create as part of the configuration.

  • (optional) Host names of the administration nodes on which you want to create instances of the configuration.

    Note:

    While creating a configuration by using the New Configuration wizard, you can choose to also instantiate the configuration on one or more administration nodes. The wizard enables you to do this by displaying the host names of the administration nodes that are registered with the administration server.

Creating a Configuration Using Fusion Middleware Control

To create a configuration by using Fusion Middleware Control, do the following tasks:

  1. Log in to Fusion Middleware Control for Traffic Director, as described in Section 1.7.2, "Displaying Fusion Middleware Control."

  2. Click the WebLogic Domain button at the upper left corner of the page.

  3. Select Administration > OTD Configurations.

  4. In the Common Tasks pane select the Create button.

    The New Configuration wizard opens.

    Figure 3-1 New Configuration Wizard

    Description of Figure 3-1 follows
    Description of ''Figure 3-1 New Configuration Wizard''

  5. Follow the on-screen prompts to complete creation of the configuration by using the details—origin server type, and so on—that you decided earlier.

    After the configuration is created, the Results screen of the New Configuration wizard displays a message confirming successful creation of the configuration. If you chose to create instances of the configuration, then a message confirming successful creation of the instances is also displayed.

  6. Click Close on the Results screen.

    In the New Configuration wizard, if you chose not to create an instance of the configuration, the message Undeployed Configuration is displayed, indicating that the configuration that you just created is yet to be deployed.

Creating a Configuration Using WLST

To create a configuration, run the otd_createConfiguration command.

For example, the following command creates a configuration named soa.example.com with an origin server, vault.example.com:80.

# Online
props = {}
props['name'] = 'soa.example.com'
props['listener-port'] = '12345'
props['server-name'] = 'foo'
props['origin-server'] = 'vault.example.com:80'
otd_createConfiguration(props)
# Offline
readDomain('/export/2110_12c/iplanet/ias/server/work/TD_Linux2.6_DBG.OBJ/domains/otd_domain')
props = {}
props['configuration'] = 'foo'
props['listener-port'] = '12345'
props['server-name'] = 'foo'
props['origin-server'] = 'www.mycompany.com:80'
otd_createConfiguration(props)
updateDomain()
closeDomain()

For more information about otd_createConfiguration, see the WebLogic Scripting Tool Command Reference for Oracle Traffic Director or run the command with the --help option.

For more information on the offline mode, see Offline Commands in the WebLogic Scripting Tool Command Reference for Oracle Traffic Director.

3.2 Viewing a List of Configurations

At any time, you can view a list of the available configurations by using either Fusion Middleware Control or the WLST.

Note:

For information about invoking WLST, see Section 1.7.1, "Accessing WebLogic Scripting Tool."

Viewing a List of Configurations Using Fusion Middleware Control

To view a list of the available configurations:

  1. Log in to Fusion Middleware Control, as described in Section 1.7.2, "Displaying Fusion Middleware Control."

  2. Click the WebLogic Domain button at the upper left corner of the page.

  3. Select Administration > OTD Configurations.

    A list of the available configurations is displayed, as shown in Figure 3-2.

Figure 3-2 List of Configurations

Description of Figure 3-2 follows
Description of ''Figure 3-2 List of Configurations''

You can view the properties of a configuration by clicking on its name.

Viewing a List of Configurations Using WLST

To view a list of the available configurations, run the otd_listConfigurations command, as shown in the following example:

# Online
otd_listConfigurations()

# Offline
readDomain('/export/2110_12c/iplanet/ias/server/work/TD_Linux2.6_DBG.OBJ/domains/otd_domain')
otd_listConfigurations()
closeDomain() 

For more information on the offline mode, see Offline Commands in the WebLogic Scripting Tool Command Reference for Oracle Traffic Director.

3.3 Activate Configuration Changes

You can activate the configuration changes by using either Fusion Middleware Control or the WLST.

Note:

Certain configuration changes cannot be applied dynamically without restarting the instances.

You can activate the configuration changes to the instances. The activate command will activate only the changes done after starting an edit session by executing the command startEdit. Also, the effect of this command is not just limited to OTD. All the changes done after starting an edit session to the various other components and managed servers will also be activated.

Activate a Configuration Using Fusion Middleware Control

  1. Log in to Fusion Middleware Control for Traffic Director, as described in Section 1.7.2, "Displaying Fusion Middleware Control."

  2. Click the unlock button just below Weblogic Domain at the upper left corner of the page.

  3. In default Auto-Commit Mode is enabled.

    • Enable

      • Enable Auto-Commit Mode and create a configuration. It displays a information that all changes have been activated.

    • Disable

      • Disable Auto-Commit Mode and create a configuration. It displays a information that changes are pending for activation. Use change center to activate pending changes.

Activate Configuration changes Using WLST

All the commands executed by the WLST should be activated through the Activate command to activate changes.

For example, the following command updates all instances of the configuration with the latest configuration settings.

wls:/mydomain/edit !> activate(200000, block='true')
Activating all your changes, this may take a while ...
The edit lock associated with this edit session is released once the activation iscompleted.
Action completed.
wls:/mydomain/edit>

For more information about activate, see the WebLogic Scripting Tool Command Reference for Oracle Traffic Director.

Note:

For some parameters, you can reconfigure an instance without
restarting it. For more information, see Section 4.4, "Updating Oracle Traffic Director Instances Without Restarting."

3.4 Modifying a Configuration

After you create a configuration and create instances from it, you might need to change some of the settings—log preferences, performance parameters, virtual server listener, origin-server pools, and so on.

You can modify a configuration by using either Fusion Middleware Control or the WLST.

Note:

For information about invoking WLST, see Section 1.7.1, "Accessing WebLogic Scripting Tool."

Modifying a Configuration Using Fusion Middleware Control

To modify a configuration by using the Fusion Middleware Control, do the following:

  1. Log in to Fusion Middleware Control for Traffic Director, as described in Section 1.7.2, "Displaying Fusion Middleware Control."

  2. Click the WebLogic Domain button at the upper left corner of the page.

  3. Select Administration > OTD Configurations.

    A list of the available configurations is displayed.

  4. Select the configuration that you want to modify.

  5. In the navigation pane, you can select the following additional categories of settings for the configuration. The parameters relevant to the selected category are displayed on the main pane.

    Note:

    For information about modifying origin servers, origin-server pools, listeners, and virtual servers, see:
  6. Specify the parameters that you want to change.

    On-screen help and prompts are provided for all of the parameters.

    When you change the value in a field or tab out of a text field that you changed, the Save button near the upper right corner of the page is enabled.

    At any time, you can discard the changes by clicking the Reset button.

  7. After making the required changes, click Save.

    • A message, confirming that the updated configuration was saved, is displayed in the Console Messages pane.

    • In addition, the Deployment Pending message is displayed at the top of the main pane. You can either deploy the updated configuration immediately by clicking Deploy Changes, or you can do so later after making further changes as described in Section 3.3, "Activate Configuration Changes."

    Caution:

    In the Advanced Settings page, if you change the Temporary Directory value, you should first stop all the instances of the configuration, deploy the changes, and then start the instances.

    If you deploy the changes without stopping the running instances, an error would occur when you attempt to stop the instances later. For information about solving this problem, see Section 16.2.5, "Unable to stop instance after changing the temporary directory."

Modifying a Configuration Using WLST

WLST provides several commands (see Table 3-1) that you can use to change specific parameters of a configuration.

Note:

For information about the WLST commands to change the properties of virtual servers, listeners, origin server pools, and origin servers in a configuration, see the following chapters:

Table 3-1 WLST Commands for Modifying a Configuration

Task WLST Commands

Change the configuration properties

otd_setConfigurationProperties

Change access-log buffer properties

otd_setAccessLogBufferProperties

otd_getAccessLogBufferProperties

Change caching properties

otd_setCacheProperties

otd_getCacheProperties

Change DNS properties

otd_setDnsProperties

otd_getDnsProperties

Change DNS caching properties

otd_setDnsCacheProperties

otd_getDnsCacheProperties

Change HTTP request properties

otd_setHttpProperties

otd_getHttpProperties

Change keep-alive settings for client connections

otd_setKeepAliveProperties

otd_getKeepAliveProperties

Change error log settings

otd_setLogProperties

otd_getLogProperties

Enable SNMP

otd_setSnmpProperties

otd_getSnmpProperties

Change SSL/TLS session caching properties

otd_setSslSessionCacheProperties

otd_getSslSessionCacheProperties

Change statistics collection properties

otd_setStatsProperties

otd_getStatsProperties

Change HTTP thread pool properties

otd_setHttpThreadPoolProperties

otd_getHttpThreadPoolProperties

Change TCP thread pool properties

otd_setTcpThreadPoolProperties

otd_getTcpThreadPoolProperties


For example, the following command changes the log level for the configuration foo to the most verbose (finest) setting, TRACE:32.

props = {}
props['configuration'] = 'foo'
otd_getConfigurationProperties(props)

For more information about the WLST commands mentioned in this section, see the WebLogic Scripting Tool Command Reference for Oracle Traffic Director or run the commands with the --help option.

3.5 Copying a Configuration

When you want to create a configuration that is similar to an existing configuration, you can copy the existing configuration and make the required changes later.

You can copy a configuration by using either Fusion Middleware Control or the WLST.

Note:

For information about invoking WLST, see Section 1.7.1, "Accessing WebLogic Scripting Tool."

Copying a Configuration Using Fusion Middleware Control

To copy a configuration by using the Fusion Middleware Control, do the following:

  1. Log in to Fusion Middleware Control for Traffic Director, as described in Section 1.7.2, "Displaying Fusion Middleware Control."

  2. Click the WebLogic Domain button at the upper left corner of the page.

  3. Select Administration > OTD Configurations.

    A list of the available configurations is displayed.

  4. Select the configuration that you want to copy.

  5. In the Common Tasks pane, click Duplicate Configuration.

  6. In the resulting dialog box, enter a name for the new configuration, and then click OK

    A message is displayed confirming that the configuration was copied.

  7. Click OK.

Copying a Configuration Using WLST

To copy a configuration, run the otd_copyConfiguration command.

For example, the following command copies the configuration foo to a new configuration named foo1.

props = {}
props['source-configuration'] = 'foo'
props['dest-configuration'] = 'bar'
otd_copyConfiguration(props)

For more information about otd_copyConfiguration, see the WebLogic Scripting Tool Command Reference for Oracle Traffic Director.

3.6 Deleting a Configuration

You can delete a configuration by using either Fusion Middleware Control or the WLST.

Note:

Deleting a Configuration Using Fusion Middleware Control

To delete a configuration by using the Fusion Middleware Control, do the following:

  1. Log in to Fusion Middleware Control, as described in Section 1.7.2, "Displaying Fusion Middleware Control."

  2. Click the WebLogic Domain button at the upper left corner of the page.

  3. Select Administration > OTD Configurations.

    A list of the available configurations is displayed.

  4. Select the configuration that you want to delete.

  5. In the Common Tasks pane, click Delete Configuration.

    • If there are no instances of the configuration that you want to delete, a prompt to confirm deletion of the configuration is displayed.

      1. Click OK.

        A message is displayed confirming that the configuration was deleted.

      2. Click OK.

    • If there are instances of the configuration that you want to delete, a dialog box is displayed listing the administration nodes on which the configuration is deployed. The list also indicates whether the instances are running.

      1. If you want to proceed with the deletion, you can choose to save the log files of the instances by selecting the Save Instance Logs check box.

        To confirm deletion, click OK.

        A message is displayed confirming that the configuration and its instances were deleted.

      2. Click OK.

      Note:

      If you selected the Save Instance Logs check box, the server access and error logs for the instances that were deleted are retained in the INSTANCE_HOME/net-config_name/logs directory.
  6. Click the Delete button corresponding to the configuration that you want to delete.

Deleting a Configuration Using WLST

Note:

You cannot delete a configuration by using WLST if instances of the configuration are deployed to administration nodes, regardless of whether the instances are running or stopped.

To delete such a configuration by using WLST, you must first delete all of its instances.

To delete a configuration, run the otd_deleteConfiguration command, as shown in the following example:

# Online
props = {}
props['configuration'] = 'foo'
otd_deleteConfiguration(props)
# Offline
readDomain('/export/2110_12c/iplanet/ias/server/work/TD_Linux2.6_DBG.OBJ/domains/otd_domain')
props = {}
props['configuration'] = 'foo'
otd_deleteConfiguration(props)
updateDomain()
closeDomain()

For more information about otd_deleteConfiguration, see the WebLogic Scripting Tool Command Reference for Oracle Traffic Director

For more information on the offline mode, see Offline Commands in the WebLogic Scripting Tool Command Reference for Oracle Traffic Director.