Tuesday, July 21, 2009

Chapter 17 Performing Database Recovery

Overview of Data Recovery Advisor
all copies of the controlfile must be valid. If not, instance abort. Startup reach nomount mode only.

Damage to any controlfile copy will abort the instance immediately. It will not be possible to mount the database until the problem has been fixed.

Check v$controlfile to see if controlfile is multiplexing. If not, include a new copy in the nomount mode using ALTER SYSTEM SET CONTROL_FILES='controlfiles list' SCOPE=SPFILE.

If all members of a online redo log file group are lost, then instance abort. Startup reach mount mode only.

Check v$logfile to see if online redo log file group is multiplexing. If not, add a new member in the open mode using ALTER DATABASE ADD LOGFILE MEMBER 'newlogfile01A.log' TO GROUP 1.

To repair a damaged member: (simplest technique)
ALTER DATABASE CLEAR LOGFILE GROUP n;

If the log file group is current, active, or unarchived, then CLEAR will fail.
ALTER SYSTEM SWITCH LOGFILE;
ALTER SYSTEM CHECKPOINT;
ALTER SYSTEM ARCHIVE LOG ALL;

In noarchivelog mode, there can be no concept of recovery, the only restore possible is of the whole database.
ALTER DATABASE OPEN RESETLOGS;

SYSTEM and UNDO tablespaces are critical, if any of these datafiles is damage, then instance abort. Startup reach mount mode only.

If other tablespace are non-critical, then they are taken offline automatically while database open. Startup reach mount mode and they must be taken offline manually before database can be opened. During offline period, tables and indexes in the tablespace are unusuable.

Health Monitor:
Use ADR as repository located in the directory specified by DIAGNOSTIC_DEST.

In nomount mode:
only the "DB Structure Integrity Check"
In mount mode:
"DB Structure Integrity Check" and "Redo Integrity Check"
In open mode:
"Data Block Integerity Check", "Undo Segment Integrity Check", "Dictionary Integrity Check"


Checkers in Database Control or DBMS_HM PL/SQL package.

DRA must be in at least nomount mode and only supports single-instance database.


Use Data Recovery Advisor to Perform Recovery (Control File, Redo Log File, and Data File)
list failure;
advise failure;
repair failure;

No comments:

Post a Comment