重庆思庄Oracle、Redhat认证学习论坛

 找回密码
 注册

QQ登录

只需一步,快速开始

搜索
查看: 1959|回复: 0
打印 上一主题 下一主题

oracle 12c的Data guard中将废弃使用using current logfile

[复制链接]
跳转到指定楼层
楼主
发表于 2017-7-20 00:17:10 | 只看该作者 回帖奖励 |倒序浏览 |阅读模式
下面我们看一篇关于12c的Data guard中将废弃使用using current logfile问题的分析详解,希望这篇文章可以对各位带来一些帮助。

问题起源于客户的一个12c的数据库,需要启动到非real time apply的模式,但是发现执行:
alter database recover managed standby database cancel;
alter database recover managed standby database disconnect from session;
之后,数据库还是一直工作在real time apply的模式。
去alertlog中找了一下,发现了答案:
Thu Jun 09 12:16:03 2016
Errors in file /cust/mydb/rdbms/oracle/diag/rdbms/rmydb/mydb/trace/mydb_pr00_24168.trc:
ORA-16037: user requested cancel of managed recovery operation
Thu Jun 09 12:16:03 2016
MRP0: Background Media Recovery process shutdown (mydb)
Thu Jun 09 12:16:04 2016
Managed Standby Recovery Canceled (mydb)
Completed: alter database recover managed standby database cancel
alter database recover managed standby database disconnect from session <==我们平时的发起语句
Thu Jun 09 12:16:13 2016
Attempt to start background Managed Standby Recovery process (mydb)
Starting background process MRP0
Thu Jun 09 12:16:13 2016
MRP0 started with pid=27, OS id=17971
Thu Jun 09 12:16:13 2016
MRP0: Background Managed Standby Recovery process started (mydb)
Thu Jun 09 12:16:19 2016
Started logmerger process
Thu Jun 09 12:16:19 2016
Managed Standby Recovery starting Real Time Apply  <==使用了real time apply,而上述语句在11g中的效果是使用real time apply,在12c中行为发生了变化。
Thu Jun 09 12:17:06 2016
Only allocated 127 recovery slaves (requested 128)
Thu Jun 09 12:17:06 2016
Parallel Media Recovery started with 127 slaves
Thu Jun 09 12:17:12 2016
Waiting for all non-current ORLs to be archived...
Thu Jun 09 12:17:12 2016
  
  
Wed Apr 27 14:56:52 2016
MRP0: Background Media Recovery process shutdown (mydb)
Wed Apr 27 14:56:53 2016
Managed Standby Recovery Canceled (mydb)
Completed: alter database recover managed standby database cancel
alter database recover managed standby database parallel 16 USING ARCHIVED LOGFILE   disconnect <== 使用using archived log
Wed Apr 27 14:57:29 2016
Attempt to start background Managed Standby Recovery process (mydb)
Starting background process MRP0
Wed Apr 27 14:57:29 2016
MRP0 started with pid=27, OS id=23908
Wed Apr 27 14:57:29 2016
MRP0: Background Managed Standby Recovery process started (mydb)
Started logmerger process
Wed Apr 27 14:57:35 2016
Managed Standby Recovery not using Real Time Apply <==可以看到,不使用real time apply了!
Wed Apr 27 14:57:38 2016
Parallel Media Recovery started with 16 slaves
Wed Apr 27 14:57:38 2016
Waiting for all non-current ORLs to be archived...
Wed Apr 27 14:57:38 2016
All non-current ORLs have been archived.
Wed Apr 27 14:57:39 2016
Media Recovery Waiting for thread 1 sequence 2287 (in transit)
Completed: alter database recover managed standby database parallel 16 USING ARCHIVED LOGFILE   disconnect
同时,在在线文档也发现了相关说明:

即using current logfile 已经过期,如果要启用real time apply,不再需要加这个语句。(所以我们无论加了using current logfile,还是不加,都是使用real time apply的。)
要使用非real time apply,就需要使用using archived log了。
综上:
在11g中,如要使用real time apply,需要加using current logfile,
在12c中,如果要不使用real time apply,需要加using archived log,using current logfile已经过期作废。
不带using语句,在11g中,默认是不使用real time apply,而在12c中是默认使用real time apply

分享到:  QQ好友和群QQ好友和群 QQ空间QQ空间 腾讯微博腾讯微博 腾讯朋友腾讯朋友
收藏收藏 支持支持 反对反对
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

QQ|手机版|小黑屋|重庆思庄Oracle、Redhat认证学习论坛 ( 渝ICP备12004239号-4 )

GMT+8, 2024-11-24 23:11 , Processed in 0.110397 second(s), 19 queries .

重庆思庄学习中心论坛-重庆思庄科技有限公司论坛

© 2001-2020

快速回复 返回顶部 返回列表