Home » RDBMS Server » Backup & Recovery » Oracle RMAN Recovery (oracle, 10.2.0.1.0,Windows XP)
Oracle RMAN Recovery [message #530540] Wed, 09 November 2011 00:47 Go to next message
umeshgupta1987
Messages: 4
Registered: November 2011
Junior Member
Environment:
oracle 10.2.0.1.0
Windows XP

I have taken the RMAN Full database backup through the following command.

My database is in no archivelog mode.

AT RMAN prompt
Shutdown immediate;
Startup mount;
run
{
allocate channel c01 device type disk format 'd:\rman_bkp\test_%U';
allocate channel c02 device type disk format 'd:\rman_bkp\test_%U';
backup full database tag 'full_bkup_test_081111';
backup current controlfile;
backup spfile;
release channel c01;
release channel c02;
}


Now i have deleted my all controlfile and spfile/Pfile from the database.

So how can i recover my SPfile and controlfile??
Please Suggest.!!

i do not have autobackup on of SPfile/Controlfile.


Regards

Umesh
Re: Oracle RMAN Recovery [message #530545 is a reply to message #530540] Wed, 09 November 2011 01:12 Go to previous messageGo to next message
Michel Cadot
Messages: 59290
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
restore controlfile from 'your backup file';


Read http://download.oracle.com/docs/cd/B19306_01/backup.102/b14194/rcmsynta051.htm#sthref796.

Regards
Michel


Re: Oracle RMAN Recovery [message #530549 is a reply to message #530545] Wed, 09 November 2011 01:34 Go to previous messageGo to next message
umeshgupta1987
Messages: 4
Registered: November 2011
Junior Member
Thanks Michel,

But i would i know the file name???

I have attached the snapshot of RMAN Backup.

Please Suggest..!!./fa/9546/0/


Regards

Umesh
  • Attachment: rman_bkp.JPG
    (Size: 59.59KB, Downloaded 414 times)
Re: Oracle RMAN Recovery [message #530552 is a reply to message #530549] Wed, 09 November 2011 01:42 Go to previous messageGo to next message
Michel Cadot
Messages: 59290
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
Quote:
Suggest..!!

Read your backup logs.
And for the future name the backups of your control file and spfile with a specific name.
Or better activate autobackup.

Most likely the 6MB files are control file backups and the 96KB ones are spfile backups.

And next time, use DOS and copy and paste the result in TEXT mode. No need to waste space
and network bandwidth for this.

Regards
Michel

[Updated on: Wed, 09 November 2011 01:42]

Report message to a moderator

Re: Oracle RMAN Recovery [message #530587 is a reply to message #530552] Wed, 09 November 2011 03:39 Go to previous messageGo to next message
umeshgupta1987
Messages: 4
Registered: November 2011
Junior Member
Thanks you Michel,

But my concern was like as i can restore any of my datafile which i have deleted.I have not given the path etc, like same cn't i do in case of control file.

coz with my RMAN backup log i have restored my SPFILE/ControlFile,But my concern was if i can restore them as well without giving any path that Oracle should identify itself.


Regards

Umesh
Re: Oracle RMAN Recovery [message #530596 is a reply to message #530587] Wed, 09 November 2011 03:58 Go to previous messageGo to next message
Michel Cadot
Messages: 59290
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
No, you have to give it the path, this is why you should use autobackup.

Regards
Michel
Re: Oracle RMAN Recovery [message #530625 is a reply to message #530596] Wed, 09 November 2011 07:04 Go to previous messageGo to next message
umeshgupta1987
Messages: 4
Registered: November 2011
Junior Member
Hi Michel,

I have tried something like this..


Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:\>rman target / nocatalog

Recovery Manager: Release 10.2.0.1.0 - Production on Wed Nov 9 18:04:32 2011

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

connected to target database: ORCL (DBID=1278113024)
using target database control file instead of recovery catalog

RMAN> show all;

RMAN configuration parameters are:
CONFIGURE RETENTION POLICY TO REDUNDANCY 1; # default
CONFIGURE BACKUP OPTIMIZATION OFF; # default
CONFIGURE DEFAULT DEVICE TYPE TO DISK; # default
CONFIGURE CONTROLFILE AUTOBACKUP ON;
CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO '_%F';
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
CONFIGURE SNAPSHOT CONTROLFILE NAME TO 'D:\ORACLE\PRODUCT\10.2.0\DB_1\DATABASE\SNCFORCL.ORA'; # default

RMAN> list backup summary;

RMAN> run
2> {
3> shutdown immediate;
4> startup mount;
5> backup full database tag 'full_bkup_test_091111';
6> }

database closed
database dismounted
Oracle instance shut down

connected to target database (not started)
Oracle instance started
database mounted

Total System Global Area     612368384 bytes

Fixed Size                     1250428 bytes
Variable Size                289409924 bytes
Database Buffers             314572800 bytes
Redo Buffers                   7135232 bytes

Starting backup at 09-NOV-11
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=267 devtype=DISK
channel ORA_DISK_1: starting full datafile backupset
channel ORA_DISK_1: specifying datafile(s) in backupset
input datafile fno=00001 name=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\SYSTEM01.DBF
input datafile fno=00003 name=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\SYSAUX01.DBF
input datafile fno=00002 name=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\UNDOTBS01.DBF
input datafile fno=00005 name=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\EXAMPLE01.DBF
input datafile fno=00004 name=D:\ORACLE\PRODUCT\10.2.0\ORADATA\ORCL\USERS01.DBF
channel ORA_DISK_1: starting piece 1 at 09-NOV-11
channel ORA_DISK_1: finished piece 1 at 09-NOV-11
piece handle=D:\ORACLE\PRODUCT\10.2.0\FLASH_RECOVERY_AREA\ORCL\BACKUPSET\2011_11
_09\O1_MF_NNNDF_FULL_BKUP_TEST_09111_7CNX2X9J_.BKP tag=FULL_BKUP_TEST_091111 com
ment=NONE
channel ORA_DISK_1: backup set complete, elapsed time: 00:01:15
Finished backup at 09-NOV-11

Starting Control File and SPFILE Autobackup at 09-NOV-11
piece handle=D:\ORACLE\PRODUCT\10.2.0\DB_1\DATABASE\_C-1278113024-20111109-01 co
mment=NONE
Finished Control File and SPFILE Autobackup at 09-NOV-11

RMAN> shutdown immediate;

database dismounted
Oracle instance shut down



Now i went to D:\oracle\product\10.2.0\db_1\database and deleted the SPFILEORCL.ORA

Created a pfile for taking database to nomount stage.
content of D:\oracle\product\10.2.0\oradata\orcl\init.ora

db_name=orcl
sga_max_size=512M
sga_target=512M


RMAN> Startup nomount pfile=D:\oracle\product\10.2.0\oradata\orcl\init.ora

connected to target database (not started)
Oracle instance started

Total System Global Area     536870912 bytes

Fixed Size                     1250044 bytes
Variable Size                150998276 bytes
Database Buffers             377487360 bytes
Redo Buffers                   7135232 bytes

RMAN> restore spfile from autobackup;

Starting restore at 09-NOV-11
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=36 devtype=DISK

channel ORA_DISK_1: looking for autobackup on day: 20111109
channel ORA_DISK_1: looking for autobackup on day: 20111108
channel ORA_DISK_1: looking for autobackup on day: 20111107
channel ORA_DISK_1: looking for autobackup on day: 20111106
channel ORA_DISK_1: looking for autobackup on day: 20111105
channel ORA_DISK_1: looking for autobackup on day: 20111104
channel ORA_DISK_1: looking for autobackup on day: 20111103
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 11/09/2011 18:14:36
RMAN-06172: no autobackup found or specified handle is not a valid copy or piece


RMAN>



But i am not able to restore SPFILE from auto backup.

Please Correct Me What I Have Done Wrong???


Regards

Umesh
Re: Oracle RMAN Recovery [message #530636 is a reply to message #530625] Wed, 09 November 2011 08:07 Go to previous message
John Watson
Messages: 4610
Registered: January 2010
Location: Global Village
Senior Member
You need to set your dbid,

set dbid 1278113024;

it is all in the docs, see example 3-44.
http://download.oracle.com/docs/cd/E11882_01/backup.112/e10643/rcmsynta2014.htm#i85845
Previous Topic: Oracle Database Backup Question
Next Topic: backupset issue
Goto Forum:
  


Current Time: Wed Oct 01 07:31:56 CDT 2014

Total time taken to generate the page: 0.30024 seconds