Database Reference
In-Depth Information
RMAN Backup of Archived Redo Logs
Backing up archived redo logs is an important task since it serves to protect the database's
principal recovery mechanism, which is redo. Backing up archived redo logs is done via the
BACKUP ARCHIVELOG
command. This command requires that you include keywords from
the
ARCHIVELOG SPECIFIER
clause, which is used to indicate the archived redo logs that you
want to back up. Common keywords that you might use include the following:
ALL
Backs up all archived redo logs currently on disk
SEQUENCE BETWEEN N AND O
Backs up all archived redo logs available on disk between
sequence number
n
and sequence number
o
TIME BETWEEN T1 AND T2
Backs up all archived redo logs available on disk between time
t1
(the earlier time) and time
t2
(the later time)
Be Careful What You Ask For. You Might just Get it (or Not)
Look at the example where we backed up the archived redo logs for the last 24 hours. The
command was as follows:
backup archivelog time between “sysdate-1” and “sysdate”;
But guess what happens if you change this command just slightly:
RMAN> backup archivelog time between “sysdate” and “sysdate-1”;
Starting backup at 05-SEP-2013
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of backup command at 09/05/2013 19:02:56
RMAN-20242: specification does not match any archived log in the
recovery catalog
If you didn't know any better, you might just think that there are no archived redo logs to
back up and assume the
BACKUP ARCHIVELOG
command worked fine and dandy. In fact,
the command failed because you had the from/to dates in the wrong order. This high-
lights how important it is to make sure you carefully review the syntax of the command
you are getting ready to execute and then review the output of RMAN commands and
make sure RMAN did what you thought you told it to do.
Search WWH ::
Custom Search