Skip Headers
Oracle® Traffic Director Configuration File Reference
11g Release 1 (

Part Number E21038-03
Go to Documentation Home
Go to Book List
Book List
Go to Table of Contents
Go to Index
Go to Feedback page
Contact Us

Go to previous page
Go to next page
PDF · Mobi · ePub

2 Syntax and Use of server.xml

The server.xml file contains most of the server configuration. This chapter describes the basic syntax of the server.xml file and provides a high-level view of the elements that are used to configure features of the server. This chapter contains the following topics:

2.1 Overview of server.xml

The server.xml file contains the elements that define the configuration. The server.xml file is located in the
INSTANCE_HOME/net-server-id/config directory.

The encoding is UTF-8 to maintain compatibility with UNIX text editors.

2.1.1 Editing the server.xml File

The structure of the server.xml file is a hierarchy, with server as the topmost element. The server element has many subelements, many of which have subelements of their own.

In general, you do not need to edit server.xml directly. Instead, use the Administrator Console and the tadm command-line interface to change values in the server.xml file. The changes that are made using the Administrator Console and tadm command-line interface affects the server.xml file. Using tadm when creating scripts to change the server.xml file ensures forward compatibility. If you edit the server.xml file directly, ensure that the resulting server.xml file is valid. Editing Element Values

To change the values in the server.xml file, change the value between the tags associated with the element you are editing. For example, to change the value of
<log-level> from NOTIFICATION:1 to TRACE:1, find the log child element of the server element. In this example, you see the following lines:

For example:

Changing the log-level from NOTIFICATION:1 to TRACE:1 is shown below:




After you make changes to the server.xml file, you must deploy your configuration for most changes to take effect. Use the command-line interface command tadm pull-config to pull the modified server.xml file, then use the Administrator Console or the tadm deploy-config command to deploy your changes. For some changes, you must restart the server before they take effect. For information about changes that require a restart and which do not, see Section 1.3, "Dynamic Reconfiguration". Adding Elements

To add a new element to the file, add the element and any required subelements. Elements begin with a tag, for example <virtual-server>, and end with the closing tag, for example </virtual-server>. The tags are case-sensitive. Validating server.xml

After editing the server.xml file, Oracle Traffic Director automatically validates the XML code when you start or dynamically reconfigure a server.

You can also use the -configtest option of the startserv script to validate your configuration. From the instance's bin directory, run:

startserv -configtest

2.2 Understanding server.xml

To change the server.xml file for your environment, you must know which elements contain the relevant settings. The following sections contain brief descriptions of the elements that configure the functional areas:

For more information about all the server.xml elements and their subelements, see Elements in server.xml.

2.2.1 Server Pools

The origin-server element defines a member of a server pool. The origin-server-pool element configures a pool of origin servers that are used for load balancing requests. An origin server is a back-end server—such as an Oracle WebLogic Server instance or an Oracle iPlanet Web Server instance—to which Oracle Traffic Director should forward requests that it receives from clients, and from which it receives responses. A set of origin servers providing the same service constitute an origin server pool. For more information, see Section 3.1.15, "origin-server-pool", Section 3.1.16, "origin-server", Section 3.1.22, "server"

2.2.2 Health check

The health-check element configures the parameters that are used to determine the status of each origin server in an origin-server pool. The health-check element is a subelement of the origin-server-pool element. For more information, see Section 3.1.8, "health-check" and Section 3.1.15, "origin-server-pool"

2.2.3 High Availability

The failover-group element is a grouping of a VIP (Virtual IP), an instance that is designated as the primary server and another instance designated as the backup server. The Active-Passive or Active-Active cluster failover configurations are represented as Failover Groups. The failover-group element defines a failover group. For more information, see Section 3.1.7, "failover-group"

2.2.4 HTTP Protocol

The http element configures the general HTTP protocol options. The keep-alive element configures the HTTP keep-alive connection management. The http-listener element configures the ports and IP addresses on which the server listens for new HTTP connections. The virtual-server element configures a method by which the server processes the HTTP requests. For more information, see Section 3.1.9, "http", Section 3.1.12, "keep-alive", Section 3.1.10, "http-listener", and Section 3.1.36, "virtual-server".

2.2.5 Logging and Monitoring

The access-log element configures the file name and format of access logs. The access-log-buffer element configures the frequency of access log updates and ordering of the access log entries. For more information, see Section 3.1.1, "access-log" and Section 3.1.2, "access-log-buffer". For more information about the log file format, see Appendix B, "Using the Custom Access-Log File Format".

The log element configures the file name and contents of the server log. The event element configures the access log and server log rotation. For more information, see Section 3.1.14, "log" and Section 3.1.6, "event".

The snmp element configures Simple Network Management Protocol (SNMP), and the stats element configures statistics collection. For more information, see Section 3.1.23, "snmp" and Section 3.1.27, "stats".

2.2.6 Performance Tuning

The thread-pool element configures the number of threads used to process requests and the maximum number of HTTP connections that the server queues. For more information, see Section 3.1.32, "thread-pool".

The keep-alive element configures the HTTP keep-alive connection management. For more information, see Section 3.1.12, "keep-alive". The dns-cache element configures the DNS caching. For more information, see Section 3.1.5, "dns-cache".

2.2.7 SSL, TLS, and PKCS #11

The ssl element configures Secure Sockets Layer (SSL) and Transport Layer Security (TLS). SSL and TLS can be configured separately for each HTTP listener. For more information, see Section 3.1.24, "ssl" and Section 3.1.10, "http-listener".

The pkcs11 element configures the PKCS #11 subsystem, including certificate revocation lists (CRLs) and third-party cryptographic modules. For more information, see Section 3.1.17, "pkcs11".

2.2.8 Variables

The variable element defines a variable for use in expressions, log formats, and obj.conf parameters. For more information about the variable element, see Section 3.1.35, "variable". For more information about variable and expression use, see Appendix A, "Using Variables, Expressions, Wildcards, and String Interpolation".

2.2.9 Virtual Servers

The virtual-server element configures the virtual servers. Each virtual server processes HTTP requests from one or more HTTP listeners. The http-listener element configures the HTTP listeners. For more information, see Section 3.1.36, "virtual-server", and Section 3.1.10, "http-listener".

You can define variables within a virtual server using the variable element, as described in Section 2.2.8, "Variables".

2.3 Sample server.xml File

Example 2-1 shows an excerpt from a server.xml file.

Example 2-1 server.xml file

<?xml version="1.0" encoding="UTF-8" ?>
  Copyright (c) 2011, Oracle and/or its affiliates. All rights reserved