Redirected Restore from Tape using RMAN

We have a problem on one of our production database…. missing some data as per user 🙂
So my boss as ask me if i can restore the database to May 1st.

So this blog is everything i did. i know its very basic… but just taking some notes.

  
SOURCE : 
HOST : lnx01prod
DATAFILE LOCATION : /dbQXYZ/db04/oradata/QXYZ
DBID : 106413834

Tablespace Name / File Class  Filename                                                            File Size MB Auto            Next             Max
----------------------------- ---------------------------------------------------------------- --------------- ---- --------------- ---------------
SYSAUX                        /dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf                                     1,140 YES       10,485,760          32,768
SYSTEM                        /dbQXYZ/db04/oradata/QXYZ/system01.dbf                                     1,520 YES       10,485,760          32,768
TEMP                          /dbQXYZ/db04/oradata/QXYZ/temp01.dbf                                       5,658 YES          655,360          32,768
TS_DATA                       /dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf                                      3,735 YES            8,192          32,768
TS_HIST_DATA                  /dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf                                   279 YES            8,192           3,200
TS_MV                         /dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf                                     250 YES            8,192           3,200
TS_NDX                        /dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf                                         946 YES            8,192          10,240
TS_POA_DATA                   /dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf                                    250 YES            8,192           3,200
TS_POA_DATA_BLOBS             /dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf                            1,024 YES            8,192           3,200
TS_POA_NDX                    /dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf                                     100 YES            8,192           3,200
TS_REPORT_DATA                /dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf                                 250 YES            8,192           3,200
UNDOTBS1                      /dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf                                      825 YES        5,242,880          32,768
USERS                         /dbQXYZ/db04/oradata/QXYZ/users01.dbf                                         36 YES        1,310,720          32,768
[ CONTROL FILE    ]           /dbQXYZ/db04/oradata/QXYZ/control01.ctl
[ CONTROL FILE    ]           /dbQXYZ/db04/oradata/QXYZ/control02.ctl
[ ONLINE REDO LOG ]           /dbQXYZ/db04/oradata/QXYZ/redo01.log                                          50
[ ONLINE REDO LOG ]           /dbQXYZ/db04/oradata/QXYZ/redo02.log                                          50
[ ONLINE REDO LOG ]           /dbQXYZ/db04/oradata/QXYZ/redo03.log                                          50
                                                                                               ---------------
sum                                                                                                     16,163

  
TARGET : 
HOST : lnx01dev
DESTINATION DIR : /dbnfs/dbQXYZ/db04/oradata/QXYZ
OH : /opt/app/oracle/product/11.2.0.2/db_

Create a new pfile

  
*.audit_file_dest='/dbnfs/dbQXYZ/db04/oradata/QXYZ/adump'
*.audit_trail='db'
*.compatible='11.2.0.0.0'
*.control_files='/dbnfs/dbQXYZ/db04/oradata/QXYZ/control01.ctl','/dbnfs/dbQXYZ/db04/oradata/QXYZ/control02.ctl'
*.db_block_size=8192
*.db_domain=''
*.db_name='QXYZ'
*.diagnostic_dest='/opt/app/oracle'
*.dispatchers='(PROTOCOL=TCP) (SERVICE=QXYZXDB)'
##*.local_listener='LISTENER_QXYZ'
*.log_archive_dest_1='LOCATION=/dbnfs/dbQXYZ/db04/oradata/QXYZ/arch'
*.log_archive_format='QXYZ_%t_%s_%r.arc'
*.open_cursors=300
*.processes=500
*.remote_login_passwordfile='EXCLUSIVE'
*.sessions=555
*.undo_tablespace='UNDOTBS1'
*.disk_asynch_io=FALSE
*.control_file_record_keep_time=89
*.sga_target=5G
*.sga_max_size=5G


Start the database to nomount

  
SQL> startup nomount;
ORACLE instance started.

Total System Global Area 5344731136 bytes
Fixed Size                  2235904 bytes
Variable Size            1895825920 bytes
Database Buffers         3439329280 bytes
Redo Buffers                7340032 bytes
SQL>

Now restore the control file.

  
/opt/app/oracle/product/11.2.0.2/db_1/bin/rman target / catalog rman11gr2/rman@lnx12prod:1524/RMNTOOLS

Recovery Manager: Release 11.2.0.2.0 - Production on Fri May 31 20:33:00 2013
Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

connected to target database: QXYZ (not mounted)
connected to recovery catalog database

RMAN> set DBID 106413834;
ALLOCATE CHANNEL FOR MAINTENANCE DEVICE TYPE DISK;
ALLOCATE CHANNEL FOR MAINTENANCE DEVICE TYPE 'SBT_TAPE';
executing command: SET DBID
database name is "QXYZ" and DBID is 106413834

RMAN>
allocated channel: ORA_MAINT_DISK_1
channel ORA_MAINT_DISK_1: SID=397 device type=DISK

RMAN>
allocated channel: ORA_MAINT_SBT_TAPE_2
channel ORA_MAINT_SBT_TAPE_2: SID=9 device type=SBT_TAPE
channel ORA_MAINT_SBT_TAPE_2: Veritas NetBackup for Oracle - Release 7.1 (2012031702)

RMAN> RUN {
ALLOCATE CHANNEL ch00 TYPE 'SBT_TAPE';2>
3> send 'NB_ORA_POLICY=ykf_RMAN_Weekly';
send 'NB_ORA_PC_SCHED=Full';4>
5> send 'NB_ORA_CLIENT=lnx01prod'; <<<<------- this is the source.
set until time "to_date('2013-05-19 00:00:00', 'YYYY-MM-DD HH24:MI:SS')";
restore controlfile;
6> 7> 8>
9> }

allocated channel: ch00
channel ch00: SID=395 device type=SBT_TAPE
channel ch00: Veritas NetBackup for Oracle - Release 7.1 (2012031702)
sent command to channel: ORA_MAINT_DISK_1
sent command to channel: ORA_MAINT_SBT_TAPE_2
sent command to channel: ch00
sent command to channel: ORA_MAINT_DISK_1
sent command to channel: ORA_MAINT_SBT_TAPE_2
sent command to channel: ch00
sent command to channel: ORA_MAINT_DISK_1
sent command to channel: ORA_MAINT_SBT_TAPE_2
sent command to channel: ch00

executing command: SET until clause

Starting restore at 31-MAY-13

channel ch00: starting datafile backup set restore
channel ch00: restoring control file
channel ch00: reading from backup piece bk_QXYZ_10060_1_815765266
channel ch00: piece handle=bk_QXYZ_10060_1_815765266 tag=TAG20130518T170319
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:02:55
output file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/control01.ctl
output file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/control02.ctl
Finished restore at 31-MAY-13
released channel: ch00
RMAN>

Now mount the database and start database restore.

  
/opt/app/oracle/product/11.2.0.2/db_1/bin/rman target / catalog rman11gr2/rman@lnx12prod:1524/RMNTOOLS 
RUN {
ALLOCATE CHANNEL ch00 TYPE 'SBT_TAPE';
ALLOCATE CHANNEL ch01 TYPE 'SBT_TAPE';
send 'NB_ORA_POLICY=ykf_RMAN_Weekly';
send 'NB_ORA_PC_SCHED=Full';
send 'NB_ORA_CLIENT=lnx01prod';<<<<------- this is the source
set until time "to_date('2013-05-01 00:00:00', 'YYYY-MM-DD HH24:MI:SS')";
set newname for datafile 1 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/system01.dbf';
set newname for datafile 2 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf';
set newname for datafile 3 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf';
set newname for datafile 4 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/users01.dbf';
set newname for datafile 5 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf';
set newname for datafile 6 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf';
set newname for datafile 7 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf';
set newname for datafile 8 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf';
set newname for datafile 9 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf';
set newname for datafile 10 to ' /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf';
set newname for datafile 11 to ' /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf';
set newname for datafile 12 to ' /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf';
restore database;
switch datafile all;
recover database;
alter database open resetlogs;
}
  
Recovery Manager: Release 11.2.0.2.0 - Production on Fri May 31 20:56:49 2013
Copyright (c) 1982, 2009, Oracle and/or its affiliates.  All rights reserved.

connected to target database: QXYZ (DBID=106413834, not open)
connected to recovery catalog database

RMAN>

RMAN> RUN {
2> ALLOCATE CHANNEL ch00 TYPE 'SBT_TAPE';
3> ALLOCATE CHANNEL ch01 TYPE 'SBT_TAPE';
4> send 'NB_ORA_POLICY=ykf_RMAN_Weekly';
5> send 'NB_ORA_PC_SCHED=Full';
6> send 'NB_ORA_CLIENT=lnx01prod';
7> set until time "to_date('2013-05-01 00:00:00', 'YYYY-MM-DD HH24:MI:SS')";
8> set newname for datafile 1 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/system01.dbf';
9> set newname for datafile 2 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf';
set newname for datafile 3 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf';
10> 11> set newname for datafile 4 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/users01.dbf';
12> set newname for datafile 5 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf';
13> set newname for datafile 6 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf';
14> set newname for datafile 7 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf';
15> set newname for datafile 8 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf';
16> set newname for datafile 9 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf';
17> set newname for datafile 10 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf';
18> set newname for datafile 11 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf';
19> set newname for datafile 12 to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf';
20> restore database;
21> switch datafile all;
22> recover database;
23> alter database open resetlogs;
24> }

allocated channel: ch00
channel ch00: SID=395 device type=SBT_TAPE
channel ch00: Veritas NetBackup for Oracle - Release 7.1 (2012031702)

allocated channel: ch01
channel ch01: SID=10 device type=SBT_TAPE
channel ch01: Veritas NetBackup for Oracle - Release 7.1 (2012031702)

sent command to channel: ch00
sent command to channel: ch01
sent command to channel: ch00
sent command to channel: ch01
sent command to channel: ch00
sent command to channel: ch01

executing command: SET until clause
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME
executing command: SET NEWNAME

Starting restore at 31-MAY-13

channel ch00: starting datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
channel ch00: restoring datafile 00009 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf
channel ch00: restoring datafile 00011 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf
channel ch00: reading from backup piece bk_QXYZ_9694_1_813863399
channel ch01: starting datafile backup set restore
channel ch01: specifying datafile(s) to restore from backup set
channel ch01: restoring datafile 00002 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf
channel ch01: restoring datafile 00012 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf
channel ch01: reading from backup piece bk_QXYZ_9693_1_813863399
channel ch00: piece handle=bk_QXYZ_9694_1_813863399 tag=TAG20130427T170906
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:19:46
channel ch00: starting datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
channel ch00: restoring datafile 00001 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/system01.dbf
channel ch00: restoring datafile 00008 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf
channel ch00: reading from backup piece bk_QXYZ_9692_1_813863399
channel ch01: piece handle=bk_QXYZ_9693_1_813863399 tag=TAG20130427T170906
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:21:02
channel ch01: starting datafile backup set restore
channel ch01: specifying datafile(s) to restore from backup set
channel ch01: restoring datafile 00004 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/users01.dbf
channel ch01: restoring datafile 00005 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf
channel ch01: reading from backup piece bk_QXYZ_9691_1_813863390
channel ch00: piece handle=bk_QXYZ_9692_1_813863399 tag=TAG20130427T170906
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:17:30
channel ch00: starting datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
channel ch00: restoring datafile 00003 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf
channel ch00: restoring datafile 00010 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf
channel ch00: reading from backup piece bk_QXYZ_9696_1_813863399
channel ch00: piece handle=bk_QXYZ_9696_1_813863399 tag=TAG20130427T170906
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:09:16
channel ch00: starting datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
channel ch00: restoring datafile 00006 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf
channel ch00: restoring datafile 00007 to /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf
channel ch00: reading from backup piece bk_QXYZ_9695_1_813863399
channel ch01: piece handle=bk_QXYZ_9691_1_813863390 tag=TAG20130427T170906
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:31:46
channel ch00: piece handle=bk_QXYZ_9695_1_813863399 tag=TAG20130427T170906
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:13:25
Finished restore at 31-MAY-13

datafile 1 switched to datafile copy
input datafile copy RECID=13 STAMP=816904696 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/system01.dbf
datafile 2 switched to datafile copy
input datafile copy RECID=14 STAMP=816904697 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf
datafile 3 switched to datafile copy
input datafile copy RECID=15 STAMP=816904698 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf
datafile 4 switched to datafile copy
input datafile copy RECID=16 STAMP=816904700 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/users01.dbf
datafile 5 switched to datafile copy
input datafile copy RECID=17 STAMP=816904701 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf
datafile 6 switched to datafile copy
input datafile copy RECID=18 STAMP=816904702 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf
datafile 7 switched to datafile copy
input datafile copy RECID=19 STAMP=816904703 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf
datafile 8 switched to datafile copy
input datafile copy RECID=20 STAMP=816904704 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf
datafile 9 switched to datafile copy
input datafile copy RECID=21 STAMP=816904705 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf
datafile 10 switched to datafile copy
input datafile copy RECID=22 STAMP=816904706 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf
datafile 11 switched to datafile copy
input datafile copy RECID=23 STAMP=816904706 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf
datafile 12 switched to datafile copy
input datafile copy RECID=24 STAMP=816904707 file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf

Starting recover at 31-MAY-13
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00009: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf
channel ch00: reading from backup piece bk_QXYZ_9740_1_814129301
channel ch01: starting incremental datafile backup set restore
channel ch01: specifying datafile(s) to restore from backup set
destination for restore of datafile 00002: /dbnfs/dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf
channel ch01: reading from backup piece bk_QXYZ_9739_1_814129301
channel ch00: piece handle=bk_QXYZ_9740_1_814129301 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:00:15
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00001: /dbnfs/dbQXYZ/db04/oradata/QXYZ/system01.dbf
channel ch00: reading from backup piece bk_QXYZ_9738_1_814129301
channel ch00: piece handle=bk_QXYZ_9738_1_814129301 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:00:35
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00003: /dbnfs/dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf
channel ch00: reading from backup piece bk_QXYZ_9742_1_814129301
channel ch00: piece handle=bk_QXYZ_9742_1_814129301 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:00:45
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00006: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf
channel ch00: reading from backup piece bk_QXYZ_9741_1_814129301
channel ch01: piece handle=bk_QXYZ_9739_1_814129301 tag=TAG20130430T190138
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:01:42
channel ch01: starting incremental datafile backup set restore
channel ch01: specifying datafile(s) to restore from backup set
destination for restore of datafile 00005: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf
channel ch01: reading from backup piece bk_QXYZ_9737_1_814129301
channel ch00: piece handle=bk_QXYZ_9741_1_814129301 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:01:33
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00010: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf
channel ch00: reading from backup piece bk_QXYZ_9743_1_814129876
channel ch00: piece handle=bk_QXYZ_9743_1_814129876 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:01:15
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00007: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf
channel ch00: reading from backup piece bk_QXYZ_9744_1_814129883
channel ch01: piece handle=bk_QXYZ_9737_1_814129301 tag=TAG20130430T190138
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:02:56
channel ch01: starting incremental datafile backup set restore
channel ch01: specifying datafile(s) to restore from backup set
destination for restore of datafile 00008: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf
channel ch01: reading from backup piece bk_QXYZ_9747_1_814129899
channel ch00: piece handle=bk_QXYZ_9744_1_814129883 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:02:50
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00012: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf
channel ch00: reading from backup piece bk_QXYZ_9746_1_814129898
channel ch01: piece handle=bk_QXYZ_9747_1_814129899 tag=TAG20130430T190138
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:04:00
channel ch01: starting incremental datafile backup set restore
channel ch01: specifying datafile(s) to restore from backup set
destination for restore of datafile 00011: /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf
channel ch01: reading from backup piece bk_QXYZ_9745_1_814129898
channel ch00: piece handle=bk_QXYZ_9746_1_814129898 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:07:31
channel ch00: starting incremental datafile backup set restore
channel ch00: specifying datafile(s) to restore from backup set
destination for restore of datafile 00004: /dbnfs/dbQXYZ/db04/oradata/QXYZ/users01.dbf
channel ch00: reading from backup piece bk_QXYZ_9748_1_814129924
channel ch01: piece handle=bk_QXYZ_9745_1_814129898 tag=TAG20130430T190138
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:06:41
channel ch00: piece handle=bk_QXYZ_9748_1_814129924 tag=TAG20130430T190138
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:00:45

starting media recovery

channel ch00: starting archived log restore to default destination
channel ch00: restoring archived log
archived log thread=1 sequence=7663
channel ch00: reading from backup piece arch_QXYZ_glo8dgsr_1_1_814138267
channel ch01: starting archived log restore to default destination
channel ch01: restoring archived log
archived log thread=1 sequence=7664
channel ch01: reading from backup piece arch_QXYZ_gno8gg7b_1_1_814235883
channel ch00: piece handle=arch_QXYZ_glo8dgsr_1_1_814138267 tag=TAG20130430T213107
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:01:46
archived log file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/arch/QXYZ_1_7663_766157898.arc thread=1 sequence=7663
channel ch00: starting archived log restore to default destination
channel ch00: restoring archived log
archived log thread=1 sequence=7665
channel ch00: reading from backup piece arch_QXYZ_goo8gg7b_1_1_814235883
channel ch01: piece handle=arch_QXYZ_gno8gg7b_1_1_814235883 tag=TAG20130501T003802
channel ch01: restored backup piece 1
channel ch01: restore complete, elapsed time: 00:02:01
archived log file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/arch/QXYZ_1_7664_766157898.arc thread=1 sequence=7664
channel ch00: piece handle=arch_QXYZ_goo8gg7b_1_1_814235883 tag=TAG20130501T003802
channel ch00: restored backup piece 1
channel ch00: restore complete, elapsed time: 00:02:41
archived log file name=/dbnfs/dbQXYZ/db04/oradata/QXYZ/arch/QXYZ_1_7665_766157898.arc thread=1 sequence=7665
media recovery complete, elapsed time: 00:00:25
Finished recover at 31-MAY-13

released channel: ch00
released channel: ch01
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of alter db command at 05/31/2013 22:20:05
ORA-00349: failure obtaining block size for '/dbQXYZ/db04/oradata/QXYZ/redo01.log'
ORA-27041: unable to open file
Linux-x86_64 Error: 2: No such file or directory
Additional information: 9

RMAN> exit

Database recovery is complete. just need to do some post restore steps.

  
SQL>  
alter database rename file '/dbQXYZ/db04/oradata/QXYZ/redo01.log' to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/redo01.log';
alter database rename file '/dbQXYZ/db04/oradata/QXYZ/redo02.log' to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/redo02.log';
alter database rename file '/dbQXYZ/db04/oradata/QXYZ/redo03.log' to '/dbnfs/dbQXYZ/db04/oradata/QXYZ/redo03.log';
Database altered.

SQL>
Database altered.
SQL>
Database altered.

SQL>

SQL>  alter database clear logfile group 3;
Database altered.
SQL> alter database clear logfile group 2;
Database altered.
SQL> alter database clear logfile group 1;
Database altered.

once all cleared do the open resetlogs.

  
SQL> alter database open resetlogs;
Database altered.
SQL>

Now lets fixed the tempfile

  
SQL>  select name from v$tempfile;
NAME
--------------------------------------------------------------------------------
/dbQXYZ/db04/oradata/QXYZ/temp01.dbf           <<<< ---- old location

SQL> alter database tempfile '/dbQXYZ/db04/oradata/QXYZ/temp01.dbf' drop;
Database altered.

SQL> alter tablespace temp add tempfile '/dbnfs/dbQXYZ/db04/oradata/QXYZ/temp01.dbf' size 500M autoextend on next 500M;

Tablespace altered.
SQL>

Now restore is complete.

  
Tablespace Name / File Class  Filename                                                            File Size MB Auto            Next             Max
----------------------------- ---------------------------------------------------------------- --------------- ---- --------------- ---------------
SYSAUX                        /dbnfs/dbQXYZ/db04/oradata/QXYZ/sysaux01.dbf                               1,120 YES       10,485,760          32,768
SYSTEM                        /dbnfs/dbQXYZ/db04/oradata/QXYZ/system01.dbf                               1,520 YES       10,485,760          32,768
TEMP                          /dbnfs/dbQXYZ/db04/oradata/QXYZ/temp01.dbf                                   500 YES      524,288,000          32,768
TS_DATA                       /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA.dbf                                3,653 YES            8,192          32,768
TS_HIST_DATA                  /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_HIST_DATA.dbf                             276 YES            8,192           3,200
TS_MV                         /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_DATA_MV.dbf                               250 YES            8,192           3,200
TS_NDX                        /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_NDX.dbf                                   921 YES            8,192          10,240
TS_POA_DATA                   /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA.dbf                              250 YES            8,192           3,200
TS_POA_DATA_BLOBS             /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_DATA_BLOBS.dbf                      1,024 YES            8,192           3,200
TS_POA_NDX                    /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_POA_NDX.dbf                               100 YES            8,192           3,200
TS_REPORT_DATA                /dbnfs/dbQXYZ/db04/oradata/QXYZ/TS_REPORT_DATA.dbf                           250 YES            8,192           3,200
UNDOTBS1                      /dbnfs/dbQXYZ/db04/oradata/QXYZ/undotbs01.dbf                                825 YES        5,242,880          32,768
USERS                         /dbnfs/dbQXYZ/db04/oradata/QXYZ/users01.dbf                                   36 YES        1,310,720          32,768
[ CONTROL FILE    ]           /dbnfs/dbQXYZ/db04/oradata/QXYZ/control01.ctl
[ CONTROL FILE    ]           /dbnfs/dbQXYZ/db04/oradata/QXYZ/control02.ctl
[ ONLINE REDO LOG ]           /dbnfs/dbQXYZ/db04/oradata/QXYZ/redo01.log                                    50
[ ONLINE REDO LOG ]           /dbnfs/dbQXYZ/db04/oradata/QXYZ/redo02.log                                    50
[ ONLINE REDO LOG ]           /dbnfs/dbQXYZ/db04/oradata/QXYZ/redo03.log                                    50
                                                                                               ---------------
sum                                                                                                     10,875

18 rows selected.

SQL>
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s