Db2 Mirror properties

There are properties within Db2® Mirror which will affect characteristics of the replication environment.

The properties can be viewed and changed on the Db2 Mirror GUI by clicking the Management icon on the left side and choosing Mirror Properties.

Figure 1. Selecting Mirror Properties using the Db2 Mirror GUI
Selecting Mirror Properties using the Db2 Mirror GUI

Automatic resume

Automatic resume determines whether SYSBAS or a database IASP will resume automatically after a system initiated suspend. The value is set separately for SYSBAS and each registered database IASP. The default value is YES.

The automatic resume setting can be changed using the Db2 Mirror GUI under the Replication tab in Mirror Properties, as shown in the following figure.

Figure 2. Change replication properties using the Db2 Mirror GUI
Change replication properties using the Db2 Mirror GUI

The QSYS2.CHANGE_MIRROR procedure can also be used to set the automatic resume value.

CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', AUTO_RESUME => 'YES');

For more information about the automatic resume property, see Automatic resume.

Parallel degree

The parallel degree setting specifies the maximum degree of parallelism that can be used for Db2 Mirror resynchronization processing. Increasing the parallelism can potentially reduce the time required for resynchronization. The default value is NONE. The Db2 Symmetric Multiprocessing (SMP) priced option (5770SS1 Option 26) is required to set the value between 2 and 256.

The value is set separately for SYSBAS and each registered database IASP. The value is also set separately for each node.

Changing the parallel degree setting will not affect any resynchronization that is currently active. The current value will be checked and used when a new resynchronization begins.

The parallel degree setting can be changed using the Db2 Mirror GUI under the Replication tab in Mirror Properties, as shown in Figure 2.

The QSYS2.CHANGE_MIRROR procedure can also be used to set the parallel degree.

CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', PARALLEL_DEGREE => 10);

Spooled file resynchronization interval

Spooled file replication is done on an interval basis. At a regular interval, a spool server job will look at all replicated output queues for spooled files which have been closed within the interval. These spooled files will be sent to the other node if the replication state is ACTIVE or added to the OTL if the replication state is TRACKING or BLOCKED.

The spooled file resynchronization interval can be set to any value from a minimum of 1 second to a maximum of 3600 seconds (60 minutes). The default value is 10 seconds. The optimal value is dependent on the environment. From a performance standpoint, it is recommended to set the value so that multiple spooled files are closed within the interval. The interval decision must also consider the need for current data on the target node.

SYSBAS and each registered database IASP have separate spooled file resynchronization interval settings. Each node in the Db2 Mirror pair is also set separately, as this could be based on the physical resources available on each node.

A change to the spooled file resynchronization interval setting will take effect when the current interval wait time is reached. For example, if the current interval setting is 600 seconds (10 minutes) and it is changed to 60 seconds, the current 10 minute interval will need to expire before the 60 second setting will take effect.

The spooled file resynchronization interval can be changed using the Db2 Mirror GUI under the Replication tab in Mirror Properties, as shown in Figure 2.

The QSYS2.CHANGE_MIRROR procedure can also be used to set the resynchronization interval.
CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', SPLF_RESYNC_INTERVAL => 60);

Automatic role swap for planned outages

The automatic role swap property determines whether a role swap will occur when a user initiates a Power Down System (PWRDWNSYS) or End System (ENDSYS), or goes into restricted state with End Subsystem (ENDSBS) with SBS(*ALL) on the current primary node. The default value is NO.

The setting can be changed using the Db2 Mirror GUI under the Swap tab in Mirror Properties, as shown in the following figure.

Figure 3. Change automatic role swap property
Change automatic role swap property
The QSYS2.CHANGE_MIRROR procedure can also be used to set the automatic role swap value. The IASP_NAME parameter does not apply to SWAP_ON_PWRDWNSYS and is ignored.
CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', SWAP_ON_PWRDWNSYS => 'YES');

Encrypted RDMA

Db2 Mirror requires encrypted RDMA protocols to be used by default. To allow Db2 Mirror to use non-encrypted RDMA protocols, your security administrator must change the Db2 Mirror encrypted RDMA setting to Not Required.

This setting can be viewed and changed using the Db2 Mirror GUI under the RDMA tab in Mirror Properties. If encryption is required, the setting will be displayed as shown in the following figure. Click Not Required to allow non-encrypted RDMA.

Figure 4. Encrypted RDMA is required
Encrypted RDMA is required

If encryption is not required, the setting will be displayed as shown in the following figure. Click Required to allow only encrypted RDMA.

Figure 5. Encrypted RDMA is not required
Encrypted RDMA is not required

Changing the encrypted RDMA setting requires each node to be suspended for maintenance and then resumed for the change to take effect. A confirmation dialog similar to the one shown in the following figure will appear. Click Yes to suspend for maintenance now.

Figure 6. Confirm suspending for maintenance
Confirm suspending for maintenance

The QSYS2.CHANGE_MIRROR procedure can be used to set the encrypted RDMA setting and suspend for maintenance.

CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', ENCRYPTED_RDMA => 'REQUIRED');
CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', REPLICATION_STATE => 'MAINTENANCE');
CALL QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', REPLICATION_STATE => 'RESUME);
CALL RMTNODE.QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', REPLICATION_STATE => 'MAINTENANCE');
CALL RMTNODE.QSYS2.CHANGE_MIRROR(IASP_NAME => '*SYSBAS', REPLICATION_STATE => 'RESUME');