Note:
For the definitions of the Oracle Traffic Director terminology—configuration, administration node, and instance, see Oracle Traffic Director Terminology. For information about the relationship between configurations, administration nodes, and instances, see Figure 1-2 in Getting Started with Oracle Traffic Director.
This chapter contains the following topics:
You can create configurations by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Oracle Java Cloud Service creates the initial configuration when you create an Oracle Java Cloud Service instance with a load balancer or add a load balancer to an Oracle Java Cloud Service instance. You need to create a configuration only if you require additional configurations.
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.
The user ID with which the Oracle Traffic Director instances of the configuration should run.
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 the Administration Console
To create a configuration by using the administration console, do the following tasks:
To create a configuration, run the create-config
command.
For example, the following command creates a configuration named soa.example.com
with the virtual server and port soa-app.example.com:1905
and two origin servers, soa-1.example.com:80
and soa-2.example.com:80
.
tadm> create-config --listener-port=1905 --server-name=soa-app.example.com
--origin-server=soa-1.example.com:80,soa-2.example.com:80 soa.example.com
For more information about create-config
, see the Oracle Traffic Director Command-Line Reference or run the command with the --help
option.
At any time, you can view a list of the available configurations by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Viewing a List of Configurations Using the Administration Console
To view a list of the available configurations by using the administration console, do the following:
You can view the properties of a configuration by clicking on its name.
To view a list of the available configurations, run the list-configs
command, as shown in the following example:
tadm> list-configs --verbose --all
config-name deployment-status
---------------------------------
soa deploy-pending
adm undeployed
dev deployed
org instance-modified
A configuration can be in one of the following statuses:
Deployed: One or more instances of the configuration exist. All of the instances have the updated configuration settings.
Deployment pending: One or more instances of the configuration exist. But the instances do not have the latest configuration settings.
Undeployed: No instances exist for the configuration.
Instance modified: The settings of one or more instances of the configuration have been manually modified.
You deploy a configuration to either create an instance of it on an administration node or update a previously created instance with new configuration settings. When you deploy a configuration, the running instances are reconfigured to reflect the configuration changes.
Note:
Certain configuration changes cannot be applied dynamically without restarting the instances. For the configuration changes that require instances to be restarted, the administration interfaces—CLI and administration console—display a prompt to restart the instances.
You can deploy a configuration by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Deploying a Configuration Using the Administration Console
To deploy a configuration by using the administration console, do the following:
Log in to the administration console, as described in Accessing the Administration Console.
Click the Configurations button that is situated at the upper left corner of the page.
A list of the available configurations is displayed.
Select the configuration that you want to deploy.
If there is no instance yet of the configuration that you selected to deploy, the message Undeployed Configuration is displayed at the top of the main pane. For the procedure to create one or more instances of an undeployed configuration, see Creating Oracle Traffic Director Instances.
If instances of the configuration exist, but do not have the latest configuration settings, the message Deployment Pending is displayed at the top of the main pane. To update the instances with the latest configuration settings, do the following:
Click Deploy Changes.
A prompt to confirm deployment is displayed.
Click Deploy.
A message is displayed confirming that the updated configuration was successfully deployed.
Click Close.
Deploying a Configuration Using the CLI
To deploy a configuration, run the deploy-config
command.
For example, the following command updates all instances of the configuration soa.example.com
with the latest configuration settings.
tadm> deploy-config soa.example.com
OTD-70201 Command 'deploy-config' ran successfully.
For more information about deploy-config
, see the Oracle Traffic Director Command-Line Reference or run the command with the --help
option.
After deploying an updated configuration, for the changes to take effect, you should restart the instance.
Note:
For some parameters, you can reconfigure an instance without restarting it. For more information, see Updating Oracle Traffic Director Instances Without Restarting.
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 the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Modifying a Configuration Using the Administration Console
To modify a configuration by using the administration console, do the following:
The CLI provides several commands (see Table 4-1) that you can use to change specific parameters of a configuration.
Note:
For information about the CLI commands to change the properties of virtual servers, listeners, origin server pools, and origin servers in a configuration, see the following chapters:
Table 4-1 CLI Commands for Modifying a Configuration
Task | CLI Commands |
---|---|
Change the server user and temporary directory |
|
Change access-log buffer properties |
|
Change caching properties |
|
Change DNS properties |
|
Change DNS caching properties |
|
Change HTTP request properties |
|
Change keep-alive settings for client connections |
|
Change the default language |
|
Change error log settings |
|
Change PKCS #11 encryption settings |
|
Change QoS settings |
|
Enable SNMP |
|
Change SSL/TLS session caching properties |
|
Change statistics collection properties |
|
Change TCP thread pool properties |
|
Change HTTP thread pool properties |
|
For example, the following command changes the location of the error log file for the configuration soa
to /home/log/errors.log
.
tadm> set-log-prop --config=soa log-file=/home/log/errors.log
OTD-70201 Command 'set-log-prop' ran successfully.
For the updated configuration to take effect, you should deploy it to the Oracle Traffic Director instances by using the deploy-config
command.
For more information about the CLI commands mentioned in this section, see the Oracle Traffic Director Command-Line Reference or run the commands with the --help
option.
When you create a configuration, the configuration files—server.xml
and vs_name
-obj.conf
—are created in the configuration store on the administration server.
When you create instances of the configuration, the configuration files are copied from the configuration store to the instance-specific configuration directories on the nodes, as in the following examples:
INSTANCE_HOME/net-soa.example.com/config INSTANCE_HOME/net-dev.example.com/config
So the configuration files in the instance-specific configuration directories are usually identical to the configuration files stored in the configuration store on the administration server. In the following situations, a configuration stored on the administration server can be different from that of its instances.
You modified a configuration on the administration server, by using the administration console or CLI, but have not yet deployed the modified configuration to its instances.
You can rectify this out-of-sync situation by deploying the configuration as described in Deploying a Configuration.
You changed the configuration of an instance manually, by editing a configuration file directly in the instance's config
directory.
If you change the configuration of an instance manually by editing a configuration file—server.xml
or vs_name
-obj.conf
in the INSTANCE_HOME/net-
config_name
/config
directory, the next time you log in to the administration console and view the configuration, the alert Instance Configuration Modified is displayed. The alert indicates that the configuration stored on the administration server is different from the current configuration settings of one or more instances. The alert continues to be displayed till you synchronize the configuration stored on the administration server with that of all its instances, by doing one of the following:
Pull the modified configuration from one of the modified instances back into the configuration store of the administration server.
Discard the instance-specific configurations by redeploying the configuration from the administration server to the modified instances.
You can synchronize a configuration on the administration server with its instances by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Synchronizing Configurations on the Administration Server and Administration Nodes Using the Administration Console
To synchronize a configuration stored on the administration server with that of its instances by using the administration console, do the following:
To discard the instance-specific configurations and deploy the configuration that is currently stored on the administration server to all the instances, run the following command:
tadm> deploy-config -- force config_name
To pull configuration files from an instance to the configuration store on the administration server, run the following commands:
tadm> pull-config --config=config_name node tadm> deploy-config config_name
For more information about the CLI commands mentioned in this section, see the Oracle Traffic Director Command-Line Reference or run the commands with the --help
option.
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 the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Copying a Configuration Using the Administration Console
To copy a configuration by using the administration console, do the following:
To copy a configuration, run the copy-config
command.
For example, the following command copies the configuration soa.example.com
to a new configuration named soa2.example.com
.
tadm> copy-config --config=soa.example.com soa2.example.com
OTD-70201 Command 'copy-config' ran successfully.
For more information about copy-config
, see the Oracle Traffic Director Command-Line Reference or run the command with the --help
option.
You can delete a configuration by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Deleting a Configuration Using the Administration Console
To delete a configuration by using the administration console, do the following:
Log in to the administration console, as described in Accessing the Administration Console.
Click the Configurations button that is situated at the upper left corner of the page.
A list of the available configurations is displayed.
Select the configuration that you want to delete.
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.
Click Delete.
A message is displayed confirming that the configuration was deleted.
Click Close.
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.
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 Delete.
A message is displayed confirming that the configuration and its instances were deleted.
Click Close.
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.
Click the Delete button corresponding to the configuration that you want to delete.
Deleting a Configuration Using the CLI
Note:
You cannot delete a configuration by using the CLI 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 the CLI, you must first delete all of its instances.
To delete a configuration, run the delete-config
command, as shown in the following example:
tadm> delete-config --config=soa.example.com
OTD-70201 Command 'delete-config' ran successfully.
For more information about delete-config
, see the Oracle Traffic Director Command-Line Reference or run the command with the --help
option.
When you redeploy a modified configuration to its instances, a backup of the previous configuration is stored in a zip file in the configuration store on the administration server.
You can view a list of the backups of a configuration by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Viewing a List of Configuration Backups Using the CLI
To view a list of the backups of a configuration by using the CLI, run the following command:
tadm> list-backups --config=config_name --verbose --all
The following is an example of the output of the list-backups
command.
backup-id backup-date --------------------------- 20110712_025354 "Jul 12, 2011 2:53:54 AM" 20110712_024410 "Jul 12, 2011 2:44:10 AM" 20110712_004743 "Jul 12, 2011 12:47:43 AM" 20110711_231826 "Jul 11, 2011 11:18:26 PM
As shown in the example output, each backup configuration has a unique ID, which is assigned automatically when it is created. The ID indicates the date and time when the backup was created.
Viewing a List of Configuration Backups Using the Administration Console
To view a list of the backups of a configuration by using the administration console, do the following:
When you redeploy a modified configuration to its instances, a backup of the previous configuration is created. For information about viewing a list of the available backups, see Viewing a List of Configuration Backups.
You can restore a configuration from a backup by using either the administration console or the CLI.
Note:
The CLI examples in this section are shown in shell mode (tadm>
). For information about invoking the CLI shell, see Accessing the Command-Line Interface.
Restoring a Configuration from a Backup Using the Administration Console
To restore a configuration from a backup, by using the administration console, do the following: