Skip Headers
Oracle® Database Backup and Recovery Reference
10g Release 2 (10.2)

Part Number B14194-03
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

REPORT

Syntax

report::=

Description of report.gif follows
Description of the illustration report.gif

reportObject::=

Description of reportobject.gif follows
Description of the illustration reportobject.gif

atClause::=

Description of atclause.gif follows
Description of the illustration atclause.gif

Purpose

To perform detailed analyses of the RMAN repository. The Database writes the output from the REPORT command to standard output or the message log file.

Use the REPORT command to answer questions such as the following:

Restrictions and Usage Notes

Keywords and Parameters

report

Syntax Element Description
NEED BACKUP Lists all datafiles in need of a new backup. The report assumes that you will use the most recent backup for restore operations. If you do not specify any option, then RMAN uses the current retention policy configuration. If the retention policy is disabled (CONFIGURE RETENTION POLICY TO NONE), RMAN generates an error.
DAYS = integer Lists all datafiles requiring more than the specified number of days' worth of archived redo log files for complete recovery. For example, REPORT NEED BACKUP DAYS 7 DATABASE shows the datafiles whose recovery requires more than seven days' worth of archived redo logs.

If the target database control file is mounted and current, then RMAN makes the following optimizations to this report:

  • Files that are offline and whose most recent backup contains all changes to the file are not included.

  • Files that were offline and are now online, and whose most recent backup contains all changes up to the offline time, are only reported if they have been online for more than the specified number of days.

INCREMENTAL = integer Specifies a threshold number of incremental backups required for recovery. If complete recovery of a datafile requires more than integer incremental backups, then the datafile requires a new full backup.

Note: Files for which no backups exist will not appear in this list: issue the REPORT NEED BACKUP REDUNDANCY command to display them.

RECOVERY WINDOW OF integer DAYS Reports datafiles for which there are not sufficient backups to satisfy a recovery window-based retention policy for the specified number of days, that is, datafiles without sufficient backups for point-in-time recovery to any point back to the time SYSDATE - integer.
REDUNDANCY = integer Specifies the minimum number of backups or copies that must exist for a datafile to be considered not in need of a backup. In other words, a datafile needs a backup if there are fewer than integer backups or copies of this file. For example, REDUNDANCY 2 means that if there are fewer than two copies or backups of a datafile, then it needs a new backup.
OBSOLETE obsOperandList Lists full backups, datafile copies, and archived logs recorded in the RMAN repository that can be deleted because they are no longer needed. The subclause obsOperandList describes the criteria that RMAN uses to determine what is obsolete. If you do not specify parameters in obsOperandList, then RMAN uses the options specified in CONFIGURE RETENTION POLICY. If you use this option in conjunction with DEVICE TYPE, then RMAN only considers backups and copies created on the specified device.

Note: Even if you use a KEEP UNTIL clause to specify a time after which a backup is to be considered obsolete, RMAN does not consider that backup obsolete if it is needed to satisfy the specified retention policy. A KEEPUNTIL clause can cause a backup to be kept longer than the retention policy requires, but never a shorter time.

SCHEMA Lists the names of all datafiles and tablespaces at the specified point in time.
UNRECOVERABLE Lists all unrecoverable datafiles. A datafile is considered unrecoverable if an unrecoverable operation has been performed against an object residing in the datafile since the last backup of the datafile.

Note: The nonexistence of any backup of a datafile is not sufficient reason to consider it unrecoverable. Such datafiles can be recovered through the use of the CREATE DATAFILE command, if redo logs starting from when the file was created still exist.

DEVICE TYPE deviceSpecifier Specifies the type of storage device. RMAN only considers backups and copies available on the specified device for its report.

reportObject

Syntax Element Description
reportObject Specifies the datafiles to be included in the report. The report can include the entire database (optionally skipping certain tablespaces), a list of tablespaces, or a list of datafiles.

Note: RMAN includes objects from prior incarnations.

DATAFILE datafileSpec Lists the specified datafiles. RMAN reports on backups or datafile copies that contain at least one of the specified datafiles.
TABLESPACE 'tablespace_name' Lists datafiles in the specified tablespace. RMAN reports on backups or datafile copies that include at least one datafile from a specified tablespace.
DATABASE Lists backups or datafile copies of all files in the current database. Specify SKIP TABLESPACE tablespace_name to exclude the specified tablespace from the DATABASE specification.

atClause

Syntax Element Description
atClause Specifies a point in time as a time, an SCN, or a log sequence number.
AT TIME = 'date_string' Specifies a date. The NLS_LANG and NLS_DATE_FORMAT environment variables specify the format for the time.
AT SCN = integer Specifies an SCN.
AT SEQUENCE = integer THREAD = integer Specifies a log sequence number for a specified redo THREAD number. The integer indicates the time when the specified log and thread were first opened.

Report Output

The information that appears in the output is described in the following tables:

Table 2-21 Report of Database Schema

Column Indicates

File

The absolute datafile number.

K-bytes

The size of the file in kilobytes.

Tablespace

The tablespace name.

RB segs

For datafiles only. YES if rollback segments exist in the tablespace and NO if they do not (only if connected to the recovery catalog). If RMAN is not connected to the catalog, then *** is displayed.

Datafile Name

For datafiles only. The filename of the datafile.

Maxsize (MB) Name

For tempfiles only. The maximum size of the tempfile.

Tempfile Name

For tempfiles only. The filename of the tempfile.


Table 2-22 Report of Obsolete Backups and Copies

Column Indicates

Type

Whether the object is a backup set, backup piece, proxy copy, or datafile copy.

Key

A unique key that identifies this backup in the target database control file.

Completion Time

The time that the backup or copy completed.

Filename/handle

The filename or media handle of the backup or datafile copy.


Table 2-23 Report of Files that Need Backup Due to Unrecoverable Operations

Column Indicates

File

The absolute number of the datafile that needs a new backup due to unrecoverable operations.

Type Of Backup Required

FULL or INCREMENTAL, depending on which type of backup is necessary to ensure the recoverability of all of the data in this file. If FULL, then create a full backup, level 0 backup, or a datafile copy. If INCREMENTAL, then a full or incremental backup will also suffice.

Name

The name of the datafile.


Table 2-24 Report of Files with Fewer Than n Redundant Backups

Column Indicates

File

The absolute datafile number of a datafile with less than n redundant backups.

#bkps

The number of backups that exist for this file.

Name

The name of the file.


Table 2-25 Report of Files Whose Recovery Needs More Than n Days of Archived Logs

Column Indicates

File

The absolute file number of a datafile that requires more than n days of archived redo logs for recovery.

Days

The number of days of archived redo data required for recovery.

Name

The name of the datafile.


Table 2-26 Report of Files That Need More than n Incrementals During Recovery

Column Indicates

File

The absolute file number of a datafile that requires more than n incrementals for complete recovery.

Incrementals

The number of incremental backups required for complete recovery.

Name

The name of the datafile.


Examples

Reporting Database Schema: Example This example, which requires a recovery catalog, reports the names of all datafiles and tablespaces one week ago:

REPORT SCHEMA AT TIME 'SYSDATE-7';

Report of database schema
File K-bytes    Tablespace           RB segs Datafile Name
---- ---------- -------------------- ------- -------------------
1        307200 SYSTEM               ***     /oracle/oradata/trgt/system01.dbf
2         20480 UNDOTBS              ***     /oracle/oradata/trgt/undotbs01.dbf
3         10240 CWMLITE              ***     /oracle/oradata/trgt/cwmlite01.dbf
4         10240 DRSYS                ***     /oracle/oradata/trgt/drsys01.dbf
5         10240 EXAMPLE              ***     /oracle/oradata/trgt/example01.dbf
6         10240 INDX                 ***     /oracle/oradata/trgt/indx01.dbf
7         10240 TOOLS                ***     /oracle/oradata/trgt/tools01.dbf
8         10240 USERS                ***     /oracle/oradata/trgt/users01.dbf

Reporting Datafiles Needing Incremental Backups: Example This example reports all datafiles in the database that require the application of five or more incremental backups to be recovered to their current state:

REPORT NEED BACKUP INCREMENTAL 5 DATABASE;

Report of files that need more than 5 incrementals during recovery
File Incrementals Name
---- ------------ ----------------------------------------------
2    9            /oracle/oradata/trgt/undotbs01.dbf
3    9            /oracle/oradata/trgt/cwmlite01.dbf
4    9            /oracle/oradata/trgt/drsys01.dbf

Reporting Datafiles Needing Backups: Example The following example reports all datafiles from tablespace SYSTEM that will need more than two days of archived redo logs to be applied during recovery after being restored from the most recent backup:

REPORT NEED BACKUP DAYS 2 TABLESPACE SYSTEM; 

Report of files whose recovery needs more than 2 days of archived logs
File Days  Name
---- ----- -----------------------------------------------------
1    3     /oracle/oradata/trgt/drsys01.dbf.f

Reporting Unrecoverable Datafiles: Example The following example reports all datafiles that cannot be recovered from existing backups because redo may be missing:

REPORT UNRECOVERABLE;

Report of files that need backup due to unrecoverable operations
File Type of Backup Required Name
---- ----------------------- -----------------------------------
1    full                    /oracle/oradata/trgt/system01.dbf

Reporting Obsolete Backups and Copies: Example The following example reports obsolete backups and copies with a redundancy of 1:

REPORT OBSOLETE;

Report of obsolete backups and copies
Type                 Key    Completion Time    Filename/Handle
-------------------- ------ ------------------ --------------------
Backup Set           1      OCT 30 2001 15:54:56
  Backup Piece       1      OCT 30 2001 15:54:56 /oracle/dbs/01d7t0t9_1_1
Archive Log          1      OCT 30 2001 04:52:17 /oracle/oradata/trgt/arch/archive1_21.dbf