D Oracle Fusion Middleware T2P Utility for Oracle Traffic Director

This appendix describes the Oracle Fusion Middleware T2P utility for Oracle Traffic Director, and contains the following sections:

D.1 Introduction

The Oracle Fusion Middleware T2P utility allows you to move an Oracle Fusion Middleware environment from test to production (T2P) with customization specific to the production environment. This appendix describes support for moving an Oracle Traffic Director environment.

Moving an Oracle Traffic Director installation minimizes the amount of work that would otherwise be required to reapply all the customization and configuration changes made in one environment to another. You can install, configure, customize, and validate Oracle Traffic Director in a test environment. Once the system is stable and performs as required, you can create the production environment by moving a copy of the server and its configuration from the test environment, instead of redoing all the changes that were incorporated into the test environment. If you have an existing production environment, you can move any modifications of the test environment, such as customization, to the production environment.

Moving an Oracle Traffic Director installation from a test to a production environment assumes that the production environment is on the same operating system as the test environment. In addition, the operating system architecture must be the same in both environments. For example, both environment must be running 64-bit operating systems.

For more information on Fusion Middleware Test to Production see: Moving from a Test to a Production Environment in Oracle Fusion Middleware Administering Oracle Fusion Middleware.

D.2 Overview of the T2P Process

The T2P move of an Oracle Fusion Middleware environment consists of the following two broad steps:

Moving the binaries to the production system.

Moving the configuration to the production system.

  • Copy Binary (Oracle Home) - This is the process of creating an archive of the Oracle Home where Oracle Traffic Director is installed.

  • Copy Configuration - This is the process of creating an archive of the domain configuration for Oracle Traffic Director.

  • Edit Configuration - This is the process of creating an archive of the domain configuration for Oracle Traffic Director.

  • Paste Binary (Oracle Home) - This is the process of recreating the binaries at the destination.

  • Paste Configuration - This is the process of recreating the configurations at the destination.

The destination configuration of a component can be customized during the T2P move using a document generated during the Copy Configuration phase called a move plan.

D.3 Requirements

The following are requirements for the destination host:

  • A JDK must be present on destination host in order to execute the T2P scripts.

  • The archive created during the Copy Binary/Configuration phase must be accessible.

D.4 Usage of the T2P Utility

The following examples show how to execute commands from the T2P utility.

D.4.1 Copy Binary (Oracle Home)

To create an archive of the Oracle Home including all the files, libraries, and configuration, execute copyBinary.sh. After the copy binary operation, created jar file should be copied to the production system.

The following is an example command:

Example D-1 Copy Binary Command

./copyBinary.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/mw.jar -sourceOracleHomeLoc /scratch/installers/colocated_otd

D.4.2 Copy Configuration

To create an archive of the domain configuration (extended for Oracle Traffic Director), execute copyConfig.sh. This command introspects all the OTD configurations present in the domain home. Specifically, it introspects the OTD configuration file server.xml, and extracts elements such as http-listener, tcp-listener, origin-server-pool, and failover-group from server.xml. You can customize the values of these elements by editing the move plan. After the copy configuration operation, created jar file should be copied to the production system

The following is an example command:

Example D-2 Copy Configuration Command for Collocated OTD

./copyConfig.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/otd.jar -sourceDomainLoc /scratch/installers/otd_domain -sourceOracleHomeLoc /scratch/installers/colocated_otd -domainHostName abc1234.example.com -domainPortNum 7010 -domainAdminUserName weblogic -domainAdminPasswordFile /scratch/password.txt

Note:

Make sure that WLS administration server is running, when you perform Appendix D, "Copy Configuration".

Example D-3 Copy Configuration Command for Standalone OTD

./copyConfig.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/otd.jar -sourceDomainLoc /scratch/installers/otd_domain -sourceOracleHomeLoc /scratch/installers/colocated_otd

D.4.3 Edit Configuration

To edit a configuration, we need to extract the move plan, execute extractMovePlan.sh. For details on customizing the move plan, see Extracting and Customizing an Oracle Traffic Director Move Plan.

The following is an example command:

Example D-4 Extract Move Plan Command

./extractMovePlan.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/otd.jar -planDirLoc /scratch/moveplan/

D.4.4 Paste Binary (Oracle Home)

To recreate the binaries at the destination, execute pasteBinary.sh. The following is an example command:

Example D-5 Paste Binary Command

./pasteBinary.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/mw.jar -targetOracleHomeLoc /scratch/installers/cloned_colocated_otd/

D.4.5 Paste Configuration

To recreate the configurations at the destination, execute pasteConfig.sh. This command extracts the custom values from the customized move plan, updates the configuration with the value specified in the move plan, and saves the configuration.

The following is an example command:

Example D-6 Paste Configuration Command for Collocated OTD

./pasteConfig.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/otdc.jar -movePlanLocation /scratch/moveplan/moveplan.xml -targetDomainLoc /scratch/installers/cloned_domain -targetOracleHomeLoc /scratch/installers/cloned_colocated_otd/ -domainAdminPasswordFile /scratch/password.txt

Example D-7 Paste Configuration Command for Standalone OTD

./pasteConfig.sh -javaHome ./oracle_common/jdk/jre -archiveLoc /tmp/otdc.jar -movePlanLocation /scratch/moveplan/moveplan.xml -targetDomainLoc /scratch/installers/cloned_domain -targetOracleHomeLoc /scratch/installers/cloned_colocated_otd

Additional Steps for Moving Oracle Traffic Director:

  • Cert Reconfiguration : Certificate can be reconfigured using otd_setHttpListenerSslProperties/otd_setTcpListenerSslProperties/otd_setVirtualServerSslProperties or otd_setOriginServerPoolSslProperties.

  • OAM Reconfiguration : If webgate is configured in the OTD instance and the user wants to re-configure OAM at the target Env in order to use a different OAM instance, then this use case must be handled manually once the pasteConfig is done.

Note:

Make sure that all the paths configured for OTD instance are accessible and have proper file permissions on the target environment. For example, server log file path.

For more information on WLST, see WebLogic Scripting Tool Command Reference for Oracle Traffic Director

D.5 Extracting and Customizing an Oracle Traffic Director Move Plan

There are few elements in the Oracle Traffic Director server.xml that you can customize using the move plan. These elements are listed below:

Table D-1 Oracle Traffic Director Elements for Customization

Element Editable Properties

http-listener

ip, port and server-name

tcp-listener

ip and port

failover-group

virtual-ip

origin-server-pool

origin-servers


You should also modify the following properties of the domain:

  • Create a new schema for the target domain and update the schema prefix in the move plan, valid only when domain is full JRF.

  • Update the Password file for node manager element. By default the value is </value> which you should modify to <value>/scratch/T2P/password.txt</value>. The password file you provide must exist on the file system.

The following in an example Oracle Traffic Director move plan:

<movableComponent>
  <componentType>OTD</componentType>
  <componentName>test</componentName>
  <Description>otd component</Description>
  <moveDescriptor>
    <configGroup>
      <type>http-listeners</type>
      <configProperty id="http-listener-1">
        <configProperty>
          <name>Ip</name>
          <value>*</value>
          <itemMetadata>
            <dataType>INTEGER</dataType>
            <scope>READ_WRITE</scope>
          </itemMetadata>
        </configProperty>
        <configProperty>
          <name>Port</name>           
          <value>7011</value>
          <itemMetadata>
            <dataType>INTEGER</dataType>
            <scope>READ_WRITE</scope>
          </itemMetadata>
        </configProperty>
        <configProperty>
          <name>ServerName</name>
          <value>abc1234.example.com</value>
          <itemMetadata>
            <dataType>STRING</dataType>
            <scope>READ_WRITE</scope>
          </itemMetadata>
        </configProperty>
      </configProperty>     
    </configGroup>
    <configGroup>
      <type>tcp-listeners</type>
    </configGroup>
    <configGroup>
      <type>origin-server-pool</type>
      <configProperty id="origin-server-pool-1">
        <configProperty id="origin-server-1">
          <name>origin-server-1</name>
          <value>abc1234.example.com:7010</value>
          <itemMetadata>
            <dataType>STRING</dataType>
            <scope>READ_WRITE</scope>
          </itemMetadata>
        </configProperty>
        <configProperty id="origin-server-2">
          <name>origin-server-2</name>
          <value>abc1234.example.com:7015</value>
          <itemMetadata>
            <dataType>STRING</dataType>
            <scope>READ_WRITE</scope>
          </itemMetadata>
        </configProperty>
      </configProperty>
    </configGroup>
    <configGroup>
      <type>failover</type>
      <configProperty id="failover-group-1">
        <name>virtual-ip</name>
        <value>10.100.10.1</value>
        <itemMetadata>
          <dataType>STRING</dataType>
          <scope>READ_WRITE</scope>
        </itemMetadata>
      </configProperty>
    </configGroup>
  </moveDescriptor>
</movableComponent>
</movableComponent>

D.6 Logging

The T2P utility puts the logs for the copy and paste phases into the Java temp directory (For example: /tmp/CLONE<Date Time>.log). The failures and errors are logged into a separate CLONE<Date Time>.error file in the format Error Message, Cause and Action. You can specify a different location for the logs using the command line argument -logDirLoc.