当前位置:网站首页>Configuring the environment for RMAN backups_ Configure backup optimization
Configuring the environment for RMAN backups_ Configure backup optimization
2022-06-09 08:42:00 【Count words and lines】
function RMAN Of CONFIGURE Command to enable and disable backup optimization . Backup optimization in some cases Skip file backup if the equivalent file or the equivalent version of the file has been backed up .
1. Overview of backup optimization
When backup optimization is enabled , If the equivalent file has been backed up to the specified device type ,BACKUP The command skips backing up files .
The following table describes RMAN A standard used to determine whether a file is equivalent to a backed up file .
| file type | Confirm the standards of equivalent documents |
|---|---|
| Data files | The data file must have the same... As the data file in the backup DBID, checkpoint SCN, establish SCN,RESETLOGS SCN And time . Data files must be offline normally (offline-normal), read-only , Or normally closed . |
| Archive log | same DBID, Threads , Serial number ,RESETLOGS SCN And time . |
| Backup set | same DBID, Backup set records ID And time stamp . |
If RMAN Confirm that a file is equivalent to that it has been backed up , So it's a skipped candidate .RMAN Further checks must be made to confirm whether the file is skipped , However , The retention policy and backup two-way reuse feature are used to determine RMAN Whether there are enough backup algorithm elements on the specified device type .
If the above conditions are met ,RMAN Optimize with backup :
1) command CONFIGURE BACKUP OPTIMIZATION ON Has been run to enable backup optimization
2) function BACKUP DATABASE,BACKUP ARCHIVELOG and ALL or LIKE Options , or BACKUP BACKUPSET ALL,BACKUP RECOVERY AREA,BACKUP RECOVERY FILES or BACKUP DATAFILECOPY.
notes : When TO DESTINATION And BACKUP RECOVERY AREA or BACKUP RECOVERY FILE When used together ,RMAN Just skip backup TO DESTINATION There is an equivalent backup file in the location .
3) Only one channel type is assigned , Not in the same BACKUP Mixed disk and... On the command SBT passageway .
notes : In backup undo Optimization ,RMAN Exclude committed transactions undo change ( Restoring a backup does not require ). Backup optimization can be enabled and disabled , But backup undo Optimization is a built-in behavior .
for example , Suppose you have configured backup optimization . These commands back up the database , All archived logs and all backup sets to tape .
BACKUP DEVICE TYPE sbt DATABASE PLUS ARCHIVELOG;
BACKUP DEVICE TYPE sbt BACKUPSET ALL;
If a file that has not been backed up since the last backup has been changed , that RMAN The files will not be backed up again . If the file has been backed up ,RMAN Skip all files specified by the command ,RMAN It will also prompt errors .
Can be specified at any time BACKUP Ordered FORCE Option to undo the optimization . for example , Can run :
BACKUP DATABASE FORCE;
BACKUP ARCHIVELOG ALL FORCE;
2.SBT Backup optimization effect of backup retention policy
When backing up to SBT Equipment time , Backup optimization is not always applied .
The behavior of normal backup optimization exceptions based on recovery windows and redundancy retention policies is described in the following sections .
notes : If you use the media manager and its own internal expiration policy , Carefully enable backup optimization . Regular operation CROSSCHECK Command to synchronize with the media manager RMAN Restore directory . otherwise ,RMAN Skip backup due to optimization , Without realizing that the media manager has discarded the backup stored on tape .
2.1. SBT Backup recovery window for backup backup optimization of retention policy
Assume that the backup retention policy is in effect with backup optimization and recovery windows enabled . In this case , When executed SBT When the backup ,RMAN Always back up their most recent backup data files that are older than the recovery window .
for example , Suppose the following scenario :
1) It's today 2 month 21 Japan
2) The recovery window is 7 God
3) Recent tablespaces tools Tape backup of is 1 month 3 Japan
4) Table space tools It's read-only
stay 2 month 21 Japan , When executing commands to back up tablespaces tools When to tape ,RMAN Back it up even if it is 1 month 3 No changes have been made since the backup of ( Because it's read-only ).RMAN It is backed up because the tablespace is backed up in the 7 The recovery window period of days does not exist .
This behavior allows media management to set the old tape to expire . otherwise , The media manager is forced to remain indefinitely 1 month 3 Table space of day tools Backup of . stay 2 month 21 Day to day tablespace tools Make a recent backup ,RMAN Let the media manager include 1 month 3 The tape of daily backup is set as expired .
2.2. SBT Redundancy of backup backup optimization of retention policy
Suppose a redundancy retention policy is configured . In this case , When it exists r+1 Backup of files (r Is the command CONFIGURE RETENTION POLICY TO REDUNDANCY r Redundancy in ),RMAN Only skip backing up offline or read-only data files to SBT.
for example , Assume that backup optimization is enabled and the following retention policies are set :
CONFIGURE DEFAULT DEVICE TYPE TO sbt;
CONFIGURE BACKUP OPTIMIZATION ON;
CONFIGURE RETENTION POLICY TO REDUNDANCY 2;
Use these configurations ,RMAN Skip backing up only three identical files that have already been backed up . Assume you have never backed up users Table space , It's readable and writable , During the course of a week, perform the actions in the following table .
| God | operation | result | Redundant backup |
|---|---|---|---|
| Monday | Normal offline users Table space | ||
| Tuesday | BACKUP DATABASE | Backup tablespaces users | |
| Wednesday | BACKUP DATABASE | Backup tablespaces users | |
| Thursday | BACKUP DATABASE | Backup tablespaces users | Tuesday's backup |
| Friday | BACKUP DATABASE | Table space users No backup | Tuesday's backup |
| Saturday | BACKUP DATABASE | Table space users No backup | Tuesday's backup |
| Sunday | DELETE OBSOLETE | Tuesday's backup was deleted | |
| Monday | BACKUP DATABASE | Backup tablespaces users | Wednesday backup |
On Tuesday , Wednesday and Thursday backup offline users Table space to satisfy the need to exist 3 Conditions for backup ( More than redundancy settings 1). Friday and Saturday backups will not back up tablespaces because of backup optimization users. Tuesday's backup is expired from Thursday .
On Sunday , Delete all expired backups , It will remove Tuesday's users Backup of table space . Tuesday's backup expires because of the retention policy settings . The backup of the entire database on Monday will be backed up users Table space to meet 3 Conditions that a backup must exist ( More than redundancy settings 1). such , Tape can be recycled over time .
3. Configure backup optimization
By default , Backup optimization configuration is OFF. have access to SHOW BACKUP OPTIMIZATION Command to view the current settings for backup optimization .
View the current backup optimization configuration :
SHOW BACKUP OPTIMIZATION;
RMAN configuration parameters for database with db_unique_name PROD1 are:
CONFIGURE BACKUP OPTIMIZATION OFF;
Enable backup optimization :
CONFIGURE BACKUP OPTIMIZATION ON;
source :《Oracle Database Backup and Recovery User’s Guide,19c》
边栏推荐
- Hj22 water bottle
- English语法_副词
- SQL: people flow in the gymnasium (common solution for continuous day cases)
- HJ22 汽水瓶
- 2022-2028 global gamefi token industry research and trend analysis report
- 2022-2028 global electronic equipment leasing platform industry research and trend analysis report
- 编辑器说明-备用
- Oracle本地管理的表空间
- 使用闪回数据库(FLASHBACK DATABASE)和还原点(RESTORE POINT)
- 配置RMAN备份的环境
猜你喜欢
随机推荐
RMAN备份概念_一致的和不一致的RMAN备份
Use of extensions and super
配置RMAN备份的环境_配置高级的备份选项
Self made compiler learning 4: using flex
Sql: employees exceeding manager's income
Excerpt of a verse of compassion and gladness
Huayun data was selected as the representative manufacturer of cloud infrastructure in IDC development trends of industrial software and industrial Internet
配置Conda环境和Pytorch安装
I met a big man!
If and ifnull in MySQL
RMAN备份概念_关于备份集(Backup Set)
Openinfra summit 2022 𞓜 China cloud data users once again won the super user Award
編輯器說明-備用
配置RMAN备份的环境_配置通道(Channel)
Sql: Sales Analysis III
EDA open source simulation tool verilator getting started 1: installation and testing
使用闪回数据库(FLASHBACK DATABASE)和还原点(RESTORE POINT)
SQL: market analysis I
Sql: actors and directors who have cooperated at least three times
2022-2028 global electronic equipment leasing platform industry research and trend analysis report









