关于RMAN 优化选项的配置----RMAN Optimization(发现官方文档有问题)

文档地址:http://docs.oracle.com/cd/B19306_01/backup.102/b14191/rcmbackp.htm#i1006854

 

Using Backup Optimization: Examples

Run the CONFIGURE BACKUPOPTIMIZATION command to enable backup optimization.When specific conditions are met (described in "Backup Optimization Algorithm"), RMANskips backups of files that are identical to files that are alreadybacked up.

 

--这个优化选项。在RMAN备份当中,如果在一个文件满足条件(见下conditions),RMAN在备份相同文件,即此文件备份在备份当中存在,同时此备份不是过期的。RMAN会跳过此备份,进行下边的备份工作,从而会节省时间。

 

Assume that you configure optimization and a retentionpolicy as follows:

CONFIGURE DEFAULT DEVICE TYPE TO sbt;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE RETENTION POLICY TO RECOVERY WINDOW OF 4 DAYS;
Optimizing a Database Backup: Example

Then, you run this command every night to back up the databaseto tape:

BACKUP DATABASE;

Because backup optimization is configured, RMAN skipsbackups of offline and read-only datafiles only if the most recentbackups were made on or after the earliest point in the recoverywindow. RMAN does not skip backups when the most recent backups areolder than thewindow.---这段话译文。即RMAN最近的一次备份不能晚于这个恢复窗口的时间,如果晚了,说直白点,即备份被marked为obsolete了,那么备份的时候不会跳过此文件的备份,尽管你的文件符合要求。怀疑:下边的文档,不是这么写。估计文档出错了。

 

 For example, optimizationensures you do not end up with a new backup of the read-onlydatafile ?/oradata/trgt/history01.dbf every night, solong as one backup set containing this file exists within therecovery window.

 

 

For example, if the most recent backup of the datafileswas on Sunday, and the point of recoverability (that is, theearliest date in the recovery window) is on Saturday, then RMANskips the datafiles when you run the Wednesday backup. On Friday,the point of recoverability is now Monday,

--因为这里默认设定了恢复窗口的时间为4天。然而到了星期五,最早的的恢复点应该在星期一,星期天的备份就在这个恢复窗口时间的外边,即备份文件过期了。RMAN在备份这个文件的时候就不会逃过此文件了。

so the Sunday backup is now outside the window. Hence,the Friday backup does not skip the datafiles.

--这里举了个例子。

 

 

文档地址:http://docs.oracle.com/cd/B19306_01/backup.102/b14191/rcmconc1.htm#BRADV113

 

Backup Optimization

 

Ifyou enable backup optimization, then the BACKUPcommand skips backing up files when the identical file has alreadybeen backed up to the specified device type.

译文:如果启用了备份优化,那么备份命令在备份相同文件的时候,而此时它的备份已经被备份到指定的设备类型上了,那么备份会跳过这个文件。

Rules for Identifying Identical Files for BackupOptimization

--备份优化中的标识相同文件的原则

 

Table 2-2 describes criteria that RMAN uses to determinewhether a file is identical to a file that it already backedup.

Table 2-2 Criteria to Determine an IdenticalFile---确定相同文件的条件

Type of FileCriteria to Determine an IdenticalFile

Datafile

The datafile must have the same DBID, checkpoint SCN,creation SCN, and RESETLOGS SCN and time as a datafilealready in a backup. The datafile must beoffline-normal, read-only, or closednormally.   文件必须是只读的,and soon.

Archived redo log

Same thread, sequence number, and RESETLOGS SCN andtime.

Backup set

Same backup set recid and stamp.


If RMAN determines that a file is identical and it has alreadybeen backed up, then it is a candidate to be skipped. However, RMANmust do further checking to determine whether to skip the file,because both the retention policy and the backup duplexing featureare factors in the algorithm that determines whether RMAN hassufficient backups on the specified device type.

 

Backup Optimization Algorithm---备份优化算法

 

Table 2-3 describes the algorithm that backup optimization useswhen determining whether to skip the backup of an identicalfile.

Table 2-3 Backup Optimization Algorithm

For an Identical ...Backup Optimization Algorithm

Datafile

With a recovery window-based retention policy:

For backups to tape, RMAN takes another backup of a file, evenif a backup of an identical file exists, if the most recent backupis older than the configured recovery window. This is done to allowmedia to be recycled after the media expires.

For backups to disk, RMAN skips taking the backup if anidentical file is available from a backup on disk, even if thatbackup is older than the beginning of the recovery window. Theretention policy causes RMAN to retain the old backup for as longas it is needed.

 

--这句话当中有错误的地方。even if that backup is older than thebeginning of the recovery window.尽管那个备份要陈旧于恢复窗口的开始时间。

如果是这种情况的话,RMAN备份的时候是不会跳过这个文件的。怀疑文档出错了。

 

With a redundancy-based retention policy:

RMAN sets r=1 by default and searchesfor values of n in this order of precedence (that is,values higher on the list override values lower on the list):

If CONFIGURE RETENTIONPOLICY TO REDUNDANCYr isenabled, then RMAN only skips datafiles whenn=r+1backups exist.

BACKUP ... COPIESn

SET BACKUP COPIESn

CONFIGURE DATAFILE BACKUPCOPIES FOR DEVICETYPE ... TOn

RMAN skips backup only if at least n backups of anidentical file exist on the specified device. If RMAN does not skipthe backup, then it makes the backup exactly as specified.

Archived log

By default, n=1. RMAN searches forvalues of n in this order of precedence (that is,values higher on the list override values lower on the list):

BACKUP ... COPIESn

SET BACKUP COPIESn

CONFIGURE ARCHIVELOGBACKUP COPIES FORDEVICE TYPE ...TO n

RMAN skips backup only if at least n backups of anidentical file exist on the specified device. If RMAN does not skipthe backup, then it makes the backup exactly as specified.

Backup set

By default, n=1. RMAN searches forother values of n in this order of precedence (thatis, values higher on the list override values lower on thelist):

BACKUP ... COPIESn

SET BACKUP COPIESn

RMAN skips backup only if at least n backups of anidentical file exist on the specified device. If RMAN does not skipthe backup, then it makes the backup exactly as specified.


 

 

文档地址:http://docs.oracle.com/cd/B19306_01/backup.102/b14194/rcmsynta015.htm#RCMRF113

 

CONFIGURE RETENTION POLICY TO NONE; 意思为:Disables theretention policy feature. RMAN does not consider any backups orcopies as obsolete.

 

所以当需要优化的时候,将保留策略更改为CONFIGURE RETENTION POLICY TONONE;,同时那个备份文件没被人为手动删除的话,可以使得满足条件的文件不需要再次备份,RMAN会跳过此文件进行下边的工作,从而节省备份的时间,提高系统的performance;

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值