Configuring Db2 connections to work with database sequences in DataStage

You can use Db2 database sequences as connections in several DataStage stages. However, you must first configure these connections for them to work properly.

About this task

To use a Db2® connection as a database sequence in applicable DataStage® stages, you must configure the connection by cataloging the connection itself and the database.

Procedure

To configure the Db2 connection:

  1. SSH to the Cloud Pak for Data cluster as a root user:
    ssh root@ <IP address>
  2. Log in to Docker:
    oc login -u kubeadmin -p <password> <URL to the cluster>
  3. Find out the name of the conductor node:
    oc get pods -n ds | grep ds-px-default-ibm-datastage-px-runtime
  4. Connect to the conductor pod:
    kubectl exec -it <conductor node name> -n ds bash
  5. On the conductor node, catalog the remote Db2 connection:
    db2 catalog tcpip node <catalog name> remote <hostname> server <port>
  6. On the conductor node, catalog the database:
    db2 catalog db sample as <database name> at node <catalog name>
  7. Add the package db2esql80:
    db2 bind /opt/ibm/PXService/Server/DSComponents/bin/db2esql80.bnd

What to do next

When you set up a Db2 database sequence as a connection in a DataStage stage, enter the following information:
Client instance name
Enter the default name of dsuser.
Client alias DB name
Enter the name of the remote database that you cataloged.