Search This Blog

Friday, 24 November 2017

Archive log restoration to Specific destination:

RMAN> catalog start with '/oracle/RAJA33DT/archive/RAJA33DT';

using target database control file instead of recovery catalog
searching for all files that match the pattern /oracle/RAJA33DT/archive/RAJA33DT

List of Files Unknown to the Database
=====================================
File Name: /oracle/RAJA33DT/archive/RAJA33DT/RAJA33DT-114008-20170701-63999.1.PITR.redo

Do you really want to catalog the above files (enter YES or NO)? yes
cataloging files...
cataloging done

List of Cataloged Files
=======================
File Name: /oracle/RAJA33DT/archive/RAJA33DT/RAJA33DT-114008-20170701-63999.1.PITR.redo


RMAN> list backup of archivelog all;

RMAN> restore archivelog logseq 113983;

RMAN> restore archivelog logseq 113983;

or

NOTE: (If you want to restore any specific location u have set the destination otherwise it will store default archive location)

run {
allocate channel t1 type 'sbt_tape';
set archivelog destination to '/home/oracle/terry/logfile/';  => (this will change the default restore location.)
restore archivelog logseq xxxxx;

or

restore archivelog from logseq=##### until logseq=#####;
}
=======================================================================
 RMAN MAUNAL BACKUP command:

 rman target=/ log=/oracle/RAJAD/base/admin/RAJAD/var/tmp/rman-arch-04396.temp cmdfile=/oracle/RAJAD/base/admin/RRAJAD/var/tmp/rman-arch-25815.rman

 =================================================================================================
 [orcldb@dcplnx22502547 log]$ cat /oracle/RAJAD/base/admin/RAJAD/var/tmp/rman-arch-25815.rman
set echo on
run {
 set command id to 'RMAN';
 allocate channel DISK01 device type disk format '/oracle/RAJAD/archive/RAJAD/%d-%e-%T-%s.%p.PITR.redo';
 backup tag='PITR' filesperset=32 as compressed backupset skip inaccessible (archivelog all not backed up delete all input);
 delete noprompt archivelog all backed up 1 times to device type disk;
}
exit;

No comments:

Post a Comment