Tuesday, January 25, 2011

TSPITR using restore point on 10gR2 fails

When try to do RMAN TSPITR using a previous created restore point (no guarantee) rman fails :

RMAN> run {
recover tablespace 'MYTBS' until restore point TEST_RESTORE_POINT2 auxiliary destination = '/data/ttbs/testdb/data';
sql 'alter tablespace "MYTBS" online';

Starting recover at 25-JAN-11
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=200 instance=testdb1 devtype=DISK
allocated channel: ORA_DISK_2
channel ORA_DISK_2: sid=186 instance=testdb1 devtype=DISK
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 01/25/2011 12:11:09
RMAN-00600: internal error, arguments [5085] [point] [] [] []

Searching in metalink gave me this :

Bug 8571266 : RMAN TSPITR to restore point fails with RMAN-600 [5085]
Cannot specify TO RESTORE POINT for RMAN TSPITR (tablespace point in time recovery)

Range of versions believed to be affected Versions BELOW, and i have also tried

This issue is fixed in (Server Patch Set)

The documentation states that DB Point in time Recovery can be done using restore points (I have tested and worked fine with RMAN doing incomplete recovery to restore point) and Oracle recommends to create restore point to make point-in-time recovery more manageable.

So i wanted to try using the restore point with TSPITR and its not working. I believe this is a silly RMAN bug because when you create a restore point the database records the scn and time of the restore point !!!

select name, scn , time
from v$restore_point where name='TEST_RESTORE_POINT2';

TEST_RESTORE_POINT2 15940639418 25/01/11 10:10:25,000000000

So the workaround for this bug (silly if you imagine) is to using TSPITR using until scn or until time !!!

run {
recover tablespace 'MYTBS' until scn 15940639418 auxiliary destination = '/data/ttbs/testdb/data';
sql 'alter tablespace "MYTBS" online';

No comments:

Post a Comment