12c ADG reinstate database xxx

Posted

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了12c ADG reinstate database xxx相关的知识,希望对你有一定的参考价值。

测试演练一下12C ADG环境,可能因为某些极端情况,比如主库存储异常,只能切换到备库。然后主库存储修复,重新恢复主备。

详见如下操作;
在新主库上操作

<roidb01:orcl:/home/oracle>$dgmgrl /
DGMGRL for Linux: Version 12.1.0.2.0 - 64bit Production

Copyright (c) 2000, 2013, Oracle. All rights reserved.

Welcome to DGMGRL, type "help" for information.
Connected as SYSDG.
DGMGRL> 
DGMGRL> show configuration;

Configuration - dg_config

  Protection Mode: MaxPerformance
  Members:
  orcldg - Primary database
    orcl   - Physical standby database 

Fast-Start Failover: DISABLED

Configuration Status:
SUCCESS   (status updated 34 seconds ago)

DGMGRL> validate database orcldg;

  Database Role:    Primary database

  Ready for Switchover:  Yes

DGMGRL> validate database orcl;

  Database Role:     Physical standby database
  Primary Database:  orcldg

  Ready for Switchover:  Yes
  Ready for Failover:    Yes (Primary Running)

DGMGRL> failover to orcl;
Performing failover NOW, please wait...
Failover succeeded, new primary is "orcl"
DGMGRL> show configuration;

Configuration - dg_config

  Protection Mode: MaxPerformance
  Members:
  orcl   - Primary database
    orcldg - Physical standby database (disabled)
      ORA-16661: the standby database needs to be reinstated

Fast-Start Failover: DISABLED

Configuration Status:
SUCCESS   (status updated 71 seconds ago)

##保证原主库为mount状态

DGMGRL> reinstate database orcldg;
Reinstating database "orcldg", please wait...
Reinstatement of database "orcldg" succeeded
DGMGRL> show configuration;

Configuration - dg_config

  Protection Mode: MaxPerformance
  Members:
  orcl   - Primary database
    orcldg - Physical standby database 

Fast-Start Failover: DISABLED

Configuration Status:
SUCCESS   (status updated 6 seconds ago)
DGMGRL> validate database orcl;

  Database Role:    Primary database

  Ready for Switchover:  Yes

DGMGRL> validate database orcldg;

  Database Role:     Physical standby database
  Primary Database:  orcl

  Ready for Switchover:  Yes
  Ready for Failover:    Yes (Primary Running)

DGMGRL> 

以上是关于12c ADG reinstate database xxx的主要内容,如果未能解决你的问题,请参考以下文章

12c ADG 延迟报警

Oracle 12C Rac到Rac搭建ADG

12c ADG无法删除备库归档RMAN-08137

12c adg 主库归档删除告警:RMAN-08137

12c Oracle ADG日志切换hang

ORACLE 12C物理备库archive log list 显示为0