环境: RHEL6.4 + Oracle 11.2.0.4 Primary RAC + Standby RAC

今天发现DG备库归档空间满,清理后发现备库出现GAP,需要从主库做基于SCN的增量备份进行恢复。

这个过程可以参考之前的文章《DG gap sequence修复一例》来完成。

不过本次在recover database noredo时碰到一个错误如下:

RMAN> recover database noredo;

Starting recover at 31-AUG-17
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=56 instance=jyzhao1 device type=DISK
channel ORA_DISK_1: starting incremental datafile backup set restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
destination for restore of datafile 00001: +DATA/mynas/datafile/system.258.951608183
destination for restore of datafile 00002: +DATA/mynas/datafile/sysaux.257.951608183
destination for restore of datafile 00003: +DATA/mynas/datafile/undotbs1.259.951608185
destination for restore of datafile 00004: +DATA/mynas/datafile/users.265.951608205
destination for restore of datafile 00005: +DATA/mynas/datafile/undotbs2.261.951608185
destination for restore of datafile 00006: +DATA/mynas/datafile/dbs_d_jingyu.262.951608185
destination for restore of datafile 00007: +DATA/mynas/datafile/dbs_i_jingyu.263.951608185
destination for restore of datafile 00008: +DATA/mynas/datafile/test.264.951608185
destination for restore of datafile 00009: +DATA/mynas/datafile/test2.260.951608185
destination for restore of datafile 00010: +DATA/mynas/datafile/dbs_d_hank.274.951774467
destination for restore of datafile 00011: +DATA/mynas/datafile/dbadata.276.952933931
channel ORA_DISK_1: reading from backup piece /public/backup/incremental/inc26vsd9r18.bak
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 08/31/2017 15:11:05
ORA-19870: error while restoring backup piece /public/backup/incremental/inc26vsd9r18.bak
ORA-19573: cannot obtain exclusive enqueue for datafile 11

通过故障现象按关键字“recover database noredo with error ORA-19573”搜索MOS,匹配到文档:

ORA-19573 when trying to restore to standby with incremental backup From Primary (文档 ID 1646232.1)

文中描述原因:

It was failing even though MRP was stopped using sqlplus on standby:
SQL> alter database recover managed standby database cancel; Below query was NOT returning any rows:
SQL> select process,status,sequence#,thread# from gv$managed_standby where process like 'MRP%';
Dataguard Broker is configured for this environment and MRP was not stopped using dataguard broker.

的确我这里的环境配置了DG Broker,的确我之前也停止过MRP进程,按文档的提示查询MRP进程:

SQL> select process,status,sequence#,thread# from gv$managed_standby where process like 'MRP%';

PROCESS   STATUS        SEQUENCE#    THREAD#
--------- ------------ ---------- ----------
MRP0 WAIT_FOR_GAP 665 1 --再次尝试停止MRP
SQL> alter database recover managed standby database cancel; Database altered. --再次查询MRP进程
SQL> select process,status,sequence#,thread# from gv$managed_standby where process like 'MRP%'; no rows selected

我这里在再次停掉MRP进程成功后,直接尝试recover database noredo成功:

RMAN> recover database noredo;

Starting recover at 31-AUG-17
using channel ORA_DISK_1
channel ORA_DISK_1: starting incremental datafile backup set restore
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
destination for restore of datafile 00001: +DATA/mynas/datafile/system.258.951608183
destination for restore of datafile 00002: +DATA/mynas/datafile/sysaux.257.951608183
destination for restore of datafile 00003: +DATA/mynas/datafile/undotbs1.259.951608185
destination for restore of datafile 00004: +DATA/mynas/datafile/users.265.951608205
destination for restore of datafile 00005: +DATA/mynas/datafile/undotbs2.261.951608185
destination for restore of datafile 00006: +DATA/mynas/datafile/dbs_d_jingyu.262.951608185
destination for restore of datafile 00007: +DATA/mynas/datafile/dbs_i_jingyu.263.951608185
destination for restore of datafile 00008: +DATA/mynas/datafile/test.264.951608185
destination for restore of datafile 00009: +DATA/mynas/datafile/test2.260.951608185
destination for restore of datafile 00010: +DATA/mynas/datafile/dbs_d_hank.274.951774467
destination for restore of datafile 00011: +DATA/mynas/datafile/dbadata.276.952933931
channel ORA_DISK_1: reading from backup piece /public/backup/incremental/inc26vsd9r18.bak
channel ORA_DISK_1: piece handle=/public/backup/incremental/inc26vsd9r18.bak tag=TAG20170831T150303
channel ORA_DISK_1: restored backup piece 1
channel ORA_DISK_1: restore complete, elapsed time: 00:03:45 Finished recover at 31-AUG-17

如果这样不行,可以参考MOS给出的做法:

1. Stop MRP using dataguard broker by running below command:

DGMGRL> edit database '<Standby db_unique_name>' set STATE='APPLY-OFF' ;

2. Retry the restore

至此,本文完。

recover database noredo时报错ORA-19573的更多相关文章

  1. flask迁移数据库时报错:Target database is not up的解决方案

    在flask中进行数据库迁移时报错,报错信息为"Target database is not up",解决方案如下 找到alembic的最新版本号,找到文件夹migrate下的最新 ...

  2. 案例:数据库open时报错ORA-1172,ORA-1151 处理

    环境:OEL 5.7 + Oracle 10.2.0.5 Clusterware + Oracle 10.2.0.5 RAC 故障:数据库open时报错ORA-1172,ORA-1151 1.故障详细 ...

  3. oracle备份恢复之recover database的四条语句区别

    1  recover database using backup controlfile2  recover database until cancel3  recover database usin ...

  4. 启动Oracle数据库时报错ORA-00119 & ORA-00132

    今天启动Oracle数据库时报错ORA-00119 & ORA-00132,找到解决方法做个记录,方便日后查看. 若是ORACLE不提示错误的话,可以自己查看ORACLE的日志文件. Orac ...

  5. oracle 备份恢复之recover database的四条语句区别

    1  recover database using backup controlfile2  recover database until cancel3  recover database usin ...

  6. [转帖]oracle备份恢复之recover database的四条语句区别

    oracle备份恢复之recover database的四条语句区别 https://www.cnblogs.com/andy6/p/5925433.html 需要学习一下. 1  recover d ...

  7. 在recover database时,如何决定该从哪一个SCN开始恢复

    使用备份恢复的方法搭建DG库,还原数据文件后,打开数据库时报错 SQL> ALTER DATABASE OPEN READ ONLY; ALTER DATABASE OPEN READ ONLY ...

  8. Zabbix导入数据库时报错

    导入mysql数据库时报错: ERROR 1046 (3D000) at line 1: No database selected 解决办法:1.备份原来的sql文件2. yum -y install ...

  9. SharePoint附加内容数据库时报错

    今天遇到一个很奇怪的问题,在sharepoint管理中心中给web application添加内容数据库时报错:The SharePoint database named WSS Content al ...

随机推荐

  1. Ubuntu下搭建JAVA开发环境及卸载

    据调查,在中国,PC时代,绝大多数普通用户都不知道linux为何物,到了移动互联网时代,更加不知道,也不会再知道了. 所以,此文不多解释,使用linux的,都是IT界人士,不必普及基础知识. 从已经安 ...

  2. 深度学习中将类别标签映射到one_hot向量

    有时我们的样本标签,都是标记从0开始直至到类别的个数.在模型训练的时候,这些标签需要变成one_hot向量,这样才能够跟softmax出来的概率做互熵损失,计算loss. 那么,映射的方法如下: de ...

  3. monit安装配置

    环境centos5(32bit),monit-5.17.1,下载地址 https://bitbucket.org/tildeslash/monit/downloads/ 1.tar zxvf moni ...

  4. ArcGIS拓扑检查

    对于拓扑检查中的等级参数一直不理解,经过参考资料才明白过来: 注:如果有两个要素参与到拓扑,在修复拓扑错误时会优先移动拓扑级别低的要素来满足匹配拓扑规则要求. 参考资料: https://wenku. ...

  5. cv_list

    cv_list hmz http://cse.sjtu.edu.cn/OS/OS_files/page0012.htm 邹恒明博士: 美国密歇根大学(University of Michigan-An ...

  6. wpf数据绑定:xml数据绑定

    wpf中可以通过XmlDataProvider,来实现xml数据的绑定.它通过XmlDataProvider来绑定外部资源,需要命名一个 x:Key 值,以便数据绑定目标可对其进行引用,Source设 ...

  7. 实验一:Java开发环境的熟悉

    实验一:Java开发环境的熟悉 一.实验一-1 在码云中建立"20165317exp1"的项目. 从git中下载该项目. 在"20165317exp1"目录下建 ...

  8. 《mongoDB》概念-数据类型

    一:概念 - mongoDB 是一个面向文档的数据库,而不是关系型数据库. - 摘自<mongoDB 权威指南 第2版>第3页 二:数据类型 - null - 用于表示空值或者不存在的字段 ...

  9. Examples of GoF Design Patterns in Java's core libraries

    设计模式分类 stackOverflow Structural(结构模式) Adapter:把一个接口或是类变成另外一种. java.util.Arrays#asList() javax.swing. ...

  10. FlashFXP+FileZillaServer

    从远程站点里拷贝文件到本地时,如果文件太大,通常会非常耗时,再加上若需要拨VPN,网络上的任何波动都会造成传输文件失败从头来过. 运用FlashFXP和FileZillaServer这两个工具,它拥有 ...