memory_limit parameter

The memory_limit parameter specifies the amount of memory that a Q Capture program can use to build transactions in memory.

On z/OS®, the default value of 0 causes the Q Capture program to calculate a memory allocation that is based on the Q Capture region size in the JCL or started task. The default value of 500 MB on Linux®, UNIX, and Windows is sufficient for most workloads.

You might need to increase the memory limit if the Q Capture program is spilling transactions to disk or virtual I/O. Ideally, the Q Capture program should never need to spill transactions. If the TRANS_SPILLED column in the IBMQREP_CAPMON table has a value greater than 0 (you can also view this value in the Q Capture Throughput window in the Replication Center), try increasing the memory limit.

For large transactions or batch processing, you might need to increase the memory limit or lower the commit interval to avoid spilling. You can dynamically increase these parameters while the Q Capture program is running. You can then return these values to their previous settings to avoid excessive memory allocation or CPU consumption after the batch is processed.

The maximum allowed value for the memory_limit parameter is 100 GB.

Determining minimum memory requirement

In some cases you might want to reduce the amount of memory that a Q Capture program uses but still avoid spilling to disk (for example, in environments with low volume or small transactions). To determine the minimum amount of memory that you need, you can use the following formula. The formula is based on the concept that the memory required at any given time is equal to the number of transactions that are being processed multiplied by the size of each transaction. The formula uses statistics from the IBMQREP_CAPMON table:

memory_limit >= (1.25 * MAX(MAX_TRANS_SIZE) * (MAX(TRANS_PROCESSED) /  (monitor_interval / 1000 ))
* (commit_interval / 1000) ) / (1024 * 1024)

Where:

MAX(MAX_TRANS_SIZE)
The largest value that is recorded in the MAX_TRANS_SIZE column (the largest transaction that the Q Capture program processed).
MAX(TRANS_PROCESSED)
The largest value that is recorded in the TRANS_PROCESSED column (the most transactions that the Q Capture program processed).

You can find the runtime values of the commit_interval and monitor_interval parameters by using the qryparms parameter with the MODIFY or asnqccmd commands.

You can modify the safety factor of 1.25 if your past workload is not a good predictor of your future workload.