BEA Logo BEA WLCS Release 3.5

  BEA Home  |  Events  |  Solutions  |  Partners  |  Products  |  Services  |  Download  |  Developer Center  |  WebSUPPORT

 

   WLCS Documentation   |   Deployment Guide   |   Previous Topic   |   Next Topic   |   Contents   |   Index

Migrating Oracle Data Objects

 

Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server includes a set of SQL scripts that create Oracle tables and other data objects in your testing, staging, or production environment. After creating the data objects, you can use Oracle commands to export data from the source environment and import it into a destination environment.

The Oracle commands export and import all Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server data including any document metadata that is part of the default content management implementation. The commands do not move the following:

To export Oracle data objects to a destination environment, complete the following tasks:

Step 1: Create the Destination Environment

Step 2: Review Parameter Files

Step 4: Delete Sample Data (Optional)

Step 5: Remove Orphaned Records

Step 6: Export the Data

Step 7: Stop the Server in the Destination Environment

Step 8: Import the Data

Step 9: Start the Server in the Destination Environment

 


Step 1: Create the Destination Environment

To create the destination environment, follow the procedures in Setting Up Oracle for New Installations.

For more information about Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server database schemas, refer to the following documents:

 


Step 2: Review Parameter Files

Complete this step only if you use a third-party solution (such as Interwoven or Documentum) for content management.

If your Oracle user account contains data objects that Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server does not create and maintain (such as Interwoven and Documentum objects), you must use parameter files to establish user identity and determine the tables for which you want to export and import data.

Reviewing the parameter files involves the following tasks:

For more information about the Oracle export and import commands and about the function of the parameters in the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server parameter files, see the following Oracle document: http://technet.oracle.com/docs/products/oracle8i/doc_library/817_doc/server.817/a76955/toc.htm.

Note: To access articles on technet.oracle.com, you must register as a member of Oracle Technology Network. For more information, refer to http://technet.oracle.com.

Review the List of Tables

Complete this procedure only if you use a third-party solution (such as Interwoven or Documentum) for content management.

Note: In this document, WL_COMMERCE_HOME refers to the directory into which you installed WebLogic Commerce Server and/or WebLogic Personalization Server.

Review the list of tables in the parameter files and, if necessary, modify them to match your environment:

  1. Save backup copies of the following files: WL_COMMERCE_HOME/db/oracle/8.1.6/migration/staging/wlcs_exp.par
    WL_COMMERCE_HOME/db/oracle/8.1.6/migration/staging/wlcs_imp.par

  2. Open both files in a text editor.

  3. If you are using Interwoven or Documentum for content management, prevent the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server scripts from exporting and importing data into content management tables by removing the following table names:

Note: If you are using the reference implementation (BulkLoader) for content management, you must leave these table names in the files.

  1. If you added or removed tables from the default database schemas, add or remove the corresponding table names in the parameter files.

  2. Save your modifications to the parameter files.

Add FROMUSER to the Import Parameter File

Complete this procedure only if you use a third-party solution (such as Interwoven or Documentum) for content management.

To specify the user account that owns the schema you want to import, do the following:

  1. Make a backup copy of the following file:
    WL_COMMERCE_HOME/db/oracle/8.1.6/migration/staging/wlcs_imp.par

  2. Open wlcs_imp.par in a text editor.

  3. For the FROMUSER entry, specify the name of the user who owned the schema in the source environment. For example, in your development environment, the owner of the Oracle schema is WEBLOGIC. In wlcs_imp.par, you modify the first line as follows:
    FROMUSER=WEBLOGIC

 


Step 4: Delete Sample Data (Optional)

Caution: Before you delete sample data, back up your database.

If you loaded sample data and you do not plan to it in the destination environment, we recommend that you delete it before you export data. Do not delete the administrator users or administrator group.

For information on preventing sample data from loading, refer to Prevent Sample Data from Loading (optional).

Your database might contain samples for the following types of data:

You can use the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server Administration Tool to delete sample data. To access the Administration Tool, start the server and enter the following URL in a Web browser:
http://localhost:7501/tools/index.jsp

For example, to delete sample users from the Administration Tool:

  1. Back up your database.

  2. From the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server Administration Tool click User Management.

  3. From the User Management page, click Users.

  4. From the Users Page, under Search for Users, enter * (asterisk) in the Username box. Then click Search.

    The search mechanism returns a list of all users.

  5. To delete a user, click the red X next to the username. Do not delete the administrator users.

  6. After deleting all sample users, click Finished from the Users Page.

  7. From the Users Page, click Groups.

  8. From the Groups page, click the red X next to sample group names. Do not delete the administrator group.

  9. Click Finished.

 


Step 5: Remove Orphaned Records

Note: In this document, WL_COMMERCE_HOME refers to the directory into which you installed WebLogic Commerce Server and/or WebLogic Personalization Server.

To verify that there are no orphaned records in your database, do the following:

  1. In SQL*Plus, log in as SYSTEM (or another user with DBA privileges).

  2. In the SQL*Plus session, enter the following command:
    @ WL_COMMERCE_HOME/db/oracle/8.1.6/migration/staging/del_orphaned_recs.sql

    The del_orphaned_recs.sql removes any orphaned records.

 


Step 6: Export the Data

To export data, complete one of the following tasks:

Export All Tables in the User Account

If you are using the reference implementation for content management and the Oracle user account in the destination environment contains only Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server data objects, do the following to export data:

  1. From a command line, enter the following command:

    exp username/password@ORACLE_SID file=wlcs.dmp owner=WEBLOGIC log=wlcs_exp.log

Note: You can use a username and password for any account with DBA privileges. ORACLE_SID must specify the database in which the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server schema resides. If you changed the WEBLOGIC user account name, change the value for owner.

When the exp command finishes exporting data, it prints the following message:
Export terminated successfully without warnings

  1. To review the results of your export, open the log file that you specified in step 1.

For more information about the Oracle export and import commands, see the following Oracle document: http://technet.oracle.com/docs/products/oracle8i/doc_library/817_doc/server.817/a76955/toc.htm.

Export Specific Tables from the User Account

Complete this procedure only if you use a third-party solution (such as Interwoven or Documentum) for content management.

If your Oracle accounts contain data objects that Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server does not create and maintain (such as Interwoven and Documentum objects), do the following to export data:

  1. In SQL*Plus, log in as SYSTEM (or another user with DBA privileges).

  2. In the SQL*Plus session, enter the following command:
    exp username/password@ORACLE_SID file=wlcs.dmp owner=WEBLOGIC  parfile=WL_COMMERCE_HOME/db/oracle/8.1.6/migration/staging/wlcs_exp.par log=wlcs_exp.log

Note: You can use a username and password for any account with DBA privileges. ORACLE_SID must specify the database in which the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server schema resides. If you changed the WEBLOGIC user account name, change the value for owner.

When the exp command finishes exporting data, it prints the following message:
Export terminated successfully without warnings

  1. To review the results of your export, open the log file that you specified in step 2.

    If you installed WebLogic Personalization Server without WebLogic Commerce Server, the log file may include TABLE OR VIEW DOES NOT EXIST statements for each WebLogic Commerce Server table. You can ignore these messages.

For more information about the Oracle export and import commands, see the following Oracle document: http://technet.oracle.com/docs/products/oracle8i/doc_library/817_doc/server.817/a76955/toc.htm.

 


Step 7: Stop the Server in the
Destination Environment

Before importing data, you must stop Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server by entering Ctrl+C in the shell that is running the server.

 


Step 8: Import the Data

Caution: Before you import data, back up your database in the destination environment.

To import data, complete one of the following tasks:

Import to All Tables in the User Account

If the Oracle user account in the destination environment contains only Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server data objects, do the following to import data:

  1. In the destination environment, back up your database.

  2. Start SQL*Plus and log in as SYSTEM (or another user with DBA privileges).

  3. Enter the following command:

    imp username/password@ORACLE_SID file=wlcs.dmp log=wlcs_imp.log fromuser=WEBLOGIC touser=WEBLOGIC ignore=y commit=y

Note: You can use a username and password for any account with DBA privileges. ORACLE_SID must specify the database in which the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server schema resides. If you changed the WEBLOGIC user account name, change the value for fromuser and touser.

For more information about the Oracle export and import commands, see the following Oracle document: http://technet.oracle.com/docs/products/oracle8i/doc_library/817_doc/server.817/a76955/toc.htm.

Import to Specific Tables in the User Account

Complete this procedure only if you use a third-party solution (such as Interwoven or Documentum) for content management.

If your Oracle accounts contain data objects that Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server does not create and maintain (such as Interwoven and Documentum objects), do the following to import data:

  1. In the destination environment, back up your database.

  2. Start SQL*Plus and log in as SYSTEM (or another user with DBA privileges).

  3. Enter the following command:
    imp username/password@ORACLE_SID file=wlcs.dmp log=wlcs_imp.log parfile=WL_COMMERCE_HOME/db/oracle/8.1.6/migration/staging/wlcs_imp.par 

Note: You can use a username and password for any account with DBA privileges. ORACLE_SID must specify the database in which the Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server schema resides.

For more information about the Oracle export and import commands, see the following Oracle document: http://technet.oracle.com/docs/products/oracle8i/doc_library/817_doc/server.817/a76955/toc.htm.

 


Step 9: Start the Server in the
Destination Environment

To start WebLogic Commerce Server and/or WebLogic Personalization Server on UNIX, enter the following command from a Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server host:
WL_COMMERCE_HOME/StartCommerce.sh

To start WebLogic Commerce Server and/or WebLogic Personalization Server on Windows, on a Campaign Manager for WebLogic, WebLogic Commerce Server, and WebLogic Personalization Server host, do one of the following:

For information on starting the server, refer to Starting and Shutting Down the Server.

 

back to top previous page