You set up replication in the InfoSphere® CDC Management Console to
define how change data is captured and sent to the target. To set
up replication, you add data stores for the source and target, add
a new subscription, and map one or more tables to the target system.
About this task
This procedure describes the general steps that you must
perform to set up replication in the InfoSphere CDC Management Console.
For more information about setting up replication, see the InfoSphere CDC documentation.
(When searching for information about adding data stores, note that
the InfoSphere CDC documentation
spells data store as one word, datastore.)
Procedure
- Log on to the InfoSphere CDC Management Console.
Enter the connection information that you specified for InfoSphere CDC Access Server during
the installation.
- In the Access Manager perspective, add data stores for
the source and the target.
- In the Datastore Management tab,
add a data store for the source database. Specify details about the
data store, including the following settings:
- For the server name, enter the host name of the computer where
you installed InfoSphere CDC for
the source database.
- For the port number, enter the number that you specified when
you configured InfoSphere CDC for
the source database.
- Add a data store for the target, InfoSphere DataStage.
Specify details about the target, including the following settings:
- For the server name, enter the host name of the computer where
you installed InfoSphere CDC for InfoSphere DataStage.
- For the port number, enter the number that you specified when
you configured InfoSphere CDC for InfoSphere DataStage.
- For the connection parameters, specify the credentials for tsuser,
the user that you created when you configured InfoSphere CDC for InfoSphere DataStage.
- Optional: In the User Management tab,
add a new user. You can add a new user or use an existing
one.
- In the Connection Management tab,
assign a user to each data store.
- In the Configuration perspective of the InfoSphere CDC Management Console,
add a new subscription. A subscription contains mapping
details that specify how data in a source data store is applied to
a target data store.
- For the source, select the data store that contains
the tables that you want to replicate.
- For the target, select the data store that you created
for InfoSphere DataStage.
- In the Configuration perspective of the InfoSphere CDC Management Console,
use the Map Tables wizard to map one or more
tables to the target, InfoSphere DataStage. When you run the wizard, make sure that you select the following
options.
- In the Select Map Typing page,
select InfoSphere DataStage.
- In the Select InfoSphere DataStage Connection
Method page, select Direct Connect.
- In the Select Source Tables page,
select the tables that you want to replicate.
- In the InfoSphere DataStage Direct Connect page,
select the type of record format to use for the change data.
- Single Record
- Both the "before image" (the record before the update) and the
"after image" (the record after the update) are sent in a single record.
- Multiple Records
- The "before image" and the "after image" are sent in separate
records.
After you have mapped a table to a target,
the table is no longer available for another mapping within the same
subscription.
- In the Configuration perspective of the InfoSphere CDC Management Console,
specify InfoSphere DataStage properties.
- In the Subscriptions tab, right-click
the subscription, and select .
The subscription must be open for editing when you define these properties,
or your changes are not saved.
- In the Direct Connect area, specify the project name,
job name, and connection key for the InfoSphere DataStage job. The connection key ensures that only the job with the correct
connection key information is used by InfoSphere DataStage when
receiving change data from InfoSphere CDC.
You specify this connection key as a stage property when you configure
the InfoSphere DataStage job.
- Optional: If you want to configure the job
to start automatically when the subscription starts, select Auto-start
InfoSphere DataStage Job.
Important: For the auto-start function
to work correctly,
InfoSphere CDC must
be able to load and execute the
dsjob command and
the dependent shared library. The path to this library must be specified
in the library path environment variable on the computer where
InfoSphere CDC for InfoSphere DataStage is
installed.
On UNIX or Linux, you can view and modify
the setting for this environment variable in the
dsenv file.
After setting this environment variable, source the
dsenv file
and then start the
InfoSphere CDC for InfoSphere DataStage server
to set these environment variables for the server. For example, issue
one of the following commands to source the
dsenv file:
$ . dsenv
or
$ source dsenv
Then
issue the following command to start the
InfoSphere CDC for InfoSphere DataStage server:
$ dmts64 -I <instance name>
The
environment variables for the process,
dmts64, are
set as specified in the
dsenv file.
Also,
make sure that the process is executed by a user with the user privilege
and permission to run the dsjob command. A user
who is added to the primary group of the DataStage administrator primary
group has the user privileges and the permission to the dsjob command