Backup CATALOG简析(四)

2014-11-24 16:49:33 · 作者: · 浏览: 1
dia manager to make offsite backups available.
RESTORE ARCHIVELOG ALL PREVIEW RECALL
Restore point
=============
SELECT NAME, SCN, TIME, DATABASE_INCARNATION#,
GUARANTEE_FLASHBACK_DATABASE, STORAGE_SIZE
FROM V$RESTORE_POINT
WHERE GUARANTEE_FLASHBACK_DATABASE='YES';
REPORT used to determine whether your database is recoverable are
=================================================================
REPORT NEED BACKUP [redundancy n | recovery window of n days]
Reports which database files require backup because they have been
affected by some NOLOGGING operation such as a direct-path INSERT
==================================================================
REPORT UNRECOVERABLE
REPORT SCHEMA
Displays files that require more than n days' worth of archived redo log files for recovery.
REPORT NEED BACKUP DAYS n
REPORT NEED BACKUP INCREMENTAL n
REPORT NEED BACKUP REDUNDANCY 2 DATAFILE 1;
report need backup device type tap;
To report obsolete backups
==========================
CROSSCHECK BACKUP DEVICE TYPE sbt;
CROSSCHECK BACKUP; # crosshecks all backups on all devices
REPORT OBSOLETE;
REPORT OBSOLETE RECOVERY WINDOW OF 3 DAYS;
To query details about past and current RMAN jobs
=================================================
for information about the backup type, status, and start and end time
---------------------------------------------------------------------
COL STATUS FORMAT a9
COL hrs FORMAT 999.99
SELECT SESSION_KEY, INPUT_TYPE, STATUS,
TO_CHAR(START_TIME,'mm/dd/yy hh24:mi') start_time,
TO_CHAR(END_TIME,'mm/dd/yy hh24:mi') end_time,
ELAPSED_SECONDS/3600 hrs
FROM V$RMAN_BACKUP_JOB_DETAILS
ORDER BY SESSION_KEY;
for the rate of backup jobs in an RMAN session
----------------------------------------------
COL in_sec FORMAT a10
COL out_sec FORMAT a10
COL TIME_TAKEN_DISPLAY FORMAT a10
SELECT SESSION_KEY,
OPTIMIZED,
COMPRESSION_RATIO,
INPUT_BYTES_PER_SEC_DISPLAY in_sec,
OUTPUT_BYTES_PER_SEC_DISPLAY out_sec,
TIME_TAKEN_DISPLAY
FROM V$RMAN_BACKUP_JOB_DETAILS
ORDER BY SESSION_KEY;
for the size of the backups in an RMAN session
----------------------------------------------
COL in_size FORMAT a10
COL out_size FORMAT a10
SELECT SESSION_KEY,
INPUT_TYPE,
COMPRESSION_RATIO,
INPUT_BYTES_DISPLAY in_size,
OUTPUT_BYTES_DISPLAY out_size
FROM V$RMAN_BACKUP_JOB_DETAILS
ORDER BY SESSION_KEY;
Unique Identifiers for Registered Databases
===========================================
Most recovery catalog views contain the columns DB_KEY and DBINC_KEY. Each database registered in the recovery catalog can be uniquely identified by either the primary key, which is the DB_KEY column value, or the DBID, which is the 32-bit unique database identifier. Each incarnation of a database is uniquely identified by the DBINC_KEY column.