Home » RDBMS Server » Backup & Recovery » When and why RMAN catalogs the files in recovery area during a Restore and Recovery? (oracle 11.2.0.1)
When and why RMAN catalogs the files in recovery area during a Restore and Recovery? [message #606132] Mon, 20 January 2014 04:46 Go to next message
swaorclser
Messages: 56
Registered: August 2011
Member
Hello Experts,

I have come across strange thing as far as RMAN restore/recovery is concerned. I have a Media Manager which generates the RMAN script. With this I am trying to restore and recover a database to a PIT of a backup control file.

MML output-

 RUN { ALLOCATE CHANNEL ch0  TYPE 'SBT_TAPE';

RESTORE CONTROLFILE FROM '05ou2gq1_1_1'; 
ALTER DATABASE MOUNT; 
RESTORE DATABASE; 
RECOVER DATABASE; 
RELEASE CHANNEL ch0;
alter database open resetlogs;
}
using target database control file instead of recovery catalog
allocated channel: ch0
channel ch0: SID=18 device type=SBT_TAPE


sent command to channel: ch0
Starting restore at 15-JAN-14

channel ch0: restoring control file
channel ch0: restore complete, elapsed time: 00:00:04
output file name=/u01/app/oracle/oradata/orcl/control01.ctl
output file name=/u01/app/oracle/flash_recovery_area/orcl/control02.ctl
Finished restore at 15-JAN-14

database mounted
Starting restore at 15-JAN-14
Starting implicit crosscheck backup at 15-JAN-14
Finished implicit crosscheck backup at 15-JAN-14

Starting implicit crosscheck copy at 15-JAN-14
Finished implicit crosscheck copy at 15-JAN-14

[color=red]searching for all files in the recovery area
cataloging files...
no files cataloged[/color]

channel ch0: starting datafile backup set restore
channel ch0: specifying datafile(s) to restore from backup set
channel ch0: restoring datafile 00001 to /u01/app/oracle/oradata/orcl/system01.dbf
channel ch0: restoring datafile 00002 to /u01/app/oracle/oradata/orcl/sysaux01.dbf
channel ch0: restoring datafile 00003 to /u01/app/oracle/oradata/orcl/undotbs01.dbf
channel ch0: restoring datafile 00004 to /u01/app/oracle/oradata/orcl/users01.dbf
channel ch0: restoring datafile 00005 to /u01/app/oracle/oradata/orcl/example01.dbf
channel ch0: reading from backup piece 02ou2gor_1_1
channel ch0: piece handle=02ou2gor_1_1 tag=TAG20140114T171923
channel ch0: restored backup piece 1
channel ch0: restore complete, elapsed time: 00:00:35
Finished restore at 15-JAN-14

Starting recover at 15-JAN-14

starting media recovery

archived log for thread 1 with sequence 16 is already on disk as file /u01/app/oracle/oradata/orcl/redo01.log
archived log for thread 1 with sequence 17 is already on disk as file /u01/app/oracle/oradata/orcl/redo02.log
archived log for thread 1 with sequence 18 is already on disk as file /u01/app/oracle/oradata/orcl/redo03.log
channel ch0: starting archived log restore to default destination
channel ch0: restoring archived log
archived log thread=1 sequence=8
channel ch0: reading from backup piece 04ou2gq0_1_1
channel ch0: piece handle=04ou2gq0_1_1 tag=TAG20140114T172000
channel ch0: restored backup piece 1
channel ch0: restore complete, elapsed time: 00:00:01
archived log file name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_8_9fdljk7d_.arc thread=1 sequence=8
channel default: deleting archived log(s)
archived log file name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_8_9fdljk7d_.arc RECID=7 STAMP=836921577
unable to find archived log
archived log thread=1 sequence=9
released channel: ch0
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 01/15/2014 14:12:58
RMAN-06054: media recovery requesting unknown archived log for thread 1 with sequence 9 and starting SCN of 1045342


Where as if I run the same script manually from RMAN console then it runs fine.

RMAN> RUN { ALLOCATE CHANNEL ch0 TYPE 'SBT_TAPE'; 
RESTORE CONTROLFILE 
FROM '05ou2gq1_1_1'; ALTER DATABASE MOUNT; RESTORE DATABASE;RECOVER 
DATABASE;RELEASE CHANNEL ch0;alter database open resetlogs;}

allocated channel: ch0
channel ch0: SID=20 device type=SBT_TAPE
sent command to channel: ch0
Starting restore at 15-JAN-14

channel ch0: restoring control file
channel ch0: restore complete, elapsed time: 00:00:12
output file name=/u01/app/oracle/oradata/orcl/control01.ctl
output file name=/u01/app/oracle/flash_recovery_area/orcl/control02.ctl
Finished restore at 15-JAN-14

database mounted

Starting restore at 15-JAN-14
Starting implicit crosscheck backup at 15-JAN-14
Finished implicit crosscheck backup at 15-JAN-14

Starting implicit crosscheck copy at 15-JAN-14
Finished implicit crosscheck copy at 15-JAN-14

[color=red]searching for all files in the recovery area
cataloging files...
cataloging done[/color]

List of Cataloged Files
=======================
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_12_9fbx1y6r_.arc 

File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_11_9fbx0yt1_.arc File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_10_9fbsl3r6_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_9_9fbsjs5c_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_4_9fdr0b28_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_13_9fcc34g9_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_15_9fcgngdh_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_3_9fdr0b39_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_3_9fdqnc7p_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_17_9fdms5fv_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_16_9fcgoqh8_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_16_9fdms5fh_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_18_9fdms5qb_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_1_9fdqcknk_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_14_9fcc4dny_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_4_9fdqon63_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_2_9fdqdvxp_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_5_9fdr0b2q_.arc
File 
Name: /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_17_9fd8r5rc_.arc

channel ch0: starting datafile backup set restore
channel ch0: specifying datafile(s) to restore from backup set
channel ch0: restoring datafile 00001 
to /u01/app/oracle/oradata/orcl/system01.dbf
channel ch0: restoring datafile 00002 
to /u01/app/oracle/oradata/orcl/sysaux01.dbf
channel ch0: restoring datafile 00003 
to /u01/app/oracle/oradata/orcl/undotbs01.dbf
channel ch0: restoring datafile 00004 
to /u01/app/oracle/oradata/orcl/users01.dbf
channel ch0: restoring datafile 00005 
to /u01/app/oracle/oradata/orcl/example01.dbf
channel ch0: reading from backup piece 02ou2gor_1_1
channel ch0: piece handle=02ou2gor_1_1 tag=TAG20140114T171923
channel ch0: restored backup piece 1
channel ch0: restore complete, elapsed time: 00:00:39
Finished restore at 15-JAN-14

Starting recover at 15-JAN-14

starting media recovery

archived log for thread 1 with sequence 8 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_8_9fb938ld_.arc
archived log for thread 1 with sequence 9 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_9_9fbsjs5c_.arc
archived log for thread 1 with sequence 10 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_10_9fbsl3r6_.arc
archived log for thread 1 with sequence 11 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_11_9fbx0yt1_.arc
archived log for thread 1 with sequence 12 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_12_9fbx1y6r_.arc
archived log for thread 1 with sequence 13 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_13_9fcc34g9_.arc
archived log for thread 1 with sequence 14 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_14_9fcc4dny_.arc
archived log for thread 1 with sequence 15 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_15_9fcgngdh_.arc
archived log for thread 1 with sequence 16 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_16_9fcgoqh8_.arc
archived log for thread 1 with sequence 17 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_17_9fdms5fv_.arc
archived log for thread 1 with sequence 18 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_18_9fdms5qb_.arc
archived log for thread 1 with sequence 1 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_1_9fdqcknk_.arc
archived log for thread 1 with sequence 2 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_2_9fdqdvxp_.arc
archived log for thread 1 with sequence 3 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_3_9fdr0b39_.arc
archived log for thread 1 with sequence 4 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_4_9fdr0b28_.arc
archived log for thread 1 with sequence 5 is already on disk as 
file /u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_5_9fdr0b2q_.arc
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_8_9fb938ld_.arc thread=1 sequence=8
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_9_9fbsjs5c_.arc thread=1 sequence=9
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_10_9fbsl3r6_.arc thread=1 sequence=10
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_11_9fbx0yt1_.arc thread=1 sequence=11
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_14/o1_mf_1_12_9fbx1y6r_.arc thread=1 sequence=12
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_13_9fcc34g9_.arc thread=1 sequence=13
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_14_9fcc4dny_.arc thread=1 sequence=14
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_15_9fcgngdh_.arc thread=1 sequence=15
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_16_9fcgoqh8_.arc thread=1 sequence=16
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_17_9fdms5fv_.arc thread=1 sequence=17
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_18_9fdms5qb_.arc thread=1 sequence=18
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_1_9fdqcknk_.arc thread=1 sequence=1
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_2_9fdqdvxp_.arc thread=1 sequence=2
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_3_9fdr0b39_.arc thread=1 sequence=3
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_4_9fdr0b28_.arc thread=1 sequence=4
archived log file 
name=/u01/app/oracle/flash_recovery_area/ORCL/archivelog/2014_01_15/o1_mf_1_5_9fdr0b2q_.arc thread=1 sequence=5
media recovery complete, elapsed time: 00:00:19
Finished recover at 15-JAN-14

released channel: ch0
database opened


When compared the RMAN outputs of these two, then I observed that when script is being run manually from RMAN console, RMAN is cataloging the recovery area, archived logs whereas it is not doing so when run the script through MML UI. Why is that?Is that a reason for recovery failure in the first case in media manager job? The database is not configured with recovery catalog. Kindly advise and help. Thanking you Gurus!

Regards.
swaorclser

[Updated on: Mon, 20 January 2014 04:51]

Report message to a moderator

Re: When and why RMAN catalogs the files in recovery area during a Restore and Recovery? [message #606203 is a reply to message #606132] Tue, 21 January 2014 03:19 Go to previous messageGo to next message
swaorclser
Messages: 56
Registered: August 2011
Member
Hello Experts,

Please do reply.

Regards
Re: When and why RMAN catalogs the files in recovery area during a Restore and Recovery? [message #606873 is a reply to message #606203] Thu, 30 January 2014 05:41 Go to previous message
mrkamranumer
Messages: 11
Registered: January 2014
Junior Member
Hi Dear,

You need to run command "crosscheck archivelog all;" command on rman and then run this script

Regards,
Kamran Saeed
Previous Topic: Recreate control files
Next Topic: The doubt about full db recovery via exp/imp
Goto Forum:
  


Current Time: Thu Mar 28 12:42:29 CDT 2024