Home » RDBMS Server » Backup & Recovery » RMAN recovery question
RMAN recovery question [message #213209] Tue, 09 January 2007 17:59 Go to next message
oracle_scorpiongirl
Messages: 39
Registered: November 2005
Member
I am very new to RMAN. I did all these by just reading what I need to know to create these. I am not confident with this whole thing being right. Can someone please validate or suggest and clarify one doubt?

I created a RMAN level 0 and leve l1 script. once level0 and level1 backups were created(in flash recovery area), I removed EVERYTHING from ASM's data group and everything(but the backups) from flash recovery area.
Did the recovery this way:
1) tried "restore spfile from autobackup" - but this did not work
this is the message I got:
Starting restore at 09-JAN-07
using channel ORA_DISK_1
channel ORA_DISK_1: looking for autobackup on day: 20070109
channel ORA_DISK_1: looking for autobackup on day: 20070108
channel ORA_DISK_1: looking for autobackup on day: 20070107
channel ORA_DISK_1: looking for autobackup on day: 20070106
channel ORA_DISK_1: looking for autobackup on day: 20070105
channel ORA_DISK_1: looking for autobackup on day: 20070104
channel ORA_DISK_1: looking for autobackup on day: 20070103
channel ORA_DISK_1: no autobackup in 7 days found
RMAN-00571: ====================================================
RMAN-00569: ======= ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ====================================================
RMAN-03002: failure of restore command at 01/09/2007 08:14:11
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece

All I understood was that the backup is there, but the handle is wrong. Not sure which one I should set/change(please see my RMAN configuration below)
I had to give the full path of the location of the autobackup in flash recoveryarea:
restore spfile from +FRA/dbname/autobackup/2007_01_09/s-xxxxxxxxx_xxx_xxxxxxxxx’;

2) startup nomount
3) restore controlfile from autobackup - this worked just fine
4) mount
5) restore database;
6) recover database;
7) alter database open resetlogs;
and take a full backup

why did the error in step 1 happen?

RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION ON; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP ON; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default

DO I have to set these to backup everything to flash recovery area (and not to a disk location)
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT CLEAR; -- to use FRA instead of disk location for backup
CONFIGURE CONTROLFILE AUTOBACKUP FOR DEVICE TYPE DISK TO '+FRA';

also please correct any of the rman configuration that needs to be changed(to backup to the ASM flash recovery area)
Please clarify. Thanks
Re: RMAN recovery question [message #213212 is a reply to message #213209] Tue, 09 January 2007 18:26 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
by default RMAN will be looking into $ORACLE_HOME/dbs
Check the value for db_recovery_file_dest.
And the correct syntax would be
RMAN> restore spfile from autobackup db_recovery_file_dest='full path for flashrecoveryareas' db_name='yourdb';
Re: RMAN recovery question [message #213327 is a reply to message #213209] Wed, 10 January 2007 05:57 Go to previous messageGo to next message
oracle_scorpiongirl
Messages: 39
Registered: November 2005
Member
db_recovery_file_dest='+FRA'

but one of the error msgs, unable to find backup in '+FRA'. But at that time I was trying to figure out how to get it to work. so I did
restore spfile from '+FRA';
and finally realized that I have to give the full path.
But according to what you said, my flash recovery area is '+FRA'. but still I have to give the FULL path in the restore command. is that correct?
and I set the dbid before doing the restore. So, it is right that I don't have to give the dbname in the command line again.
Thanks
Re: RMAN recovery question [message #213329 is a reply to message #213212] Wed, 10 January 2007 05:58 Go to previous messageGo to next message
oracle_scorpiongirl
Messages: 39
Registered: November 2005
Member
And could you also clarify this Q for me:
RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION ON; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP ON; # default
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '%F'; # default
CONFIGURE DEVICE TYPE DISK PARALLELISM 1 BACKUP TYPE TO BACKUPSET; # default
CONFIGURE DATAFILE BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE ARCHIVELOG BACKUP COPIES FOR DEVICE TYPE DISK TO 1; # default
CONFIGURE MAXSETSIZE TO UNLIMITED; # default
CONFIGURE ENCRYPTION FOR DATABASE OFF; # default
CONFIGURE ENCRYPTION ALGORITHM 'AES128'; # default
CONFIGURE ARCHIVELOG DELETION POLICY TO NONE; # default

DO I have to set these to backup everything to flash recovery area (and not to a disk location)
CONFIGURE CHANNEL DEVICE TYPE DISK FORMAT CLEAR; -- to use FRA instead of disk location for backup
CONFIGURE CONTROLFILE AUTOBACKUP FOR DEVICE TYPE DISK TO '+FRA';

any thing that needs modification/addition?
Thanks again
Re: RMAN recovery question [message #213330 is a reply to message #213327] Wed, 10 January 2007 05:58 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
You have to give the full path and you need to give the dbname.
Check documentation.
Re: RMAN recovery question [message #213332 is a reply to message #213329] Wed, 10 January 2007 06:03 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
>> DO I have to set these to backup everything to flash recovery area (and not to a disk location)
As we said earlier,
flash_recovery_area should be seperated from the regular backup destination.
Flash recovery area is usually in a local disk.
backup destination should be in a seperate disk ( you don't want to loose them all together). Having a seperate disk for archvielogs and backups are recomended. In case of using RAC, these areas should be shared between the nodes. Later if you want to use RMAN duplication, a seperate shared disk is easy to be crossmounted.
Re: RMAN recovery question [message #213383 is a reply to message #213209] Wed, 10 January 2007 09:07 Go to previous messageGo to next message
oracle_scorpiongirl
Messages: 39
Registered: November 2005
Member
OK. Apologize. I should have been more clear. I don't have the archivelogs and the rman backups in the same location

This is what is there in my asm diskgroups:
ASMCMD> pwd
+DATA/TESTDB
ASMCMD> ls
1_1_611401220.dbf
1_2_611401220.dbf
1_3_611401220.dbf
1_43_611051790.dbf
1_4_611401220.dbf
2_1_611401220.dbf
2_2_611401220.dbf
2_3_611401220.dbf
2_4_611401220.dbf
2_5_611401220.dbf
2_81_611051790.dbf
ARCHIVELOG/
CONTROLFILE/
DATAFILE/
ONLINELOG/
TEMPFILE/
spfileractest.ora


ASMCMD> pwd
+FRA/TESTDB
ASMCMD> ls
AUTOBACKUP/
BACKUPSET/
CHANGETRACKING/
CONTROLFILE/
FLASHBACK/
ONLINELOG/

For some reason I was thinking that my archivelogs will go to the flash recovery area(FRA). So, I initially decided to have RMAN backups in a seperate disk location. But after I saw the contents of the diskgroups, I decided to have the RMAN backups in FRA. (probably should have researched more on the archivelogs being in DATA group)...or, is it how files are placed when I select DATA group as the database area for OMF location and FRA group for the flash recovery area?

so if my file placements are correct, then is my question about RMAN configuration valid? abt having to CLEAR few of them I mentioned earlier to backup to FRA instead of disk location?

One more question. What are those .dbf files in the DATA group? I believe the database datafiles are in the DATAFILE directory underneath.
Thanks Mahesh
Re: RMAN recovery question [message #213387 is a reply to message #213383] Wed, 10 January 2007 09:37 Go to previous messageGo to next message
Mahesh Rajendran
Messages: 10707
Registered: March 2002
Location: oracleDocoVille
Senior Member
Account Moderator
>> For some reason I was thinking that my archivelogs will go to the flash recovery area(FRA)
Nope. the destination is determined archive_log_dest*
>> I don't have the archivelogs and the rman backups in the same location
I was talking about the same ***disk*** for the obvious performance issues and dependency.
Those dbf files are datafiles.
Overall it looks good. I myself have no ASM based RMAN system right now. Will setup a test case and
see how it goes.
Re: RMAN recovery question [message #213393 is a reply to message #213209] Wed, 10 January 2007 09:53 Go to previous message
oracle_scorpiongirl
Messages: 39
Registered: November 2005
Member
OK. That is true. I can change the location. Thanks

And yeah, those are seperate disks. Well, (I am not a very good hardware person), but I had 3 LUNS, created partitions, mapped raw devices to it and used them for the disk groups. And if I am not wrong, data and recovery were from different LUNS. (hope that will help)

Nice. Please let me know how it goes.
Thanks

Previous Topic: RMAN recovery scenario and clarification
Next Topic: rman error - RMAN-03009
Goto Forum:
  


Current Time: Mon Apr 29 23:22:19 CDT 2024