【Oracle】RMAN-20208: UNTIL CHANGE is before RESETLOGS change
2016-07-05 11:47
525 查看
在数据库已经进入新的incarnation之后,在使用新的incarnation的控制文件来恢复之前的incarnation时会出现以下报错:
RMAN> recover database until scn 1306720;
Starting recover at 04-JUL-16
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 07/04/2016 20:12:06
RMAN-20208: UNTIL CHANGE is before RESETLOGS change
解决方法也很简单,使用list incarnation;命令查看所有的incarnation,之后reset database to incarnation x;你想要恢复的备份所在的incarnation即可。
RMAN> list incarnation;
List of Database Incarnations
DB Key Inc Key DB Name DB ID STATUS Reset SCN Reset Time
------- ------- -------- ---------------- --- ---------- ----------
1 1 SOURCEDB 310015860 PARENT 1 24-AUG-13
2 2 SOURCEDB 310015860 PARENT 925702 31-JAN-16
3 3 SOURCEDB 310015860 CURRENT 1306720 04-JUL-16
RMAN> reset database to incarnation 2;
database reset to incarnation 2
RMAN> recover database until scn 1306720;
Starting recover at 04-JUL-16
using channel ORA_DISK_1
starting media recovery
archived log for thread 1 with sequence 30 is already on disk as file /home/oracle/arch/o1_mf_1_30_cqp7gbgk_.arc
archived log for thread 1 with sequence 31 is already on disk as file /home/oracle/arch/o1_mf_1_31_cqp7qsdw_.arc
archived log for thread 1 with sequence 32 is already on disk as file /home/oracle/arch/o1_mf_1_32_cqp8jht8_.arc
archived log for thread 1 with sequence 33 is already on disk as file /home/oracle/arch/o1_mf_1_33_cqp8smkk_.arc
archived log file name=/home/oracle/arch/o1_mf_1_30_cqp7gbgk_.arc thread=1 sequence=30
archived log file name=/home/oracle/arch/o1_mf_1_31_cqp7qsdw_.arc thread=1 sequence=31
archived log file name=/home/oracle/arch/o1_mf_1_32_cqp8jht8_.arc thread=1 sequence=32
archived log file name=/home/oracle/arch/o1_mf_1_33_cqp8smkk_.arc thread=1 sequence=33
media recovery complete, elapsed time: 00:00:08
Finished recover at 04-JUL-16
可以看到指定正确的incarnation后数据库可以正常进行恢复。
RMAN> recover database until scn 1306720;
Starting recover at 04-JUL-16
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 07/04/2016 20:12:06
RMAN-20208: UNTIL CHANGE is before RESETLOGS change
解决方法也很简单,使用list incarnation;命令查看所有的incarnation,之后reset database to incarnation x;你想要恢复的备份所在的incarnation即可。
RMAN> list incarnation;
List of Database Incarnations
DB Key Inc Key DB Name DB ID STATUS Reset SCN Reset Time
------- ------- -------- ---------------- --- ---------- ----------
1 1 SOURCEDB 310015860 PARENT 1 24-AUG-13
2 2 SOURCEDB 310015860 PARENT 925702 31-JAN-16
3 3 SOURCEDB 310015860 CURRENT 1306720 04-JUL-16
RMAN> reset database to incarnation 2;
database reset to incarnation 2
RMAN> recover database until scn 1306720;
Starting recover at 04-JUL-16
using channel ORA_DISK_1
starting media recovery
archived log for thread 1 with sequence 30 is already on disk as file /home/oracle/arch/o1_mf_1_30_cqp7gbgk_.arc
archived log for thread 1 with sequence 31 is already on disk as file /home/oracle/arch/o1_mf_1_31_cqp7qsdw_.arc
archived log for thread 1 with sequence 32 is already on disk as file /home/oracle/arch/o1_mf_1_32_cqp8jht8_.arc
archived log for thread 1 with sequence 33 is already on disk as file /home/oracle/arch/o1_mf_1_33_cqp8smkk_.arc
archived log file name=/home/oracle/arch/o1_mf_1_30_cqp7gbgk_.arc thread=1 sequence=30
archived log file name=/home/oracle/arch/o1_mf_1_31_cqp7qsdw_.arc thread=1 sequence=31
archived log file name=/home/oracle/arch/o1_mf_1_32_cqp8jht8_.arc thread=1 sequence=32
archived log file name=/home/oracle/arch/o1_mf_1_33_cqp8smkk_.arc thread=1 sequence=33
media recovery complete, elapsed time: 00:00:08
Finished recover at 04-JUL-16
可以看到指定正确的incarnation后数据库可以正常进行恢复。
相关文章推荐
- 【Oracle】探究recover database until scn
- Oracle数据库-select查询语句
- oracle中的游标的原理和使用详解
- 收获,不止Oracle 完整版
- oracle:IF语句 Loop循环 Cursor的用法(一)
- Oracle数据库恢复
- Oracle job procedure 存储过程定时任务
- DB2和 Oracle的并发控制(锁)比较
- oracle常用函数
- oracle 使用sqlplus
- oracle数据文件被误删或损坏故障处理
- oracle忘记密码如何重置解决办法
- oracle 12170:tns:连接超时
- 32位plsql连接64位oracle
- oracle删除重复的行
- ORACLE创建实例的过程(DBCA)
- Oracle 建立物化视图步骤
- hadoop随笔三之hive2.1安装(元数据存储oracle)
- logstash-input-jdbc实现oracle 与elasticsearch实时同步详解
- oracle启动错误提示---hostname原因导致