Knowledge Base: Backup : Backup / restore of DB2 database servers
 
Backup / restore of DB2 database servers
Creation Date: December 24, 2004
Revision Date: March 27, 2015
Product: DS‑Client (LINUX)
Backup / restore of DB2 database servers (Linux DS-Client)
The following requirements must be met to perform backup / restore of DB2 Database Servers.
General Requirements:
The user who performs DB2 backup and restore should have knowledge about the DB2 database structure and instance management.
The DB Administrator / Backup Operator must catalog the remote node and database name before creating a new backup set. You cannot browse the database(s) for names, therefore you must have the exact name. Restores must also catalog the remote node and database name prior to running the (restore) process.
The credentials used for backup / restore of the DB2 database must have the SYSADM, SYSCTRL, or SYSMAINT authority.
The account used to connect to the DB2 Client Instance must exist on the DS-Client computer. This is the user specified in the “Ask for database credentials” of the DB2 backup set (Backup Set Properties > Connection Options).
DS-Client computer requirements:
DB2 Client should be installed on the machine running the DS-Client. This DB2 Client must be the same version as the DB2 Servers being backed up.
Specify the DB2 Client library directory on DS-Client. This is done in the DS-Client Configuration dialog box’s Advanced Tab (see “Configuring the advanced settings”):
1. On the Setup menu, click Configuration.
2. In the DS-Client Configuration dialog box, click Advanced.
3. In the Category box, select Miscellaneous.
4. In the Parameter box, select DB2 Client Library Directory.
5. In the Value box, enter the path where the DB2 Client libraries are located on the DS-Client.
6. Click Apply.
7. Stop and start the DS-Client daemon.
The DB2 node and database must be cataloged so that the DB2 client can connect to each DB2 server you want to back up or restore.
DB2 server requirements:
DB2 Server should be a certified product.
You must ensure that the TCP/IP Service name is properly represented in the DB2 instance configuration file; otherwise, you can encounter errors when creating a DB2 database backup set.
1. Open the DB2 instance configuration file.
2. Ensure that the parameter SVCENAME is set to the appropriate service name, corresponding to the correct port number.
Backup requirements
The DB2 database must not be in use when you perform an off-line backup, otherwise an error will be reported.
When you create a DB2 backup set, in the Select the source for this backup set dialog box, specify the DB2 server hostname or type its IP address in the Path box. This must be the same as the one used in the catalog command.
Linux DS-Client should have read and write privileges to access the transaction log directory on the DB2 database computer (for example ~db2inst1/db2inst1/NODE0000/SQL00005/SQLOGDIR/).
Online backups are available only for databases configured with the “logarchmeth1” value set to either logretain or userexit.
The backup set must specify that the backup is online or off-line, as determined by the DB2 database configuration settings. (DO NOT CHANGE THIS PROPERTY. If you change this DB2 configuration, make a new backup set with the new option setting.)
It is recommended not to change the online option setting for a demand backup. If it is changed, you must make a record of the change and the date (manually on paper or other format), so that the information is available if a restore is performed.
Restore requirements
The DB2 database must not be in use when you perform the restore. This requirement applies to all DB2 backup sets (whether configured for online or off-line backup).
The DB2 database must be configured for online or off-line restore. This setting must match the Backup Set Properties > Options setting that was used for the backup.
The user ID of the calling application or process is used for client-side authorization. More details are available at the following links:
http://publib.boulder.ibm.com/infocenter/db2luw/v9r7/topic/com.ibm.db2.luw.apdv.api.doc/doc/r0001446.html
http://publib.boulder.ibm.com/infocenter/db2luw/v9r7/topic/com.ibm.db2.luw.apdv.api.doc/doc/r0001458.html