RMAN Configuration Demystified: A Practical Deep Dive for DBAs – Part 3

RMAN Configuration Demystified: A Practical Deep Dive for DBAs – Part 3

LIST Commands:-

Command

Description

LIST BACKUP OF DATABASE;

Lists all backup sets (full, incremental, archivelogs) related to the entire database.

LIST COPY OF DATAFILE 1, 2;

Lists image copies of datafiles 1 and 2. These are exact file copies, not in backup set format.

LIST BACKUP OF ARCHIVELOG FROM SEQUENCE 10;

Shows archive log backups starting from sequence 10 onward.

LIST BACKUPSET OF DATAFILE 1;

Lists backup sets that include datafile 1.

LIST BACKUP;

Shows all backup sets and image copies in the RMAN catalog/control file.

LIST COPY;

Lists all image copies (of datafiles, control files, etc.).

LIST ARCHIVELOG ALL;

Lists all archived redo logs known to RMAN (including backed-up or not).

LIST RESTORE POINT <Restore_point_name>;

Lists a specific restore points details. Useful for point-in-time recovery.

LIST RESTORE POINT ALL;

Lists all restore points in database.

LIST EXPIRED BACKUP;

Lists expired backups (files not found on disk, marked expired by RMAN).

LIST BACKUP SUMMARY;

Provides a summary view (high-level) of backup sets — size, date, device type, etc.

LIST BACKUPSET TAG 'weekly_full_db_backup';

Lists backup sets with a specific tag (e.g., full weekly backups).

LIST BACKUPSET 213;

Displays information about backupset with ID 213.

LIST COPY OF DATAFILE 2 COMPLETED BETWEEN '10-DEC-2024' AND '17-DEC-2024';

Shows image copies of datafile 2 completed within a date range.

LIST BACKUP OF DATAFILE 1;

Lists backups that include only datafile 1.




REPORT Commands:-

Command

Description

REPORT OBSOLETE;

Lists backups that are no longer needed according to current retention policy (can be deleted).

REPORT SCHEMA;

Displays the current database schema as seen by RMAN (tablespaces, datafiles).

REPORT NEED BACKUP;

Shows files that need a backup based on the retention policy.

REPORT NEED BACKUP RECOVERY WINDOW OF 2 DAYS DATABASE DEVICE TYPE SBT;

Reports files that need a backup to satisfy a 2-day recovery window for tape.

REPORT NEED BACKUP DEVICE TYPE DISK;

Same as above, but for disk-based backups.

REPORT NEED BACKUP TABLESPACE USERS DEVICE TYPE SBT;

Shows if tablespace USERS needs backup on tape.

REPORT OBSOLETE RECOVERY WINDOW OF 3 DAYS;

Lists backups that fall outside a 3-day recovery window — can be purged.

REPORT OBSOLETE REDUNDANCY 1;

Lists backups that exceed a redundancy of 1 copy, meaning you can safely delete extras.


CROSSCHECK Commands:-

Command

Description

CROSSCHECK BACKUP DEVICE TYPE DISK;

Checks all disk-based backups to ensure the files still exist on disk.

CROSSCHECK BACKUP DEVICE TYPE SBT;

Checks tape-based (SBT) backups for availability.

CROSSCHECK BACKUP;

Validates all backups: backup sets, image copies, proxy copies — regardless of device type.

CROSSCHECK COPY OF DATABASE;

Validates all image copies of the entire database (datafiles, controlfiles, etc.).

CROSSCHECK BACKUPSET 1338, 1339, 1340;

Checks specific backup sets by ID numbers.

CROSSCHECK BACKUPPIECE TAG nightly_backup;

Checks all backup pieces that were tagged with nightly_backup.

CROSSCHECK BACKUP OF ARCHIVELOG ALL SPFILE;

Verifies backups of all archivelogs and SPFILEs.

CROSSCHECK CONTROLFILECOPY '/tmp/control01.ctl';

Checks the availability of a control file copy at a specific location.



DELETE Commands:-

Command

Description

DELETE BACKUPPIECE 101;

Deletes the specific backup piece with ID 101 from disk or tape.

DELETE CONTROLFILECOPY '/tmp/control01.ctl';

Deletes a control file copy located at /tmp/control01.ctl.

DELETE NOPROMPT ARCHIVELOG UNTIL SEQUENCE 300;

Deletes all archived redo logs up to sequence 299, without prompting for confirmation. Useful for space management.

DELETE BACKUP TAG 'before_upgrade';

Deletes all backups (sets or copies) with the tag before_upgrade. Helpful in identifying backups made for specific events.

DELETE ARCHIVELOG ALL BACKED UP 3 TIMES TO SBT;

Deletes all archived logs that have been successfully backed up 3 times to tape (SBT). Ensures recoverability is retained before deletion.

DELETE EXPIRED BACKUP;

Deletes all expired backups (files that were marked as EXPIRED after a CROSSCHECK operation).

DELETE OBSOLETE;

Deletes all backups (datafile, archivelog, controlfile, etc.) no longer needed according to the configured retention policy (either redundancy or recovery window).


No comments:

Post a Comment