This document describes the offline and online full backup, Incremental backup, and recovery operations for DB2 databases for your reference. DB2 provides high-level data availability, integrity, security, recoverability, and execution capabilities for small-scale to large-scale applications. It also has basic platform-independent functions and SQL commands.
1. Full offline backup
(1) first, make sure that no user uses DB2:
$ Db2 list applications for db sample
(2) Stop the database and restart it to disconnect all connections:
Db2stop force
Db2start
(3) run the BACKUP command: (use TSM as the backup media)
Db2 backup db sample use tsm
If the backup is successful, a timestamp is returned.
(4) check that the backup is successful:
Db2 list history backup all for sample. You can see that this backup record is missing.
The return value can also be seen in the Db2adutl query command.
(5) Remarks:
First, run the BACKUP command on the master node (the node where the catalog tablespace is located), and then perform this operation on other nodes.