Skip to content
Home » Oracle Database » How RMAN Restore Archivelog to Different Location

How RMAN Restore Archivelog to Different Location

Here is my case, I would like to resolve the gap between the primary and the standby database, but the log_archive_dest_1 is very limited, I can't restore all of required archived log to the destination. So I decided to restore them to another location.

RMAN> run
{
  allocate channel c1 type 'sbt_tape';
  set archivelog destination to '/big_space/arch';
  restore archivelog from sequence 109056 until sequence 109118 thread 1;
  release channel c1;
}
2> 3> 4> 5> 6> 7>
allocated channel: c1
channel c1: sid=88 devtype=SBT_TAPE
channel c1: VERITAS NetBackup for Oracle - Release 5.1 (2005081403)

executing command: SET ARCHIVELOG DESTINATION

Starting restore at 2010-04-28 18:08:12

channel c1: starting archive log restore to user-specified destination
archive log destination=/big_space/arch
channel c1: restoring archive log
archive log thread=1 sequence=109056
...

So now, will the data guard resolve the gap automatically? The answer is no. Since they are restored to a different location other than log_archive_dest_1, the data guard can't transport the archived logs to the standby. You have to transport them by yourself.

After all the archived logs are transported to the standby server, you can catalog them in one statement by this:

RMAN> catalog archivelog '/oracle/oradata/ORCL/ARCH/1_109056.arc', '/oracle/oradata/ORCL/ARCH/1_109057.arc', ...;

Leave a Reply

Your email address will not be published. Required fields are marked *