登录  
 加关注
查看详情
   显示下一条  |  关闭
温馨提示!由于新浪微博认证机制调整,您的新浪微博帐号绑定已过期,请重新绑定!立即重新绑定新浪微博》  |  关闭

li.angshan 的博客

关注数据计算领域

 
 
 

日志

 
 
 
 

Failovers involving a standby database  

2009-10-29 11:47:16|  分类: oracle DataGurd |  标签: |举报 |字号 订阅

  下载LOFTER 我的照片书  |
Some circumstance you will be processed failover standby database :
  • In all cases, after a failover, the original primary database can no longer participate in the Data Guard configuration.

  • In most cases, other logical or physical standby databases not directly participating in the failover remain in the configuration and do not have to be shut down or restarted.

  • In some cases, it might be necessary to re-create all standby databases after configuring the new primary database.

Step 1
Be sure archive log gaps between primary database and standby database ,issue :
sql> SELECT THREAD#, LOW_SEQUENCE#, HIGH_SEQUENCE# FROM V$ARCHIVE_GAP;
THREAD# LOW_SEQUENCE# HIGH_SEQUENCE#
---------- ------------- --------------
1 90 92

In the result :
SQL> ALTER DATABASE REGISTER PHYSICAL LOGFILE 'filespec1';

Step 2
Repeat step 1 until all gaps resolved

Step 3
Coping any other missing archive redo logs
For ex:
SQL> SELECT UNIQUE THREAD# AS THREAD, MAX(SEQUENCE#)
2> OVER (PARTITION BY thread#) AS LAST from V$ARCHIVED_LOG;

THREAD LAST
---------- ----------
1 100

SQL> ALTER DATABASE REGISTER PHYSICAL LOGFILE 'filespec1';

Step 4 Initiate a failover on the target physical standby database

SQL> ALTER DATABASE RECOVER MANAGED STANDBY DATABASE FINISH FORCE;

Step 5 Convert physical standby database to primary database role.

SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PRIMARY;

Step 6 Finish the transition of the standby database to primary database role.

6.1 If the physical standby database have not been opened in read_only mode since last time it is started ,
issue the SQL alter database open to open the new primary database:

SQL> ALTER DATABASE OPEN;

6.2 If the physical stantdby database have been opend in read_only mode since last time it is started ,you must shut down the target
database and restarted it ;

SQL> SHUTDOWN IMMEDIATE;
SQL> STARTUP;
  评论这张
 
阅读(146)| 评论(0)

历史上的今天

评论

<#--最新日志,群博日志--> <#--推荐日志--> <#--引用记录--> <#--博主推荐--> <#--随机阅读--> <#--首页推荐--> <#--历史上的今天--> <#--被推荐日志--> <#--上一篇,下一篇--> <#-- 热度 --> <#-- 网易新闻广告 --> <#--右边模块结构--> <#--评论模块结构--> <#--引用模块结构--> <#--博主发起的投票-->
 
 
 
 
 
 
 
 
 
 
 
 
 
 

页脚

网易公司版权所有 ©1997-2018