Oracle中Archived redolog的生成

目录

一、问题预览

二、问题解答


一、问题预览

        大家都知道 Oracle 中 online redolog切换后会生成 archived redolog,心里默认的就是 online redolog 切换后 archived redolog 已经生成。切换示意图,如下图所示。

        但事实真的是这样吗?

二、问题解答

参考文档:Managing Archived Redo Logs (oracle.com)

        

Oracle Database lets you save filled groups of redo log files to one or more offline destinations, known collectively as the archived redo log. The process of turning redo log files into archived redo log files is called archiving. This process is only possible if the database is running in ARCHIVELOG mode. You can choose automatic or manual archiving.

An archived redo log file is a copy of one of the filled members of a redo log group. It includes the redo entries and the unique log sequence number of the identical member of the redo log group. For example, if you are multiplexing your redo log, and if group 1 contains identical member files a_log1 and b_log1, then the archiver process (ARCn) will archive one of these member files. Should a_log1 become corrupted, then ARCn can still archive the identical b_log1. The archived redo log contains a copy of every group created since you enabled archiving.

When the database is running in ARCHIVELOG mode, the log writer process (LGWR) cannot reuse and hence overwrite a redo log group until it has been archived. The background process ARCn automates archiving operations when automatic archiving is enabled. The database starts multiple archiver processes as needed to ensure that the archiving of filled redo logs does not fall behind.

        由上可知,oracle中的 archived redolog 文件是由专门的 ARCn 进程负责归档操作。归档操作应该是与 online redolog 的写入是并行的。

        Oracle 内部保障未归档的 online redolog 文件是不能被复用的,但没保证 online redolog 切换后一定生成归档日志文件,但上一个切换轮回的 online redolog一定被归档了。

When you run a database in ARCHIVELOG mode, you enable the archiving of the redo log.

The database control file indicates that a group of filled redo log files cannot be reused by LGWR until the group is archived.

A filled group becomes available for archiving immediately after a redo log switch occurs.

         online redolog 切换后立即会启动归档进程,一般情况下,online redolog切换了归档日志也会生成的。Oracle 数据库默认启动 4 个 ARCn。这个值是可以动态修改的。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 1
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论 1
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

我要出家当道士

打赏是不可能,这辈子都不可能

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值