(一)About Archived Redo Log Failover
归档日志如果出现缺失或坏块RMAN会自动到其它归档日志路径找对应归档日志
The archived redo log failover feature enables RMAN to complete a backup even when some archiving destinations are missing logs or contain logs with corrupt blocks. If at least one log corresponding to a given log sequence and thread is available in the fast recovery area or any of the archiving destinations, then RMAN tries to back it up. If RMAN finds a corrupt block in a log file during backup, it searches other destinations for a copy of that log without corrupt blocks.
(二)About Online Redo Log Switching
RMAN备份归档日志前均会先进行switch logfile
To make an open database backup of archived redo logs that includes the most recent online redo log, you can execute the BACKUP command with any of the following clauses:
PLUS ARCHIVELOG
ARCHIVELOG ALL
ARCHIVELOG FROM ...
Before beginning the backup, RMAN switches out of the current redo log group, and archives all online redo logs that have not yet been archived, up to and including the redo log group that was current when the command was issued. This feature ensures that the backup contains all redo generated before the start of the command.
在执行BACKUP ... PLUS ARCHIVELOG时步骤如下
An effective way of backing up archived redo logs is the BACKUP ... PLUS ARCHIVELOG command, which causes RMAN to do the following:
- Run the ALTER SYSTEM ARCHIVE LOG CURRENT statement.
- Run BACKUP ARCHIVELOG ALL. If backup optimization is enabled, then RMAN skips logs that it has already backed up to the specified device.
- Back up the rest of the files specified in the BACKUP command.
- Run the ALTER SYSTEM ARCHIVE LOG CURRENT statement.
- Back up any remaining archived logs generated during the backup. If backup optimization is not enabled, then RMAN backs up the logs generated in Step 1 plus all the logs generated during the backup.
The preceding steps guarantee that data file backups taken during the command are recoverable to a consistent state. Also, unless the online redo log is archived at the end of the backup, DUPLICATE is not possible with the backup.
(三)About Backup of Archived Redo Logs in CDBs
CDB只能通过root在CDB$root中备份,PDB无法备份归档日志,原因就是在pdb你无法switch online log
In a CDB, archived redo logs can be backed up only when you connect to the root as a common user with the SYSDBA or SYSBACKUP privilege.
When you connect to a PDB as a local user with SYSDBA or SYSBACKUP privilege, you cannot back up or delete archived redo logs.