How to recover corrupted DB2 database by using backup
DB2 Database is a Relational Database Management System (RDBMS) which is developed by IBM. It is loaded with lots of feature via which users can store and manipulate large amount of data. It can perform any operation on data in a very efficient way. It also protects your data, reduce unauthorized entry, and reduce data redundancy. DB2 data file is used by many company and industries for the backend support for storing a large amount of data in a very organized way. DB2 database is also prone to corruption. You have 2 types of backup to recover the corrupted DB2 Database i.e.: Offline & Online.
How to take offline backup:
DB2 Database doesn’t take the backup of physical files that make up your tablespaces and database. It provides DB2 a lot more flexibility while restoring it.
To backup the db2 database use backup command:
“DB2 BACKUP DATABASE db_name TO device_or_directory“
It is the simplest form that can back up all tablespaces in database named as db_name to directory or device.
You don’t even have to backup full database. You can backup full set of tablespaces or can backup single tablespace.
While use tablespace level backups:
To perform the tablespace level to restore don’t use the tablespace level backups. Now you ahev use only the tablespace backups if you don’t have enough time or space for the full database backup.
For tablespace level backups just by add this command:
“ TABLESPACE ( tablespace_name, tablespace_name) “
Write those tablespace(s) in the parenthesis which you want to have the backup and DB2 will backup those objects.
How to perform online backup:
To perform the online backup simply add “ONLINE” to above backup command. Before taking the online backup just remember that you should be archiving the log files. You can’t use the circular logging.
So you can even recover the corrupted DB2 Database by using the offline backup or Online backup. It can even happen if you maintain the backup: Offline or Online.
But if you don’t have the backup than move with the third party DB2 Repair Tool. This tool is very easy to use for recovering the corrupted DB2 Database. It does not provide any limitation and easily recover the database in almost every possible causes of corruption. It automatically detects corrupt DB2 and recovers all of them. It efficiently repair large size database easily and effectively, user friendly and easy to use.
How to recover corrupted DB2 database:
Step 1: Download, Install and Run DB2 File Repair software. It will provides two options to repair db2 file, first option is for if the database is attached to DB2, then you can select the option ‘Repair the database stored at default location‘, and if the database is not attached to DB2 then choose the manual selection of database.
Step 2: It will provide you the list of database attached to DB2. Select the particular database you want to repair and recover corresponding database objects.
Step 3: In this step this tool provide the list of recoverable database files. You can see the preview by clicking on it.
Step 4: Give the path location for the recoverable database and its object to be saved. Click on ‘Ok’ button.
249 Total Views 2 Views Today