CDR_LOG_LAG_ACTION configuration parameter

Specifies how Enterprise Replication responds to a potential log wrap situation.

onconfig.std value
CDR_LOG_LAG_ACTION ddrblock
separators
+
range of values
See the Usage section.
takes effect
After you edit your onconfig file and restart the database server.
When you reset the value dynamically in your onconfig file by running the onmode -wf command.
When you reset the value in memory by running the onmode -wm command.

Usage

Use the CDR_LOG_LAG_ACTION configuration parameter to specify one or more actions, in priority order, that Enterprise Replication takes during a potential log wrap situation.

Read syntax diagramSkip visual syntax diagram
Syntax for the CDR_LOG_LAG_ACTION configuration parameter

>>-CDR_LOG_LAG_ACTION------------------------------------------->

>--+-+-logstage--+---------+-+--+-------------+-+--------------><
   | |           '-+--dlog-' |  +-+--ignore---+ |   
   | '-dlog--+-------------+-'  +-+--ddrblock-+ |   
   |         '-+--logstage-'    '-+--shutdown-' |   
   '-+-ignore---+-------------------------------'   
     +-ddrblock-+                                   
     '-shutdown-'                                   

Table 1. Options for the CDR_LOG_LAG_ACTION configuration parameter value
Option Description
logstage Enables compressed logical log staging.

The following configuration parameters must also be set:

  • The LOG_STAGING_DIR configuration parameter must be set to a directory. The directory specified by the LOG_STAGING_DIR configuration parameter must be secure. The directory must be owned by user informix, must belong to group informix, and must not have public read, write, or execute permission.
  • The CDR_LOG_STAGING_MAXSIZE configuration parameter must be set to a positive number.

Log files are staged in the directory specified by the LOG_STAGING_DIR configuration parameter, until the maximum size specified by the CDR_LOG_STAGING_MAXSIZE configuration parameter is reached. The staged log files are deleted after advancing the log replay position.

If the amount of disk space specified by the CDR_LOG_STAGING_MAXSIZE configuration parameter is exceeded, event alarm 30005 is raised.

If log staging is configured, Enterprise Replication monitors the log lag state and stages log files even when Enterprise Replication is inactive.

dlog Enables the dynamic addition of logical logs. The following configuration parameters must be set:
  • The CDR_MAX_DYNAMIC_LOGS configuration parameter must be set to -1 or a positive number.
  • The DYNAMIC_LOGS configuration parameter must be set to 2.
ignore Ignore the potential for log wrapping. The Enterprise Replication replay position might be overrun. If the replay position is overrun, event alarm 30 is raised. Restart Enterprise Replication using the cdr cleanstart command and synchronize the data.

The ignore option must be the only or the last option.

If the snoopy log position overrun is detected, Enterprise Replication shuts down with event alarm 47005.

ddrblock Default. Block client applications update activity.

The ddrblock option must be the only or the last option.

shutdown

Shut down Enterprise Replication on the affected server. If replay position overrun is detected, restart Enterprise Replication using the cdr cleanstart command and synchronize the data. If the replay position was not overrun, restart Enterprise Replication using the cdr start command; there is no need to synchronize the data. If replay position overrun is detected and the cdr start command fails with error code 214 and raises event alarm class 75, restart Enterprise Replication using the cdr cleanstart command and synchronize the data.

The shutdown option must be the only or the last option.

If a log lag state is detected, Enterprise Replication is shut down and event alarm ID 47006 is raised.

Staged log file format

Enterprise Replication creates a directory named: ifmxddrlog_SERVERNUM in the directory specified by the LOG_STAGING_DIR configuration parameter. Log file names are in the following format:
ifmxERDDRBLOCKUniqueLog_lf_used_loguniqueid.dat
Enterprise Replication also creates an empty token file for each staged log file. The token file is used to detect log files that are only partially written. If a token file is not found then Enterprise Replication treats the staged log file as partially written log file and deletes it. The token log file format is:
ifmxERDDRBLOCKUniqueLog_lf_used_loguniqueid

Transferring log files to a high-availability cluster secondary server when using ER

If your configuration consists of an HDR, RSS, or SDS secondary server configured as an Enterprise Replication node, transfer staged log files to the secondary server using the alarm program script. The staged log files are required by Enterprise Replication in case the primary server in a high-availability cluster fails and a secondary server takes over the role of the primary server.

Enterprise Replication raises alarm class ID 30 and unique ID 30006 when a log is staged to the log staging directory. Enterprise Replication raises alarm class ID 30 and unique ID 30007 after deleting a staged log file. Using these alarms, you can automate the transfer of staged log files to the high-availability cluster secondary server using the alarm program script.

Ensure that the directory under the directory specified the LOG_STAGING_DIR configuration parameter exists and is named using the format ifmxddrlog_SERVERNUM. The script copies the staged log files to ifmxddrlog_SERVERNUM and creates a token log file after copying the staged log file.

Example

Suppose that you want Enterprise Replication to handle potential log wrap situations by first staging compressed logs until they reach 1 MB in size, then dynamically add up to two logical logs, and then block user transactions. Set the following configuration parameters:

CDR_LOG_LAG_ACTION      logstage+dlog+ddrblock
LOG_STAGING_DIR         $INFORMIXDIR/tmp
CDR_LOG_STAGING_MAXSIZE 1MB
CDR_MAX_DYNAMIC_LOGS    2
DYNAMIC_LOGS            2

Copyright© 2019 HCL Technologies Limited