HCL Workload Automation, Version 9.4

Reconfiguration from DB2 to Oracle

About this task

Perform the following steps to migrate all scheduling object definitions and global options from the DB2® database of a HCL Workload Automation version 9.4 master domain manager and make them point to an Oracle database.
  1. To export all scheduling object definitions and global options from DB2, from a Windows or UNIX command prompt run the dataexport command or script located in the <TWA_home>\bin directory:
    dataexport <source_dir> <export_dir>		 
    where:
    source_dir
    The HCL Workload Automation version 9.4 installation directory.
    export_dir
    The directory where the export files are to be created.
    For example:
    dataexport.cmd F:\TWS93\tws93user F:\TWS93\tws93user\export		 
    The object definitions and the global options are retrieved from the DB2 database and stored into the F:\TWS93\tws93user\export directory.
  2. Verify that the following files were created in export_dir:
    • calendars.def
    • erules.def
    • jobs.def
    • globalOpts.def
    • parms.def
    • prompts.def
    • resources.def
    • scheds.def
    • topology.def
    • users.def (includes encrypted user passwords)
    • vartables.def
    • rcgroups.def
    • acls.def
    • sdoms.def
    • srols.def
  3. Stop the WebSphere Application Server by using the conman stopappserver command (for details, see Starting and stopping the application server and appservman).
  4. To create an Oracle schema named tws93user on the TWS database see Procedure to create the HCL Workload Automation SQL tables for Oracle .

    The names of the table spaces are the defaults: USERS and TEMP.If an error occurs and you have to rerun this step after fixing it, you must first log in to the database as the administrator, then drop the twsDbUser (tws93user in the example).

  5. Change the data source properties from DB2 to Oracle by using the changeDataSource.bat (.sh) command or script to switch the data source in WebSphere® Application Server from DB2 to Oracle.

    See Changing data source properties for details on how to use the command.

    1. Clear the values of the following properties:
      DB2Type4JndiName
      DB2Type4DatabaseName
      DB2Type4ServerName
      DB2Type4PortNumber
      Note: For the property DB2Type4JndiName replace the value with any character or string to nullify it.
    2. Set these properties to the following values:
      OracleType2JndiName=jdbc/twsdb
      OracleType2DatabaseName=the Oracle instance name
      OracleType2PortNumber=the Oracle listener port number
    3. Set the JDBC driver path for the Oracle database to ORACLE_JDBC_DRIVER_PATH=Oracle_home/jdbc/lib and the Oracle instance type and name to ORACLETYPE2URL=JDBC:ORACLE:OCI:@instance_name
  6. Use the changeSecurityProperties.bat (.sh) command or script to change the following security settings (see Changing the security settings for details on using the command ):
    j2cUserid
    Write the value you used for twsDbUser in prepareSQLScripts.
    j2cPassword
    Write the password for the twsDbUser.
    Note: After you updated these two values, make sure that you also erase all the other lines in the security properties file before you export it again with the changeSecurityProperties command. Failure to do so will result in all the passwords contained in the file being saved as strings of asterisks (*).
  7. Modify the TWSConfig.properties file located in the <WAS_profile_path>/properties directory, where WAS_profile_path corresponds to the WebSphere Application Server profile path you specified at installation time. The default path is: <TWA_home>/WAS/TWSprofile. Take the comment marks off the following lines and edit them as shown:
    com.ibm.tws.dao.rdbms.rdbmsName = Oracle
    com.ibm.tws.dao.rdbms.modelSchema = <twsDbUser>
    com.ibm.tws.dao.rdbms.eventRuleSchema=<twsDbUser>
    com.ibm.tws.dao.rdbms.logSchema=<twsDbUser>
    where twsDbUser is the owner of the HCL Workload Automation schema that you specified also in the previous steps.
  8. For UNIX only: to set the paths for the new database in the WebSphere Application Server profile, run the updateSetupCmdLine.sh command or script located in the <TWA_home>/TWS/dbtools/oracle/scripts directory as follows:
    updateSetupCmdLine.sh -installRoot <TWA_home> -dbRoot <DB_home>
    where:
    –installRoot <TWA_home>
    The installation directory of HCL Workload Automation.
    –dbRoot <DB_home>
    The installation directory of the database.
  9. Start the WebSphere Application Server by using the conman startappserver command (for details, see Starting and stopping the application server and appservman)
  10. Manually copy the master domain manager definition from the topology.def file you exported in step 1 (you can find it in export_dir) and use composer new to add it in the Oracle database.
  11. To import all scheduling object definitions and global options to the Oracle database, from a UNIX or Windows command prompt run the dataimport file located in <TWA_home>\bin as follows:
    dataimport <source_dir> <export_dir>		 
    where:
    source_dir
    The HCL Workload Automation installation directory.
    export_dir
    The directory from where the export files are to be read from. This directory is the same export_dir directory specified for dataexport.
    For example:
    dataimport.cmd F:\TWS93\tws93user F:\TWS93\tws93user\export		 
    The object definitions and the global options are retrieved from the F:\TWS93\tws93user\export directory and stored in the new Oracle database.
  12. Run the following command to set the carry forward option to ALL:
    optman chg cf=ALL
  13. Update the Symphony file by creating a plan with 0 extension period that begins at the end of the current plan:
    JnextPlan -from start_time -for 0000
    where start_time is the date and time when the current plan ends.

To complete the reconfiguration process, you must also perform the steps listed in the Planning and Installation, Part "HCL Workload Scheduler", Chapter "Creating or upgrading the HCL Workload Scheduler database tables before installing or upgrading", section "Creating or upgrading the database tables if you are using Oracle", subsection "Running scripts to create or upgrade the SQL tables for Oracle", subsection "Procedure to create the HCL dynamic workload broker SQL tables for Oracle".

You have now completed the reconfiguration steps.

To migrate a backup master domain manager, perform the following steps: