IBM Support

Tracking DB2 data changes for an incremental backup

Question & Answer


Question

Is  it possible to avoid the delays that are seen for a DB2 incremental backup while the DB2 engine is searching for the changes?

Cause

For a DB2 delta/incremental type backup, the process will only send the data that has changed since the last full backup. This can witness delays in the sending of the data while the DB2 backup processing is looking thru the entire database to find the changes.

Answer

The TRACKMOD parameter for DB2 specifies whether modifications to the database are tracked.
  • If the DB2 trackmod parameter is not enabled, the entire database is scanned to check for any changes and significant delays may be seen while all the tablespaces are scanned.
  • If trackmod is enabled, the backup will be able to detect which tablespaces, within the database, need to be scanned for the incremental backup image.  This can reduce the time for an incremental backup as it only needs to scan the specific tablespaces which contain pages that have been changed, instead of searching thru the entire database for any changes.

To check which tablespaces will be scanned during the incremental backup processing, run the following DB2 command:

SELECT varchar(tbsp_name, 30) as tbsp_name,tbsp_trackmod_state,tbsp_type,pool_data_p_reads
FROM TABLE(MON_GET_TABLESPACE('',-2)) AS t
ORDER BY pool_data_p_reads DESC;

Those tablespaces marked as "Dirty" have pages which are changed since the last backup.

Depending on which tablespace have changes, the backup may still see delays as each tablespace is scanned for the pages that need to be backed up.  So although this trackmod setting may reduce the tablespaces that need to be checked, it may or may not reduce the delays as it searches for the changed data.  To accommodate the delays, the Idletimeout and Resourcetimeout values (for a LANFREE environment) and/or the commtimeout value (if it is a LAN backup) may need to be increased on the Spectrum Protect Server and StgAgent.

Note: After the DB2 cfg is updated to enable trackmod, it is mandatory for a Full DB2 backup to be performed.

[{"Product":{"code":"SSGSG7","label":"Tivoli Storage Manager"},"Business Unit":{"code":"BU058","label":"IBM Infrastructure w\/TPS"},"Component":"Client","Platform":[{"code":"PF025","label":"Platform Independent"}],"Version":"All Supported Versions","Edition":"Edition Independent","Line of Business":{"code":"LOB26","label":"Storage"}}]

Product Synonym

TSM

Document Information

Modified date:
11 March 2019

UID

swg21674268