The IBM Replication administrator user ID can use the commands in this section to operate Capture for UNIX platforms. Enter the commands or key combinations from an AIX, HP-UX, or Solaris window.
This section explains how to perform the following Capture tasks:
Before starting the Capture program, make sure you complete the following post-installation tasks:
You can also create these control tables manually by running the DPCNTL.* file from the RUN SQL Files window.
After you start Capture, it runs continuously until you stop it or it detects an error.
To start Capture for AIX, Capture for HP-UX, and Capture for Solaris:
export DB2INSTANCE=db2_instance_name
While the Capture program is running, a file with the name <database_instance_name><database_name>.CCP is created in the directory from which the Capture program is invoked. This file is a log file for the messages issued by the Capture program; these messages are also recorded in the ASN.IBMSNAP_TRACE table.
>>-asnccp--+------------+-+--------+-+---------+-+---------+--->< +-src_server-+ +-warm---+ +-prune---+ +-notrace-+ +-warmns-+ +-noprune-+ +-trace---+ +-cold---+
Table 15 defines the optional parameters.
Table 15. ASNCCP Command Parameter Definitions for UNIX Platforms
|
---|
|
|
|
|
Use the at command to start Capture at a specific time. For example, the following command starts Capture at 3:00 p.m. on Friday:
at 3pm Friday asnccp warmns noprune
>>-asncmd--stop------------------------------------------------><
or
>>-kill---INT--pid---------------------------------------------><
or one of the following:
Use the stop command, the kill command, or the key combinations to stop the Capture program in an orderly way and commit the log records that it processed up to that point.
Stop Capture before:
>>-asncmd--suspend---------------------------------------------><
Use the suspend command to relinquish AIX, HP-UX, or Solaris resources to operational transactions during peak periods without damaging the Capture program environment.
This command suspends the Capture program until you issue the resume command.
Attention:
Do not use the suspend command when canceling a replication source. Instead, stop the Capture program.
To use the command, do the following from a different window than where the Capture program is running:
>>-asncmd--resume----------------------------------------------><
Use the resume command to restart the Capture program if you suspended it using the suspend command.
To use the command, do the following from a different window than where the Capture program is running:
>>-asncmd--reinit----------------------------------------------><
Use the reinit command to have the Capture program reread the ASN.IBMSNAP_REGISTER tables or the ASN.IBMSNAP_CCPPARMS table while it is running. Use this command when you add a new replication source with Control Center while the Capture program is running.
This command ensures that the Capture program recognizes the new replication source. The Capture program also rereads the ASN.IBMSNAP_CCPPARMS table for any changes made to the tuning parameters.
Attention:
Do not use the reinit command to reinitialize the Capture program after canceling a replication source or dropping a replication source table while Capture is running. Instead, stop the Capture program and restart it using the WARM option.
To use the command, do the following from a different window than where the Capture program is running:
>>-asncmd--prune-----------------------------------------------><
Use the prune command to perform pruning of the change data (CD) table and UOW table if you used the noprune invocation parameter.
This command prunes the CD and UOW tables once if pruning was disabled by using the Noprune parameter while starting the Capture program. The Capture program issues the message ASN0124I when the command is successfully queued.
To use the command, do the following from a different window than where the Capture program is running:
During pruning, if you stop or suspend Capture, pruning does not resume after you enter the resume command. You must enter the prune command again to resume pruning.
>>-asncmd--getlseq---------------------------------------------><
Use the getlseq command to provide the current log sequence number and the timestamp. You can use this number to determine how far Capture has read the DB2 log.
To use the command, do the following from a different window than where the Capture program is running: