IBMSNAP_CAPPARMS table

The IBMSNAP_CAPPARMS table contains parameters that you can modify to control the operations of the Capture program. You can define these parameters to set values such as the length of time that the Capture program retains data in the CD and UOW tables before pruning and the amount of time that the Capture program is allowed to lag in processing log records. If you make changes to the parameters in this table, the Capture program reads your modifications only during startup.

Server: Capture control server

Default schema: ASN

Index: None

This table contains information that you can update by using SQL.

Table 1 provides a brief description of the columns in the IBMSNAP_CAPPARMS table.

Table 1. Columns in the IBMSNAP_CAPPARMS table
Column name Description
RETENTION_LIMIT Data type: INTEGER; Nullable: Yes

The number of minutes that rows remain in the CD, UOW, and signal tables before they become eligible for pruning, in cases where they have not been pruned based on the normal criteria. Normally, CD and UOW rows are pruned after they are applied to all targets, and signal rows are pruned when their cycle is complete (SIGNAL_STATE = C).

LAG_LIMIT Data type: INTEGER; Nullable: Yes

The number of minutes that the Capture program is allowed to lag when processing log records before it shuts itself down. During periods of high update frequency, full refreshes can be more economical than updates.

COMMIT_INTERVAL Data type: INTEGER; Nullable: Yes

How often, in seconds, the Capture program commits data to the Capture control tables, including the UOW and CD tables. This value should be less than the Db2® lockout value to prevent contention between the Capture and pruning threads.

PRUNE_INTERVAL Data type: INTEGER; Nullable: Yes

How often, in seconds, the Capture program automatically prunes (AUTOPRUNE = Y) rows in the CD, UOW, signal, trace, and Capture monitor tables that are no longer needed. A lower prune interval saves space, but increases processing costs. A higher prune interval requires more CD and UOW table space, but decreases processing costs.

TRACE_LIMIT Data type: INTEGER; Nullable: Yes

The number of minutes that rows remain in the IBMSNAP_CAPTRACE table before they are eligible for pruning. During the pruning process, the rows in the Capture trace table are pruned if the number of minutes (current timestamp - the time a row was inserted in the Capture trace table) exceeds the value of TRACE_LIMIT.

MONITOR_LIMIT Data type: INTEGER; Nullable: Yes

The number of minutes that rows remain in the IBMSNAP_CAPMON table before they are eligible for pruning. During the pruning process, rows in the Capture monitor table are pruned if the value of minutes (current timestamp - MONITOR_TIME) exceeds the value of MONITOR_LIMIT.

MONITOR_INTERVAL Data type: INTEGER; Nullable: Yes

How often, in seconds, that the monitor thread adds a row to the Capture monitor IBMSNAP_CAPMON table. For Capture for System i®, enter an interval greater than 120 seconds.

MEMORY_LIMIT Data type: SMALLINT; Nullable: Yes

The amount of memory, in megabytes, that the Capture program is allowed to use. After this allocation is used up, memory transactions will spill to a file.

REMOTE_SRC_SERVER Data type: CHAR(18); Nullable: Yes

Reserved for future options of SQL Replication. Currently this column contains the default value of null.

AUTOPRUNE Data type: CHAR(1); Nullable: Yes
A flag that indicates whether the Capture program automatically prunes rows that are no longer needed from the CD, UOW, signal, trace, and Capture monitor tables:
Y
Autopruning is on.
N
Autopruning is off.
TERM Data type: CHAR(1); Nullable: Yes
A flag that indicates whether the Capture program terminates when Db2 is quiesced or stopped:
Y
The Capture program terminates when Db2 is quiesced or stopped.
N
The Capture program stays active and waits for Db2 to be restarted or unquiesced.
AUTOSTOP Data type: CHAR(1); Nullable: Yes
A flag that indicates whether the Capture program stops capturing changes as soon as it reaches the end of the active logs:
Y
The Capture program stops as soon as it reaches the end of the active logs.
N
The Capture program continues running when it reaches the end of the active logs.
LOGREUSE Data type: CHAR(1); Nullable: Yes
A flag that indicates whether the Capture program overwrites the Capture log file or appends to it.
Y
The Capture program reuses the log file by first deleting it and then recreating it when the Capture program is restarted.
N
The Capture program appends new information to the Capture log file.
LOGSTDOUT Data type: CHAR(1); Nullable: Yes
A flag that indicates where the Capture program directs the log file messages:
Y
The Capture program directs log file messages to both the standard out (STDOUT) and the log file.
N
The Capture program directs most log file messages to the log file only. Initialization messages go to both the standard out (STDOUT) and the log file.

SLEEP_INTERVAL (z/OS®, Linux®, UNIX, Windows)

Data type: SMALLINT; Nullable: Yes

The number of seconds that the Capture program sleeps when it reaches the end of the active logs (in Linux, UNIX and Windows, or in z/OS non-data-sharing environments), or when an inefficient amount of data has been returned (in z/OS data-sharing environments).

CAPTURE_PATH Data type: VARCHAR(1040); Nullable: Yes

The path where the output from the Capture program is sent.

STARTMODE Data type: VARCHAR(10); Nullable: Yes
The processing procedure that the Capture program uses when it is started:
cold
The Capture program deletes all rows in its CD tables and UOW table during initialization. All subscriptions to these replication sources are fully refreshed during the next Apply processing cycle (that is, all data is copied from the source tables to the target tables). If the Capture program tries to cold start but you disabled full refresh, the Capture program will start but the Apply program will fail and will issue an error message.
warmsi
The Capture program warm starts; except if this is the first time you are starting the Capture program then it switches to a cold start. The warmsi start mode ensures that cold starts happen only when you initially start the Capture program.
warmns
The Capture program warm starts. If it can't warm start, it does not switch to cold start. The warmns start mode prevents cold starts from occurring unexpectedly and is useful when problems arise (such as unavailable databases or table spaces) that require repair and that prevent a warm start from proceeding. When the Capture program warm starts, it resumes processing where it ended. If errors occur after the Capture program started, the Capture program terminates and leaves all tables intact.
ARCH_LEVEL Data type: CHAR(4); Nullable: No

The version of the Capture control tables:

1021
Version 11.4 and 10.2.1
1001
Version 10.1 on Linux, UNIX, and Windows and Version 10.1 on z/OS with APAR PM75119 or higher
0973
Version 9.7 Fix Pack 3 on Linux, UNIX, and Windows
When you update the IBMSNAP_CAPPARMS table, do not change the value in this column.
COMPATIBILITY Data type: CHAR(4); Nullable: No, with default

Determines the length of log sequence numbers in the Capture control tables, CD tables, and UOW tables. The 16-byte log sequence numbers are used starting with Version 10.1 on Linux, UNIX, and Windows and Version 10.2.1 on z/OS

1021
16-byte log sequence numbers are used
1001
16-byte log sequence numbers are used on Linux, UNIX, and Windows
0801
10-byte log sequence numbers are used

The Apply program uses the value in this column to determine the length of log sequence numbers to use in its control tables and CCD target tables.

LOGRDBUFSZ Data type: INTEGER; Nullable: No, with default

Linux, UNIX, and Windows only: The size in KB of the buffer that the Capture program passes to Db2 when Capture retrieves log records. Db2 fills the buffer with available log records that Capture has not retrieved. Default: 66 KB.

LOG_COMMIT_INTERVAL Data type: INTEGER; Nullable: No, with default

Specifies an interval in seconds for how often the Capture log reader thread commits. The default is every 30 seconds. If you detect that Capture is creating contention with other DDL operations on the source database, you can shorten this value so that Capture commits, and releases any locks, more frequently.

WARNLOGAPI Data type: INTEGER; Nullable: No, with default

The number of milliseconds that the Capture program waits for the Db2 for z/OS instrumentation facility interface (IFI) or Db2 for Linux, UNIX, and Windows log read API to return log records before Capture prints a warning to the standard output. Default: 0.

STALE Data type: INTEGER; Nullable: No, with default

The number of seconds that the Capture program waits to issue a warning message or take other action after it detects a long-running transaction with no commit or rollback log record. On z/OS, Capture issues warning messages if has not seen a commit or rollback record for one hour (3600 seconds). On both z/OS and Linux, UNIX, and Windows, if a transaction has been running for the number of seconds that are specified in the STALE column and Capture did not see any row operations in the log for the transaction, it issues warning messages and increments the log sequence number that it considers to be the oldest "in-flight" transaction that was not committed or rolled back. If any rows were captured for the transaction, Capture only issues warning messages. Default: 3600.

WARNTXSZ Data type: INTEGER; Nullable: No, with default

Specifies whether the Capture program issues warning messages when it encounters transactions that are larger than a specified size. You provide a threshold value in megabytes, and transactions that exceed the threshold prompt a warning message. Capture issues multiple warning messages if the transaction size is a multiple of the WARNTXSZ value. For example, if you set WARNTXSZ to 10 MB and Capture encounters a 30 MB transaction, three warnings are issued (one for 10 MB, one for 20 MB, and one for 30 MB).

The default value of 0 MB means warnings are not issued.

USE_CAPCMD_TABLE Data type: CHAR(1); Nullable: No, with default

 A flag that tells the Capture program whether to read the IBMQREP_CAPCMD table for any commands to be processed.

N (default)
The Capture program does not read from the IBMQREP_CAPCMD table.
Y
The Capture program reads the IBMQREP_CAPCMD table every n milliseconds. The frequency is determined by the value in the CAPCMD_INTERVAL column.
CAPCMD_INTERVAL Data type: INTEGER; Nullable: No, with default

How frequently the Capture program reads the IBMQREP_CAPCMD table. The default is 3000 milliseconds and the minimum value is 1000 milliseconds.

INSERT_UOW Data type: CHAR(1); Nullable: No, with default

This option enables you to stop the Capture program from writing data to the IBMSNAP_UOW table. It can help you avoid large buildups of UOW data and reduce Capture overhead and unneeded insert processing and pruning, but should only be used when the UOW data is not needed by the Apply program.

Y (default)
Capture always writes to the IBMSNAP_UOW table when the replication configuration calls for UOW inserts (traditional behavior).
N
Capture does not write to the IBMSNAP_UOW table if the UOW data is not needed by SQL Apply. Capture checks the IBMSNAP_PRUNCNTL table and only allows this option if the TARGET_STRUCTURE column has a value of 8 (user copy ) or 9 (CCD table without a join of the IBMSNAP_UOW and CD tables). If there are any other types of TARGET_STRUCTURE, Capture stops with an error and you must restart Capture with INSERT_UOW=Y.

Capture alone cannot determine if the UOW table is needed or not. You must use INSERT_UOW=Y if you specified UOW_CD_PREDICATES or JOIN_UOW_CD in ASN.IBMSNAP_SUBS_MEMBR table. Also, MAX_SYNCH_MINUTES must be null for all subscription sets in the ASN.IBMSNAP_SUBS_SET table.

CAPSTART_REORGCHECK Data type: CHAR(1); Nullable: Yes, with default

A flag that specifies whether the Capture program checks to determine if a REORG of the source table is required before the table can be replicated.

Y (default for Db2 11 for z/OS)
Capture checks to determine if a REORG is required, and if it is required the registration is not started.
N (default for Db2 12 for z/OS)
Capture starts the registration without checking whether a REORG is required.

Starting with Db2 12, the log read API (IFI 306) returns the before and after values of a row update log record, both encoded in the version of the table at the time the log record is written. In Db2 11, the before value is encoded in the table version at the time of the insert until further updates or a REORG can be done. By returning the before value in the same format as the after value, Db2 12 removes the requirement for REORG of the table space before a registration is started for a table that was altered. This is true for a majority of cases but not all.

If Capture is behind in reading the Db2 logs and stopped, and if updates to the table are followed by a REORG of the table space, the registration fails with a decode error because Db2 cannot provide the before values in the current version and Capture did not record information about the old version because the registration was not active when the table was altered.

Recommendation: For Db2 12, you can change the default and specify CAPSTART_REORGCHECK=Y so that the REORG check is performed. If you specify CAPSTART_REORGCHECK=N and see the ASN0691E and ASN0748E messages with reason code 00C900A2 and Db2 secondary reason code 00C900B0, you must manually set the registration state to I and start the registration. These cases should be rare but are possible.
DROPTAB_ACTION Data type: CHAR(1); Nullable: No, with default

A flag that specifies the action that the Capture program takes when a table is dropped that is part of a registration. When a source table is dropped and recreated it can cause a mismatch between the values in the Db2 SYSIBM.SYSTABLES system catalog table and the IBMQREP_TABVERSION control table. This situation can lead to replication problems when other DDL changes are made to the source table. Specifying that the registration be deactivated (S) enables you to correct any problems before restarting replication.

W
(default) Takes no action.
S Stop
(deactivate) Stops the registration or subscription.
IFI_CONVERT_LOG_DATA Data type: CHAR(1); Nullable: Yes, with default NULL

z/OS only: IFI_CONVERT_LOG_DATA uses the IFI306 interface with the option to return both the before and after values of log records for UPDATE operations. Log record values are returned in the format of the table that exists when the UPDATE operation is run.

IFI_FILTER_PARTS Data type: CHAR(1); Nullable: Yes, with default NULL

z/OS only: Invokes the IFI306 log read interface with the IFI filtering by table space and partition range. The default setting is Y for V13, and N for V12.

IFI_FILTER Data type: INTEGER; Nullable: Yes, with default

z/OS only:When set Q Capture and SQL Capture uses Db2 for z/OS IFI306 filter for reading log records. In this log read mode, only the DMS log records for tables that are subscribed by the capture program are returned by Db2. This gives a significant performance boost, particularly if the replicated tablespaces are compressed, because the non-subscribed log records do not have to be decompressed. Reference for IFI_FILTER: IBM Support for IFI_FILTER and Qualification fields for READS requests

TRANS_COMMIT_MODE Data type: INTEGER; Nullable: Yes

TRANS_COMMIT_MODE=[1,2].

1 = Commit as soon as Capture sees phase 1 to 2 or begin of phase2, either of which mean that Db2 will not back out the transaction. This value was the default before APAR PH55478.

2 = Wait until Capture sees end phase 2, or end redo if Db2 crashes during phase 2 processing.

The default is 2 with APAR PH55478 and higher.