Creating a DB2 UDB for Linux, UNIX, and Windows database for process choreographer

This topic describes how to create a DB2 UDB database for process choreographer.

Steps for this task

  1. Install DB2 UDB on the machine that hosts the database.
  2. Install the DB2 run-time client on:
    • All remote application servers that use a type-2 JDBC driver to access the database.
    • On the deployment manager machine, if you use Network Deployment to administer process choreographer, for example if you are creating a clustered process choreographer setup.
  3. If your database server is not on the same machine as your application server, copy the following DDL scripts from the ProcessChoreographer subdirectory of your application server install_root directory to your database server machine.
    clearSchemaDb2.ddl
    createDatabaseDb2.ddl
    createTablespaceDb2.ddl
    createSchemaDb2.ddl
    dropSchemaDb2.ddl
    dropTablespaceDb2.ddl
    
  4. Change to the directory where the configuration scripts for process choreographer are located:
    • If your database server is on the same machine as your Enterprise Application Server: On Windows systems, enter: cd install_root\ProcessChoreographer. On UNIX and Linux systems, enter: cd install_root/ProcessChoreographer.
    • If your database server is on a different machine than your application server, change to the directory where you copied the DDL scripts.
  5. If you want to use an existing database, skip to step 11 to create the table space and schema.
    Unicode support: Make sure that the database supports Unicode (UTF-8). Without Unicode support, it cannot store all characters that can be handled in Java code, and you can run into code page conversion problems when a client uses an incompatible code page.
  6. To avoid deadlocks, verify that the DB2 flag DB2_RR_TO_RS is set to YES. If necessary, enter the command:

    db2set DB2_RR_TO_RS=YES
    then restart the DB2 instance to activate the change.

  7. Create a DB2 instance on the database machine.
  8. If you have a Symmetric Multi-Processor (SMP) machine, set the number of processors that can be used by DB2.
    On UNIX and Linux systems, use /usr/opt/db2_08_01/adm/db2licm -l.
  9. Create a new database named BPEDB:
    1. Make sure that you use a user ID that has administrator rights for the database system.
    2. If you want to create a non-production database, named BPEDB, for stand-alone development, evaluation, or demonstration purposes, you only need to enter the following command:
      db2 -tf createDatabaseDb2.ddl
      Otherwise you must create it manually using the other scripts. For a production environment consider using dedicated table space containers and adjusting the DB2 parameters.
    3. Make sure that the script output contains no errors.
      In some cases, the CLI packages are not bound to the new database. To be sure that the CLI packages are bound to the new database, for a database named BPEDB:

      On Windows systems, enter:

      db2 connect to BPEDB 
      db2 bind %DB2PATH%\bnd\@db2cli.lst blocking all grant public
      On UNIX and Linux systems, enter:
      db2 connect to BPEDB 
      db2 bind $DB2DIR/bnd/@db2cli.lst blocking all grant public

  10. To create the table space and schema:
    1. Analyze the results of your experiences during development and system testing.
      The size of your database depends on many factors. Non-interruptible processes require very little space. Each process template can require tens or hundreds of kilobytes. If possible, distribute table space containers across different logical disks, and implement an appropriate security policy. Consider the performance implications of your choices for buffer pools and log file settings.
    2. Edit the createTablespaceDb2.ddl table space creation script according to the instruction at the top of the file.
    3. Make sure that you have administrator rights for the database system.
      The user ID that you use to create the schema must be the one that you specify for WebSphere Application Server to use for database access.
    4. Make sure that you are attached to the correct instance.
      Check the DB2INSTANCE environment variable.
    5. To connect to a database named databaseName, in the DB2 command line processor, enter the command:
      db2 connect to databaseName
    6. To create the table space, enter the command:
      db2 -tf createTablespaceDb2.ddl
      Make sure that the script output contains no errors. If errors occurred, you can drop the table space using the dropTablespaceDb2.ddl script.
    7. To create the schema (tables and views) in the DB2 command line processor, enter the command:
      db2 -tf createSchemaDb2.ddl
      Make sure that the script output contains no errors. If you want to drop the schema, use the dropSchemaDb2.ddl script.
  11. On each application server that remotely accesses the database (and on the deployment manager machine if you are creating a clustered setup or if you want to use Network Deployment):
    1. Catalog the database by entering the command:
      db2 catalog database databaseName as databaseAlias at node nodeName
      For more information about cataloging a database refer to the DB2 documentation.
    2. Verify that you can connect to the database by entering the commands:
      db2 connect to databaseName user userID
      db2 connect reset

Results

The DB2 UDB database for process choreographer exists.



Searchable topic ID:   t2codbdb
Last updated: Jun 21, 2007 8:07:48 PM CDT    WebSphere Business Integration Server Foundation, Version 5.0.2
http://publib.boulder.ibm.com/infocenter/wasinfo/index.jsp?topic=/com.ibm.wasee.doc/info/ee/workflow/tasks/t2codbdb.html

Library | Support | Terms of Use | Feedback