Home » RDBMS Server » Backup & Recovery » how do i apply an level_1 backup to a level_0 backup ? (oracle 9.2.0.7; aix platform)
how do i apply an level_1 backup to a level_0 backup ? [message #504602] Tue, 26 April 2011 13:35 Go to next message
cakeday
Messages: 31
Registered: May 2010
Member
hi all:

i have done many restores from a level 0 backup and restore it.

the way i have done this in the past is,
RESTORE THE CONTROL FILE FIRST using the block below. (The tag comes from the logfile of level_0 backup)
rman target / << EOF
set dbid = 2967781169;
run
{
allocate channel t1 type 'sbt_tape' parms 'ENV=(TDPO_OPTFILE=/u001/admin/adsmagent/tdpo.opt)';
#restore controlfile from autobackup db_recovery_file_dest='c-2967781169-20110419-01';
#restore controlfile FROM AUTOBACKUP;
restore controlfile FROM 'c-2967781169-20110421-01';
release channel t1;
}
EOF

AND THEN I RESTORE AND RECOVER THE DATABASE using the script below.
i pick the end time based on the logfile.


rman target / << EOF
run
{
set until time "to_date('21-apr-2011 23:00:00','dd-mon-yyyy hh24:mi:ss')";
allocate channel t1 type 'sbt_tape' parms 'ENV=(TDPO_OPTFILE=/u001/admin/adsmagent/tdpo.opt)';
#SET NEWNAME FOR DATAFILE '/u001/user/data002/perfstat_data_002.dbf' TO '/u001/data001/perfstat_data_002.dbf';
restore database;
recover database;
release channel t1;
}
EOF

BUT IF I WERE TO apply a level 1 backup to update this backup, do i still recover the db ?
Do i do restore of level 0, then restore of level 1, restore of level 1 and then eventually recover the db once ?


what i am trying to do is, move the db from one hardware to another.
but it is a large db, 700 gb -- so to cut down the outage time, i want to do the level 0 ahead of time, then keep applying level 1's so i can cutdown on the outage time.

thank you for all your help!
Re: how do i apply an level_1 backup to a level_0 backup ? [message #504604 is a reply to message #504602] Tue, 26 April 2011 13:45 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
BUT IF I WERE TO apply a level 1 backup to update this backup, do i still recover the db ?
Do i do restore of level 0, then restore of level 1, restore of level 1 and then eventually recover the db once ?

You have nothing to do, RMAN knows what it has to restore to recover the database.

Quote:
it is a large db, 700 gb -- so to cut down the outage time, i want to do the level 0 ahead of time, then keep applying level 1's so i can cutdown on the outage time.

Create a standby database for this.

Regards
Michel
Re: how do i apply an level_1 backup to a level_0 backup ? [message #504614 is a reply to message #504604] Tue, 26 April 2011 15:34 Go to previous messageGo to next message
cakeday
Messages: 31
Registered: May 2010
Member
hi Michel: thank you for your reply. we don't use dataguard, so creating a standby is out of question. this is the most preferred method here at this company. they are pretty old school!
Re: how do i apply an level_1 backup to a level_0 backup ? [message #504617 is a reply to message #504614] Tue, 26 April 2011 15:42 Go to previous messageGo to next message
BlackSwan
Messages: 26766
Registered: January 2009
Location: SoCal
Senior Member
STANDBY DB can exist without DATAGUARD.
Re: how do i apply an level_1 backup to a level_0 backup ? [message #504618 is a reply to message #504617] Tue, 26 April 2011 15:47 Go to previous messageGo to next message
cakeday
Messages: 31
Registered: May 2010
Member
thank you! I guess, we got a little off track here. can you please help me understand or point me in the right direction of how to apply a level 1 to a level 0, please.
thank yoU!
Re: how do i apply an level_1 backup to a level_0 backup ? [message #504644 is a reply to message #504618] Wed, 27 April 2011 00:57 Go to previous messageGo to next message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
You can't "apply" a level 1 on a level 0.

Regards
Michel
Re: how do i apply an level_1 backup to a level_0 backup ? [message #505386 is a reply to message #504602] Mon, 02 May 2011 14:09 Go to previous messageGo to next message
cgswong
Messages: 1
Registered: May 2011
Location: USA
Junior Member

Hi,

I think what you are perhaps trying to do is a merged incremental backup strategy. You take an initial level 0 backup, and then afterwards you take a level 1 backup in which case each level 1 is merged into the level 0 such that your last backup is current at the point of the level 1? However, this is done using disk devices (I'm not sure if it is possible using tape, or just not done due to performance issues).

merged incremental backup (MIB):
run {
backup incremental level 1 for recover of copy with tag 'MIB_LVL0' database;
recover copy of database with tag 'MIB_LVL0';
}

Recovery:
RECOVER COPY OF DATABASE WITH TAG 'MIB_LVL0' UNTIL TIME "SYSDATE-1";

Using the above commands RMAN automatically handles everything for you.

Hope this helps.

- Stu
Re: how do i apply an level_1 backup to a level_0 backup ? [message #505387 is a reply to message #505386] Mon, 02 May 2011 14:27 Go to previous message
Michel Cadot
Messages: 68641
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
1/ No this is not what he is trying to do; see the sentence: "AND THEN I RESTORE AND RECOVER THE DATABASE using the script below", retore and recover is already done with level 0 BEFORE any incremental.
2/ Merge is not available in version 9.2

Regards
Michel
Previous Topic: Error While backup on Windows 7 Client of Oracle 11gR2 Database
Next Topic: Trying to recover database after disk failure
Goto Forum:
  


Current Time: Thu Apr 18 12:06:12 CDT 2024