ITPub博客

首页 > Linux操作系统 > Linux操作系统 > DG tips

DG tips

原创 Linux操作系统 作者:mambo_shen 时间:2009-07-29 17:48:31 0 删除 编辑
#############################  switchover  ###############################
sql> select database_role ,open_mode,protection_mode,protection_level,switchover_status from v$database;
sql> alter database commit to switchover to physical standby;
sql> alter database commit to switchover to physical standby with session shutdown;
sql> alter database commit to switchover to primary;
sql> alter database commit to switchover to primary with session shutdown;
 
#############################  failover    ###############################
sql> select thread#, low_sequence#, high_sequence# from v$archive_gap;
sql> select unique thread#, max(sequence#) over(partition by thread#) last from v$archived_log;
sql> alter database recover managed standby database cancel;
sql> alter database recover managed standby database finish;
sql> alter database recover managed standby database finish force;
sql> alter database commit to switchover to primary;
 
############################# open standby  ###############################
sql> alter database recover managed standby database cancel;
sql> alter database open;
sql> alter database recover managed standby database disconnect from session;
 
#################### Maximum Performance 2 Maximum Availability  ##################
 
service="(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=hzdevdb2.mambo.com)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=mrptdb_XPT.mambo.com)(INSTANCE_NAME=rptdb)(SERVER=dedicated)))",    ARCH SYNC NOAFFIRM delay=0 OPTIONAL max_failure=0 max_connections=1   reopen=300 db_unique_name="mrptdb" register net_timeout=180 valid_for=(online_logfile,primary_role)

service="(DESCRIPTION=(ADDRESS_LIST=(ADDRESS=(PROTOCOL=TCP)(HOST=hzdevdb2.mambo.com)(PORT=1521)))(CONNECT_DATA=(SERVICE_NAME=mrptdb_XPT.mambo.com)(INSTANCE_NAME=rptdb)(SERVER=dedicated)))",    LGWR SYNC AFFIRM delay=0 OPTIONAL max_failure=0 max_connections=1   reopen=300 db_unique_name="mrptdb" register net_timeout=180 valid_for=(online_logfile,primary_role)

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/16348200/viewspace-610765/,如需转载,请注明出处,否则将追究法律责任。

上一篇: PDG
下一篇: Linux Tips
请登录后发表评论 登录
全部评论

注册时间:2008-10-09

  • 博文量
    86
  • 访问量
    74047