Tuesday, August 11, 2009

How to validate RMAN backup

The main purpose is to check for corrupt blocks and missing files.

There are two types of corruptions
1. Physical corruption
2. Logical corruption

In physical corruption/media corruption, the database does not recognize the block at all and the checksum is invalid.

In a logical corruption, the contents of the block are logically inconsistent. By default RMAN doesn’t check for logical corruption. Use “CHECK LOGICAL” with BACKUP or RESTORE command to check for logical and physical corruption using RMAN.

It’s advised to set DB_BLOCK_CHECKSUM=typical in the initialization parameter file of a database, set so that the database calculates datafile checksums automatically (not for backups). The BACKUP command computes checksum for each block and stores it in the backup. If you specify NOCHECKSUM while creating backup then RMAN does not perform a checksum of the blocks.

Note that Automatic Diagnostic Repository (ADR) tracks all types of corruptions.

VALIDATE:-
Run below command to validate Database
RMAN> VALIDATE DATABASE;

Run below command to validate Backup set
RMAN> VALIDATE BACKUPSET 10;

Run below command to validate individual data blocks within a data file for block corruption
RMAN> VALIDATE DATAFILE 1 BLOCK 10;

Click here for Block recovery using RMAN.

BACKUP VALIDATE:-
Use BACKUP VALIDATE to check datafile logical/physical corruptions and check all database files exists in correct location. Do not use the BACKUPSET, MAXCORRUPT, or PROXY parameters with BACKUP VALIDATE.

Run below command to validate all database files and archived logs. This command checks for physical corruptions only.
RMAN> BACKUP VALIDATE DATABASE ARCHIVELOG ALL;

Run below command to check for logical corruptions and physical corruptions.
RMAN> BACKUP VALIDATE CHECK LOGICAL DATABASE ARCHIVELOG ALL;

Click here to Validate restore using RMAN.

Regards,
Satishbabu Gunukula
http://www.oracleracexpert.com/

9 comments:

  1. This comment has been removed by the author.

    ReplyDelete
  2. Thanks for this wonderful information. You posts are really nice and interesting. Writing style is also very amazing200 Words Independence Day Essay For Students in Malayalam 2018

    ReplyDelete
  3. This comment has been removed by a blog administrator.

    ReplyDelete
  4. Thank you for your post. This is excellent information. It is amazing and wonderful to visit your site
    RAC Training in Bangalore

    ReplyDelete
  5. This blog very easily understandable. Thanks for sharing such an informative post with us. This is a nice post in an interesting line of content.
    RAC Training in Bangalore

    ReplyDelete