Home » RDBMS Server » Backup & Recovery » Beginner RMAN question
Beginner RMAN question [message #360752] Sun, 23 November 2008 22:28 Go to next message
apachenc
Messages: 1
Registered: November 2008
Junior Member
I am attempting to get the example at the very bottom of the following link to work:

http://download.oracle.com/docs/cd/B28359_01/backup.111/b28270/rcmflash.htm#BRADV89737

The example does not include the current state of the database. When I try to startup in nomount, I get a SET error saying the database is not mounted upon invocation of the SET statement, as follows:

RMAN> shutdown immediate;

database dismounted
Oracle instance shut down

RMAN> startup nomount;

connected to target database (not started)
Oracle instance started

Total System Global Area 167772160 bytes

Fixed Size 1247900 bytes
Variable Size 75498852 bytes
Database Buffers 88080384 bytes
Redo Buffers 2945024 bytes

RMAN> RUN
2> {
3> set until time ="to_date('11/19/2008 21:30:00','mm/dd/yyyy hh24:mi:ss
')";
4> RESTORE CONTROLFILE FROM AUTOBACKUP;
5> ALTER DATABASE MOUNT;
6> RESTORE DATABASE;
7> RECOVER DATABASE;
8> }

executing command: SET until clause
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of set command at 11/23/2008 22:53:05
ORA-01507: database not mounted


However, when I change the startup nomount to startup mount, I get a error "Must use a TO clause' on the restore controlfile command, as follows:

RMAN> startup mount;

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

Total System Global Area 167772160 bytes

Fixed Size 1247900 bytes
Variable Size 75498852 bytes
Database Buffers 88080384 bytes
Redo Buffers 2945024 bytes

RMAN> RUN
2> {
3> set until time ="to_date('11/19/2008 21:30:00','mm/dd/yyyy hh24:mi:ss
')";
4> RESTORE CONTROLFILE FROM AUTOBACKUP;
5> ALTER DATABASE MOUNT;
6> RESTORE DATABASE;
7> RECOVER DATABASE;
8> }

executing command: SET until clause

Starting restore at 23-NOV-08
allocated channel: ORA_DISK_1
channel ORA_DISK_1: sid=157 devtype=DISK

RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 11/23/2008 22:56:17
RMAN-06496: must use the TO clause when the database is mounted or open

I dont want to use the TO clause, because I want to update the DB as it is a(as well as follow the example).

So I am confused on how to get this example to work. In what state do I put the database in what sequence to get the example to work ?

Thanks in advance. Any advice would be appreciated.
Re: Beginner RMAN question [message #360798 is a reply to message #360752] Mon, 24 November 2008 01:04 Go to previous message
Michel Cadot
Messages: 64103
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
The link you gave does not contain the example you posted.
So I will comment what you posted.
You have to "SET DBID" in nomount stage before begin able to restore the control file.

Regards
Michel
Previous Topic: Rman Backup R & D With Recovery Catalog
Next Topic: configure Large Pool
Goto Forum:
  


Current Time: Sun Dec 04 00:32:57 CST 2016

Total time taken to generate the page: 0.06528 seconds