RMAN Incremental Merge backup

All posts relating to Oracle database administration.

Moderator: Tim...

RMAN Incremental Merge backup

Postby sivakumarocp » Tue Dec 24, 2013 3:01 am

Hi Tim,

I would like to know, which restoration method is fast.

1. Restoring from RMAN Full backup (or)
2. Restoring from RMAN Image copy

I have another question,

In Incremental merge backup, when we run the below command for the first time it will perform FULL backup (Image copy)
Code: Select all
BACKUP INCREMENTAL LEVEL 1 FOR RECOVER OF COPY WITH TAG "INCR_MERGE" DATABASE;
RECOVER COPY OF DATABASE WITH TAG "INCR_MERGE" ;

then the second day it will perform just incremental backup and the 3rd day it will merge the 2nd day backup with the Previous FULL backup and then perform incremental backup and the same will goes on everyday.

here my question is, will we have every day FULL backup + one Incremental backup (or) only FULL backup.
Regards
Sivakumar.A
www.sivakumardba.com
sivakumarocp
Advisor
 
Posts: 256
Joined: Sat Jun 27, 2009 3:53 am
Location: India

Re: RMAN Incremental Merge backup

Postby Tim... » Tue Dec 24, 2013 11:01 am

Hi.

1) Typically a restore from an image copy backup will be quicker, because it is just copying the file, rather than rebuilding it. Actually, if you want you can just SWITCH to the image copy and recover it, so you don't even have the restore time, but then you lose your backup file, as it is now the actual data file. :)

2) I think you mean "incrementally updated backups".

The command you've posted will not do what you want. On the "RECOVER COPY OF DATABASE" command, you need to specify an UNTIL TIME. If not, it will recover all the way up to the latest backup, thereby losing your two day window. So for instance, this will give you a two day window.

Code: Select all
RECOVER COPY OF DATABASE WITH TAG 'incr_backup' UNTIL TIME 'SYSDATE-7';


Unless there is a different restore requirement, I tend to role with the following backup, giving me a 7 day window.

Code: Select all
RUN {
  RECOVER COPY OF DATABASE WITH TAG 'incr_backup' UNTIL TIME 'SYSDATE-7';
  BACKUP INCREMENTAL LEVEL 1 FOR RECOVER OF COPY WITH TAG 'incr_backup' DATABASE;
  BACKUP DEVICE TYPE DISK TAG 'incr_backup' ARCHIVELOG ALL NOT BACKED UP DELETE ALL INPUT;
  DELETE NOPROMPT OBSOLETE DEVICE TYPE DISK;
}


Cheers

Tim...
Tim...
Oracle ACE Director
Oracle ACE of the Year 2006 - Oracle Magazine Editors Choice Awards
OakTable Member
OCP DBA 7.3, 8, 8i, 9i, 10g, 11g
OCP Advanced PL/SQL Developer
Oracle Database: SQL Certified Expert
My website: http://www.oracle-base.com
My blog: http://www.oracle-base.com/blog
Tim...
Site Admin
 
Posts: 17953
Joined: Mon Nov 01, 2004 5:56 pm
Location: England, UK

Re: RMAN Incremental Merge backup

Postby sivakumarocp » Wed Dec 25, 2013 6:01 am

Hi Tim,

1) I will be taking Image copy directly to TAPE drive so I can't switch backups to image copy directly instead I need to restore it. so I assume restoring datafiles from Image copy will be much quicker from the RMAN backups. correct me if I am wrong.

2) In our environment all the database we are taking only FULL database backup on every day. so I thought if we could implement this Incremental Merge feature then we could reduce the Backup time atleast.

If we give UNTIL time clause along with the "RECOVER COPY OF DATABASE" command it will recover the incremental backups to the specified date. say for example If I am giving SYSDATE-7 then RMAN will recover incremental backups older than 7 days and I will be having 7 days of Incremental backups with me. (correct me If I am wrong here)

The reason why we are taking full DB backup on every day is to Increase the restore and recover time.
so if I don't give the UNTIL clause with "RECOVER COPY OF DATABASE" command will It automatically merge the incremental backups which is taken on that day to the Previous FULL DB backup (i.e Image copy)

because I want my FULL DB backup to be update to date.
Regards
Sivakumar.A
www.sivakumardba.com
sivakumarocp
Advisor
 
Posts: 256
Joined: Sat Jun 27, 2009 3:53 am
Location: India

Re: RMAN Incremental Merge backup

Postby Tim... » Wed Dec 25, 2013 9:11 am

Hi.

1) Do you really mean directly to tape, or do you mean an image copy on the file system, which will then be saved to tape? If you mean directly to tape, then you can't use incrementally updated backups because you can't apply the incremental backup on to the image copy on a tape. If you mean updating the image copy on disk, then that's fine.

2) Incrementally updated backups will definitely improve backup time. Combined with block change tracking, some of our low-update databases take a couple of minutes to backup. The issue is, this is for disk based backups. You really need to invest in some more storage for this to work well.

3) Yes. You would have to recover all the incrementals to get up to date, but this is how incrementally updated backups work. You keep one full backup on disk, which is as old as the oldest point in time you want to recover to, then keep the incrementals to get you quickly to the latest date. If you plan to have up to date backups, the you need to keep copies of every day's backup offline, so in a recovery, you will have to retrieve them off tape, re-catalog them, then use them for a restore and recovery. Depending on the system used, this may take longer than applying the incrementals...

So in summary, for direct to tape, incrementally updated backups are not the way to go. The update (recovery) of the image copy *must* happen on disk.

Cheers

Tim...
Tim...
Oracle ACE Director
Oracle ACE of the Year 2006 - Oracle Magazine Editors Choice Awards
OakTable Member
OCP DBA 7.3, 8, 8i, 9i, 10g, 11g
OCP Advanced PL/SQL Developer
Oracle Database: SQL Certified Expert
My website: http://www.oracle-base.com
My blog: http://www.oracle-base.com/blog
Tim...
Site Admin
 
Posts: 17953
Joined: Mon Nov 01, 2004 5:56 pm
Location: England, UK


Return to Oracle Database Administration

Who is online

Users browsing this forum: No registered users and 2 guests