{"id":823,"date":"2020-11-02T20:48:23","date_gmt":"2020-11-02T23:48:23","guid":{"rendered":"https:\/\/www.fernandosimon.com\/blog\/?p=823"},"modified":"2020-11-02T20:48:23","modified_gmt":"2020-11-02T23:48:23","slug":"keep-backups-and-zdlra","status":"publish","type":"post","link":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/","title":{"rendered":"KEEP backups and ZDLRA"},"content":{"rendered":"<p style=\"text-align: justify;\"><a href=\"https:\/\/docs.oracle.com\/en\/database\/oracle\/oracle-database\/19\/rcmrf\/keepOption.html#GUID-36E9008E-48A5-4AB9-8C9D-2D477342594B\" target=\"_blank\" rel=\"noopener noreferrer\">KEEP backups<\/a> from rman are used to provide <a href=\"https:\/\/docs.oracle.com\/en\/database\/oracle\/oracle-database\/19\/bradv\/backing-up-database.html#GUID-8894680E-8BBA-475D-8815-D789C1A04FD9\" target=\"_blank\" rel=\"noopener noreferrer\">long-term and archival retention<\/a>. They are used to bypass the default policy retention and are used to sustain some regulations\/compliances (like HIPAA, or others) that require archival retention. But with ZDLRA they are treated in a different way. Here I will show how the KEEP backups can impact your backup strategy for ZDLRA.<\/p>\n<p><a href=\"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg\" target=\"_blank\" rel=\"noopener noreferrer\"><img loading=\"lazy\" decoding=\"async\" class=\"aligncenter wp-image-824 size-full\" src=\"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg\" alt=\"\" width=\"500\" height=\"300\" srcset=\"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg 500w, https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup-300x180.jpg 300w\" sizes=\"auto, (max-width: 500px) 100vw, 500px\" \/><\/a><\/p>\n<p style=\"text-align: justify;\"><!--more Click here to read more...--><\/p>\n<p>Below, the database ORCL19C was recently added and there is no backup for this database registered inside of ZDLRA.<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">[oracle@orcloel7 ~]$ rman target=\/ catalog=vpcbronze\/vpcbronze@zdlras1-scan:1521\/zdlras1\r\n\r\nRecovery Manager: Release 19.0.0.0.0 - Production on Sat Oct 24 20:55:46 2020\r\nVersion 19.3.0.0.0\r\n\r\nCopyright (c) 1982, 2019, Oracle and\/or its affiliates.  All rights reserved.\r\n\r\nconnected to target database: ORCL19C (DBID=1487680695)\r\nconnected to recovery catalog database\r\n\r\nRMAN&gt; list backup of datafile 1 device type sbt_tape;\r\n\r\nspecification does not match any backup in the repository\r\n\r\nRMAN&gt;<\/pre>\n<p style=\"text-align: justify;\">And inside of ZDLRA, you can see that there are no backups:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">SQL&gt; select DB_KEY from ra_database where DB_UNIQUE_NAME = 'ORCL19C';\r\n\r\n    DB_KEY\r\n----------\r\n     14577\r\n\r\nSQL&gt; select DBINC_KEY from rc_database where db_key = 14577;\r\n\r\n DBINC_KEY\r\n----------\r\n     14578\r\n\r\nSQL&gt; select count(*) from vbdf where DB_KEY = 14577;\r\n\r\n  COUNT(*)\r\n----------\r\n         0\r\n\r\nSQL&gt; select count(*) from plans where DB_KEY = 14577;\r\n\r\n  COUNT(*)\r\n----------\r\n         0\r\n\r\nSQL&gt; select DB_KEY, SPACE_USAGE, KEEP_SPACE from ra_database where DB_UNIQUE_NAME = 'ORCL19C';\r\n\r\n    DB_KEY SPACE_USAGE KEEP_SPACE\r\n---------- ----------- ----------\r\n     14577           0          0\r\n\r\n\r\nSQL&gt;<\/pre>\n<p style=\"text-align: justify;\">And as you can see above, at table <a href=\"https:\/\/docs.oracle.com\/en\/engineered-systems\/zero-data-loss-recovery-appliance\/19.2\/amagd\/amagd_views.html#GUID-AD69194F-B474-4EFC-B05F-737E0C12BF17\" target=\"_blank\" rel=\"noopener noreferrer\">RA_DATABASE<\/a> there is column KEEP_SPACE to report the space used by keep backups.<\/p>\n<p style=\"text-align: justify;\">So, we can do the first keep backup (I made just for the datafile 1):<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">RMAN&gt; BACKUP INCREMENTAL LEVEL 0 DEVICE TYPE SBT FILESPERSET 1 DATAFILE 1 TAG 'KEEPDF1' KEEP FOREVER;\r\n\r\nStarting backup at 24\/10\/2020 22:38:54\r\n\r\nallocated channel: ORA_SBT_TAPE_1\r\nchannel ORA_SBT_TAPE_1: SID=71 device type=SBT_TAPE\r\nchannel ORA_SBT_TAPE_1: RA Library (ZDLRAS1) SID=B271AF93A734380EE053010310AC1736\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting incremental level 0 datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\ninput datafile file number=00001 name=\/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 22:38:57\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 22:40:52\r\npiece handle=ORCL19C_c3vdq8s1_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:01:55\r\ncurrent log archived\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting archived log backup set\r\nchannel ORA_SBT_TAPE_1: specifying archived log(s) in backup set\r\ninput archived log thread=1 sequence=96 RECID=155 STAMP=1054680052\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 22:40:54\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 22:41:01\r\npiece handle=ORCL19C_c4vdq8vm_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:07\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting full datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\nincluding current SPFILE in backup set\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 22:41:02\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 22:41:03\r\npiece handle=ORCL19C_c5vdq8vu_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:01\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting full datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\nincluding current control file in backup set\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 22:41:05\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 22:41:08\r\npiece handle=ORCL19C_c6vdq900_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:03\r\nFinished backup at 24\/10\/2020 22:41:08\r\n\r\nRMAN&gt; list backup of datafile 1 device type sbt_tape;\r\n\r\n\r\nList of Backup Sets\r\n===================\r\n\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15685   Incr 0  783.25M    SBT_TAPE    00:01:44     24\/10\/2020 22:40:41\r\n        BP Key: 15686   Status: AVAILABLE  Compressed: NO  Tag: KEEPDF1\r\n        Handle: ORCL19C_c3vdq8s1_1_1   Media: Recovery Appliance (ZDLRAS1)\r\n        Keep: BACKUP_LOGS        Until: FOREVER\r\n  List of Datafiles in backup set 15685\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2676322    24\/10\/2020 22:38:57              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nRMAN&gt;<\/pre>\n<p style=\"text-align: justify;\">Above, you can see that \u201cHandle\u201d does not report \u201cVB$_\u201d as normal virtual backups managed by ZDLRA. And if we look at internals tables of ZDLRA the backup was not used to generate ant virtual full backup:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">SQL&gt; select DB_KEY, SPACE_USAGE, KEEP_SPACE from ra_database where DB_UNIQUE_NAME = 'ORCL19C';\r\n\r\n    DB_KEY SPACE_USAGE KEEP_SPACE\r\n---------- ----------- ----------\r\n     14577   .79296875  .79296875\r\n\r\nSQL&gt;\r\nSQL&gt; select count(*) from plans where DB_KEY = 14577;\r\n\r\n  COUNT(*)\r\n----------\r\n         0\r\n\r\nSQL&gt; select count(*) from vbdf where DB_KEY = 14577;\r\n\r\n  COUNT(*)\r\n----------\r\n         0\r\n\r\nSQL&gt;\r\nSQL&gt; select DBINC_KEY from rc_database where db_key = 14577;\r\n\r\n DBINC_KEY\r\n----------\r\n     14578\r\n\r\nSQL&gt;\r\nSQL&gt; select DF_KEY from df where DBINC_KEY = 14578 and file# = 1;\r\n\r\n    DF_KEY\r\n----------\r\n     14590\r\n\r\nSQL&gt;\r\n\r\nSQL&gt; select count(*) from blocks where DF_KEY = 14590;\r\n\r\n  COUNT(*)\r\n----------\r\n         0\r\n\r\nSQL&gt;<\/pre>\n<p style=\"text-align: justify;\">To be clear, this is was expected since the KEEP backups, even in traditional, rman scenarios (with the third-party backup appliance) are not considered as part of the backup workflow. This means that if I do one incremental backup, the keep is not considered a valid parent backup.<\/p>\n<p style=\"text-align: justify;\">The same is valid at ZDLRA, as you can see below I made a subsequent level 1 backup for the datafile 1 and no parent backups were found:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">RMAN&gt; BACKUP INCREMENTAL LEVEL 1 DEVICE TYPE SBT FILESPERSET 1 DATAFILE 1 TAG 'DF1';\r\n\r\nStarting backup at 24\/10\/2020 22:54:28\r\nallocated channel: ORA_SBT_TAPE_1\r\nchannel ORA_SBT_TAPE_1: SID=34 device type=SBT_TAPE\r\nchannel ORA_SBT_TAPE_1: RA Library (ZDLRAS1) SID=B271E73EF4373B90E053010310AC6873\r\nno parent backup or copy of datafile 1 found\r\nchannel ORA_SBT_TAPE_1: starting incremental level 0 datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\ninput datafile file number=00001 name=\/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 22:54:30\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 22:56:35\r\npiece handle=ORCL19C_c7vdq9p6_1_1 tag=DF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:02:05\r\nFinished backup at 24\/10\/2020 22:56:35\r\n\r\nStarting Control File and SPFILE Autobackup at 24\/10\/2020 22:56:35\r\npiece handle=c-1487680695-20201024-06 comment=API Version 2.0,MMS Version 12.2.0.2\r\nFinished Control File and SPFILE Autobackup at 24\/10\/2020 22:56:44\r\n\r\nRMAN&gt;<\/pre>\n<p style=\"text-align: justify;\">And internally at ZDLRA, you can see that this backup without a keep, was used to generate virtual backups:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">SQL&gt; select count(*) from vbdf where DB_KEY = 14577;\r\n\r\n  COUNT(*)\r\n----------\r\n         1\r\n\r\nSQL&gt; select count(*) from blocks where DF_KEY = 14590;\r\n\r\n  COUNT(*)\r\n----------\r\n    100251\r\n\r\nSQL&gt; select DB_KEY, SPACE_USAGE, KEEP_SPACE from ra_database where DB_UNIQUE_NAME = 'ORCL19C';\r\n\r\n    DB_KEY SPACE_USAGE KEEP_SPACE\r\n---------- ----------- ----------\r\n     14577  1.27265625  .79296875\r\n\r\nSQL&gt;<\/pre>\n<p style=\"text-align: justify;\">So, at this moment we have keep and virtual backup:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">RMAN&gt; list backup of datafile 1 device type sbt_tape;\r\n\r\n\r\nList of Backup Sets\r\n===================\r\n\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15685   Incr 0  783.25M    SBT_TAPE    00:01:44     24\/10\/2020 22:40:41\r\n        BP Key: 15686   Status: AVAILABLE  Compressed: NO  Tag: KEEPDF1\r\n        Handle: ORCL19C_c3vdq8s1_1_1   Media: Recovery Appliance (ZDLRAS1)\r\n        Keep: BACKUP_LOGS        Until: FOREVER\r\n  List of Datafiles in backup set 15685\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2676322    24\/10\/2020 22:38:57              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15776   Incr 0  325.05M    SBT_TAPE    00:01:59     24\/10\/2020 22:56:29\r\n        BP Key: 15777   Status: AVAILABLE  Compressed: YES  Tag: DF1\r\n        Handle: VB$_1918343643_15775I   Media:\r\n  List of Datafiles in backup set 15776\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2678532    24\/10\/2020 22:54:30              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nRMAN&gt;<\/pre>\n<p style=\"text-align: justify;\">But during the normal database life (after several backups are done) is possible\/needed to do some keep backup. Fortunately, since the keep backup does not affect the incremental forever strategy, we can have it without collateral effect. Even doing a level 0 backup, the virtual full backups continue to work:<\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"raw\">RMAN&gt; BACKUP INCREMENTAL LEVEL 0 DEVICE TYPE SBT FILESPERSET 1 DATAFILE 1 TAG 'KEEPDF1' KEEP FOREVER;\r\n\r\nStarting backup at 24\/10\/2020 23:01:29\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting incremental level 0 datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\ninput datafile file number=00001 name=\/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 23:01:29\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 23:03:24\r\npiece handle=ORCL19C_c9vdqa69_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:01:55\r\ncurrent log archived\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting archived log backup set\r\nchannel ORA_SBT_TAPE_1: specifying archived log(s) in backup set\r\ninput archived log thread=1 sequence=97 RECID=156 STAMP=1054681404\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 23:03:27\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 23:03:34\r\npiece handle=ORCL19C_cavdqa9v_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:07\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting full datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\nincluding current SPFILE in backup set\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 23:03:35\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 23:03:42\r\npiece handle=ORCL19C_cbvdqaa7_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:07\r\n\r\nusing channel ORA_SBT_TAPE_1\r\nbackup will never be obsolete\r\narchived logs required to recover from this backup will be backed up\r\nchannel ORA_SBT_TAPE_1: starting full datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\nincluding current control file in backup set\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 23:03:44\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 23:03:47\r\npiece handle=ORCL19C_ccvdqaaf_1_1 tag=KEEPDF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:03\r\nFinished backup at 24\/10\/2020 23:03:47\r\n\r\nRMAN&gt; BACKUP INCREMENTAL LEVEL 0 DEVICE TYPE SBT FILESPERSET 1 DATAFILE 1 TAG 'DF1';\r\n\r\nStarting backup at 24\/10\/2020 23:05:16\r\nusing channel ORA_SBT_TAPE_1\r\nchannel ORA_SBT_TAPE_1: starting incremental level 1 datafile backup set\r\nchannel ORA_SBT_TAPE_1: specifying datafile(s) in backup set\r\ninput datafile file number=00001 name=\/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\nchannel ORA_SBT_TAPE_1: starting piece 1 at 24\/10\/2020 23:06:44\r\nchannel ORA_SBT_TAPE_1: finished piece 1 at 24\/10\/2020 23:06:45\r\npiece handle=ORCL19C_cevdqag4_1_1 tag=DF1 comment=API Version 2.0,MMS Version 12.2.0.2\r\nchannel ORA_SBT_TAPE_1: backup set complete, elapsed time: 00:00:01\r\nFinished backup at 24\/10\/2020 23:06:45\r\n\r\nStarting Control File and SPFILE Autobackup at 24\/10\/2020 23:06:45\r\npiece handle=c-1487680695-20201024-07 comment=API Version 2.0,MMS Version 12.2.0.2\r\nFinished Control File and SPFILE Autobackup at 24\/10\/2020 23:06:49\r\n\r\nRMAN&gt; list backup of datafile 1 device type sbt_tape;\r\n\r\n\r\nList of Backup Sets\r\n===================\r\n\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15685   Incr 0  783.25M    SBT_TAPE    00:01:44     24\/10\/2020 22:40:41\r\n        BP Key: 15686   Status: AVAILABLE  Compressed: NO  Tag: KEEPDF1\r\n        Handle: ORCL19C_c3vdq8s1_1_1   Media: Recovery Appliance (ZDLRAS1)\r\n        Keep: BACKUP_LOGS        Until: FOREVER\r\n  List of Datafiles in backup set 15685\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2676322    24\/10\/2020 22:38:57              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15776   Incr 0  325.05M    SBT_TAPE    00:01:59     24\/10\/2020 22:56:29\r\n        BP Key: 15777   Status: AVAILABLE  Compressed: YES  Tag: DF1\r\n        Handle: VB$_1918343643_15775I   Media:\r\n  List of Datafiles in backup set 15776\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2678532    24\/10\/2020 22:54:30              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15781   Incr 0  783.25M    SBT_TAPE    00:01:45     24\/10\/2020 23:03:14\r\n        BP Key: 15782   Status: AVAILABLE  Compressed: NO  Tag: KEEPDF1\r\n        Handle: ORCL19C_c9vdqa69_1_1   Media: Recovery Appliance (ZDLRAS1)\r\n        Keep: BACKUP_LOGS        Until: FOREVER\r\n  List of Datafiles in backup set 15781\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2679717    24\/10\/2020 23:01:29              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15895   Incr 1  48.00K     SBT_TAPE    00:00:04     24\/10\/2020 23:06:48\r\n        BP Key: 15896   Status: AVAILABLE  Compressed: YES  Tag: DF1\r\n        Handle: VB$_1918343643_15894I   Media:\r\n  List of Datafiles in backup set 15895\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    1  Incr 2680540    24\/10\/2020 23:06:44              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nBS Key  Type LV Size       Device Type Elapsed Time Completion Time\r\n------- ---- -- ---------- ----------- ------------ -------------------\r\n15899   Incr 0  323.93M    SBT_TAPE    00:00:04     24\/10\/2020 23:06:48\r\n        BP Key: 15900   Status: AVAILABLE  Compressed: YES  Tag: DF1\r\n        Handle: VB$_1918343643_15894_1   Media:\r\n  List of Datafiles in backup set 15899\r\n  File LV Type Ckp SCN    Ckp Time            Abs Fuz SCN Sparse Name\r\n  ---- -- ---- ---------- ------------------- ----------- ------ ----\r\n  1    0  Incr 2680540    24\/10\/2020 23:06:44              NO    \/u01\/app\/oracle\/oradata\/ORCL19C\/system01.dbf\r\n\r\nRMAN&gt;<\/pre>\n<p style=\"text-align: justify;\">Above you can notice that I made one keep backup level 0 for datafile 1 and after that, I made a new level 1 backup. But the virtual full backup was generated correctly meaning that the \u201ckeep level 0\u201d not affect the normal ZDLRA behavior.<\/p>\n<p style=\"text-align: justify;\">So, the KEEP backup not affect the incremental forever strategy even when taken when you already stored backups at ZDLRA. They are stored at the ZDLRA delta store, consume space, but are treated as a separate thread.<\/p>\n<p style=\"text-align: justify;\">&nbsp;<\/p>\n<p style=\"text-align: justify;\"><strong>Disclaimer<\/strong>: <em>\u201cThe postings on this site are my own and don\u2019t necessarily represent my actual employer positions, strategies or opinions. The information here was edited to be useful for general purpose, specific data and identifications were removed to allow reach the generic audience and to be useful for the community. Post protected by copyright.\u201d<\/em><\/p>\n","protected":false},"excerpt":{"rendered":"<p>KEEP backups from rman are used to provide long-term and archival retention. They are used to bypass the default policy retention and are used to sustain some regulations\/compliances (like HIPAA, or others) that require archival retention. But with ZDLRA they are treated in a different way. Here I will show how the KEEP backups can [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ngg_post_thumbnail":0,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_feature_clip_id":0,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2},"jetpack_post_was_ever_published":false},"categories":[44,29,77,5,91,106,51],"tags":[93,100,155,65,74],"class_list":["post-823","post","type-post","status-publish","format-standard","hentry","category-backup","category-database","category-engineeredsystems","category-oracle","category-rman","category-virtual-full-backup","category-zdlra","tag-backup","tag-engineered-systems","tag-keep","tag-oracle","tag-zdlra"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v28.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>KEEP backups and ZDLRA - Fernando Simon<\/title>\n<meta name=\"description\" content=\"How KEEP backups from rman affects (or no) the incremental forever strategy and virtual backups of the ZDLRA.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"KEEP backups and ZDLRA - Fernando Simon\" \/>\n<meta property=\"og:description\" content=\"How KEEP backups from rman affects (or no) the incremental forever strategy and virtual backups of the ZDLRA.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/\" \/>\n<meta property=\"og:site_name\" content=\"Fernando Simon\" \/>\n<meta property=\"article:published_time\" content=\"2020-11-02T23:48:23+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg\" \/>\n<meta name=\"author\" content=\"Simon\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Simon\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"12 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/\"},\"author\":{\"name\":\"Simon\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/#\\\/schema\\\/person\\\/386da956604bca0d5be5dd52210c1dd9\"},\"headline\":\"KEEP backups and ZDLRA\",\"datePublished\":\"2020-11-02T23:48:23+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/\"},\"wordCount\":459,\"commentCount\":4,\"image\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/10\\\/Archive_backup.jpg\",\"keywords\":[\"backup\",\"Engineered Systems\",\"Keep\",\"Oracle\",\"ZDLRA\"],\"articleSection\":[\"Backup\",\"Database\",\"Engineered Systems\",\"Oracle\",\"RMAN\",\"Virtual Full Backup\",\"ZDLRA\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/\",\"url\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/\",\"name\":\"KEEP backups and ZDLRA - Fernando Simon\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/10\\\/Archive_backup.jpg\",\"datePublished\":\"2020-11-02T23:48:23+00:00\",\"author\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/#\\\/schema\\\/person\\\/386da956604bca0d5be5dd52210c1dd9\"},\"description\":\"How KEEP backups from rman affects (or no) the incremental forever strategy and virtual backups of the ZDLRA.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/10\\\/Archive_backup.jpg\",\"contentUrl\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/wp-content\\\/uploads\\\/2020\\\/10\\\/Archive_backup.jpg\",\"width\":500,\"height\":300},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/keep-backups-and-zdlra\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"KEEP backups and ZDLRA\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/\",\"name\":\"Fernando Simon\",\"description\":\"Have you hugged your backup today?\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/#\\\/schema\\\/person\\\/386da956604bca0d5be5dd52210c1dd9\",\"name\":\"Simon\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/a3dbc48de62fffb1829befb4a588d789ec6dc5e05977afabb3407a5f37a16482?s=96&d=mm&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/a3dbc48de62fffb1829befb4a588d789ec6dc5e05977afabb3407a5f37a16482?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/a3dbc48de62fffb1829befb4a588d789ec6dc5e05977afabb3407a5f37a16482?s=96&d=mm&r=g\",\"caption\":\"Simon\"},\"sameAs\":[\"http:\\\/\\\/www.fernandosimon.com\"],\"url\":\"https:\\\/\\\/www.fernandosimon.com\\\/blog\\\/author\\\/simon\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"KEEP backups and ZDLRA - Fernando Simon","description":"How KEEP backups from rman affects (or no) the incremental forever strategy and virtual backups of the ZDLRA.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/","og_locale":"en_US","og_type":"article","og_title":"KEEP backups and ZDLRA - Fernando Simon","og_description":"How KEEP backups from rman affects (or no) the incremental forever strategy and virtual backups of the ZDLRA.","og_url":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/","og_site_name":"Fernando Simon","article_published_time":"2020-11-02T23:48:23+00:00","og_image":[{"url":"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg","type":"","width":"","height":""}],"author":"Simon","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Simon","Est. reading time":"12 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#article","isPartOf":{"@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/"},"author":{"name":"Simon","@id":"https:\/\/www.fernandosimon.com\/blog\/#\/schema\/person\/386da956604bca0d5be5dd52210c1dd9"},"headline":"KEEP backups and ZDLRA","datePublished":"2020-11-02T23:48:23+00:00","mainEntityOfPage":{"@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/"},"wordCount":459,"commentCount":4,"image":{"@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#primaryimage"},"thumbnailUrl":"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg","keywords":["backup","Engineered Systems","Keep","Oracle","ZDLRA"],"articleSection":["Backup","Database","Engineered Systems","Oracle","RMAN","Virtual Full Backup","ZDLRA"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/","url":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/","name":"KEEP backups and ZDLRA - Fernando Simon","isPartOf":{"@id":"https:\/\/www.fernandosimon.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#primaryimage"},"image":{"@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#primaryimage"},"thumbnailUrl":"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg","datePublished":"2020-11-02T23:48:23+00:00","author":{"@id":"https:\/\/www.fernandosimon.com\/blog\/#\/schema\/person\/386da956604bca0d5be5dd52210c1dd9"},"description":"How KEEP backups from rman affects (or no) the incremental forever strategy and virtual backups of the ZDLRA.","breadcrumb":{"@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#primaryimage","url":"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg","contentUrl":"https:\/\/www.fernandosimon.com\/blog\/wp-content\/uploads\/2020\/10\/Archive_backup.jpg","width":500,"height":300},{"@type":"BreadcrumbList","@id":"https:\/\/www.fernandosimon.com\/blog\/keep-backups-and-zdlra\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.fernandosimon.com\/blog\/"},{"@type":"ListItem","position":2,"name":"KEEP backups and ZDLRA"}]},{"@type":"WebSite","@id":"https:\/\/www.fernandosimon.com\/blog\/#website","url":"https:\/\/www.fernandosimon.com\/blog\/","name":"Fernando Simon","description":"Have you hugged your backup today?","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.fernandosimon.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Person","@id":"https:\/\/www.fernandosimon.com\/blog\/#\/schema\/person\/386da956604bca0d5be5dd52210c1dd9","name":"Simon","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/a3dbc48de62fffb1829befb4a588d789ec6dc5e05977afabb3407a5f37a16482?s=96&d=mm&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/a3dbc48de62fffb1829befb4a588d789ec6dc5e05977afabb3407a5f37a16482?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/a3dbc48de62fffb1829befb4a588d789ec6dc5e05977afabb3407a5f37a16482?s=96&d=mm&r=g","caption":"Simon"},"sameAs":["http:\/\/www.fernandosimon.com"],"url":"https:\/\/www.fernandosimon.com\/blog\/author\/simon\/"}]}},"jetpack_publicize_connections":[],"jetpack_sharing_enabled":true,"jetpack_shortlink":"https:\/\/wp.me\/p5ofTp-dh","jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/posts\/823","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/comments?post=823"}],"version-history":[{"count":0,"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/posts\/823\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/media?parent=823"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/categories?post=823"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.fernandosimon.com\/blog\/wp-json\/wp\/v2\/tags?post=823"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}