In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly shows you the "example analysis of rman incremental backup", the content is simple and easy to understand, the organization is clear, I hope to help you solve doubts, let Xiaobian lead you to study and learn the "example analysis of rman incremental backup" article.
BACKUP DATABASE and BACKUP INCREMENTAL LEVEL 0 DATABASE backups have the same contents, but they still differ. Full backup is not applied to incremental backup policies, only level 0 backups can be used as base points for incremental backups, and there is no RMAN command to translate the relationship between the two. When the database is open, incremental backup can only be used if the database is in archive mode. If the database is not in archive mode and the database is in open state, incremental backup cannot be used.
There are two types of incremental backups: cumulative incremental and differential incremental
Accumulate incremental backups
An incremental backup that backs up all the blocks changed since the most recent backup at level 0. When recovering with cumulative incremental backups, only the most recent cumulative incremental backup must be applied.
Cumulative incremental backups back up all changed blocks from the most recent level 0 backup point to the present, and only the most recent incremental backups are used when restoring data using incremental backups
differential incremental backup
A type of incremental backup that backs up all blocks that have changed since the most recent backup at level 1 or level 0. For example, in a differential level 1 backup RMAN determines which level 1 or level 0 incremental backup is most recent and then backs up all blocks changed since that backup. Differential backups are the default type of incremental backup. When recovering using differential incremental backups, RMAN must apply all differential incremental level 1 backups since the restored data file backup.
Differential incremental backups back up all changed blocks from the most recent level 0 or 1 point up to the present. When there is only a level 0 backup before, differential incremental backup will only backup the changed blocks from level 0 to the present. When there is a level 1 backup before, differential incremental backup will backup the changed blocks from level 1 to the present. When restoring data using differential incremental backups, all level 1 differential incremental backups need to be applied.
Difference between differential and cumulative backups
Differential backups save more space and resources than cumulative backups, but level 1 availability must be guaranteed to ensure that the database cannot be restored to the point of failure because of the effectiveness of a certain level 1. In contrast, cumulative backups are more secure than differential backups because their own backups are repetitive, and only the most recent level 1 backup needs to be available to recover to the point of failure, rather than all level 1 backups. Accumulating backups also requires more disk space.
RMAN> backup incremental level 0 database;
Starting backup at 2017-07-30 13:12:44
using channel ORA_DISK_1
channel ORA_DISK_1: starting incremental level 0 datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00001 name=/u01/app/oracle/oradata/test/system01.dbf
input datafile file number=00002 name=/u01/app/oracle/oradata/test/sysaux01.dbf
input datafile file number=00004 name=/u01/app/oracle/oradata/test/users01.dbf
input datafile file number=00003 name=/u01/app/oracle/oradata/test/undotbs01.dbf
channel ORA_DISK_1: starting piece 1 at 2017-07-30 13:12:44
channel ORA_DISK_1: finished piece 1 at 2017-07-30 13:12:59
piece handle=/home/oracle/1csal8ic_1_1 tag=TAG20170730T131244 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:15
channel ORA_DISK_1: starting incremental level 0 datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
including current control file in backup set
including current SPFILE in backup set
channel ORA_DISK_1: starting piece 1 at 2017-07-30 13:13:02
channel ORA_DISK_1: finished piece 1 at 2017-07-30 13:13:03
piece handle=/home/oracle/1dsal8ir_1_1 tag=TAG20170730T131244 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backup at 2017-07-30 13:13:03
change data
SQL> create table scott.backuptest(a int);
Table created.
SQL> insert into scott.backuptest values(1);
1 row created.
SQL> commit
2 /
Commit complete
Level 1 Cumulative Incremental Backup
RMAN> BACKUP INCREMENTAL LEVEL 1 CUMULATIVE DATABASE;
Starting backup at 2017-07-30 13:25:38
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=1 device type=DISK
channel ORA_DISK_1: starting incremental level 1 datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00001 name=/u01/app/oracle/oradata/test/system01.dbf
input datafile file number=00002 name=/u01/app/oracle/oradata/test/sysaux01.dbf
input datafile file number=00004 name=/u01/app/oracle/oradata/test/users01.dbf
input datafile file number=00003 name=/u01/app/oracle/oradata/test/undotbs01.dbf
channel ORA_DISK_1: starting piece 1 at 2017-07-30 13:25:39
channel ORA_DISK_1: finished piece 1 at 2017-07-30 13:25:46
piece handle=/home/oracle/1fsal9aj_1_1 tag=TAG20170730T132538 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:07
channel ORA_DISK_1: starting incremental level 1 datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
including current control file in backup set
including current SPFILE in backup set
channel ORA_DISK_1: starting piece 1 at 2017-07-30 13:25:47
channel ORA_DISK_1: finished piece 1 at 2017-07-30 13:25:48
piece handle=/home/oracle/1gsal9aq_1_1 tag=TAG20170730T132538 comment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:00:01
Finished backup at 2017-07-30 13:25:48
v$backup_datafile view to view backups
SQL> SELECT FILE#, INCREMENTAL_LEVEL, COMPLETION_TIME,
BLOCKS, DATAFILE_BLOCKS
FROM V$BACKUP_DATAFILE
WHERE INCREMENTAL_LEVEL IN (0,1)
ORDER BY COMPLETION_TIME; 2 3 4 5
FILE# INCREMENTAL_LEVEL COMPLETION_TIME BLOCKS DATAFILE_BLOCKS
---------- ----------------- ------------------- ---------- ---------------
3 0 2017-07-30 13:12:44 1241 11520
4 0 2017-07-30 13:12:49 49665 52320
2 0 2017-07-30 13:12:52 62449 81920
1 0 2017-07-30 13:12:53 78054 117760
3 1 2017-07-30 13:25:40 160 11520
4 1 2017-07-30 13:25:42 11 52320
2 1 2017-07-30 13:25:43 527 81920
1 1 2017-07-30 13:25:44 53 117760
8 rows selected.
The above is "rman incremental backup sample analysis" all the content of this article, thank you for reading! I believe that everyone has a certain understanding, hope to share the content to help everyone, if you still want to learn more knowledge, welcome to pay attention to the industry information channel!
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.