RMAN restore off autobackup [message #600142] |
Fri, 01 November 2013 05:26 |
ijsselg
Messages: 13 Registered: April 2005 Location: Netherlands
|
Junior Member |
|
|
I want to restore my database from server x to server y.
The control files on server x are named [$ORACLE_SID]_control01.ctl and [$ORACLE_SID]_control02.ctl.
We have an auto backup of the control files.
When I restore the control files on host y, (from autobackup) the restored controle files have other names: control01.ctl and control02.ctl. After the restore and recover (which goes well) the database does not start correctly.
SQL> ORACLE instance started.
Total System Global Area 626327552 bytes
Fixed Size 2224088 bytes
Variable Size 411041832 bytes
Database Buffers 205520896 bytes
Redo Buffers 7540736 bytes
Database mounted.
ORA-01122: database file 1 failed verification check
ORA-01110: data file 1: '/data/coda/coda_system01.dbf'
ORA-01202: wrong incarnation of this file - wrong creation time
|
|
|
|
Re: RMAN restore off autobackup [message #600146 is a reply to message #600144] |
Fri, 01 November 2013 05:43 |
ijsselg
Messages: 13 Registered: April 2005 Location: Netherlands
|
Junior Member |
|
|
Thanks, but we have a standard procedure/script voor backup and restore with RMAN. And this procedure is working for all other databases, only this one is the problem.
|
|
|
|
Re: RMAN restore off autobackup [message #600149 is a reply to message #600148] |
Fri, 01 November 2013 05:58 |
ijsselg
Messages: 13 Registered: April 2005 Location: Netherlands
|
Junior Member |
|
|
ok, this is my restorescript
rman target / << EOF
set dbid $DBID
STARTUP FORCE NOMOUNT PFILE='/dbms/oracle/admin/$sid/pfile/init.ora'
RESTORE CONTROLFILE FROM '/dbms/oracle/${flash}_recovery_area/auto.restore.$ORACLE_SID/$ctrlfile2';
alter database mount;
catalog start with '/dbms/oracle/${flash}_recovery_area/auto.restore.$ORACLE_SID';
YES
run {
set until time "to_date('$dat $tijd','dd-mm-yyyy hh24:mi:ss')";
restore database;
recover database;
}
exit
EOF
sqlplus '/as sysdba' << EOF
alter database open resetlogs;
shutdown abort
startup
exit
EOF
|
|
|
|
|
|
Re: RMAN restore off autobackup [message #600156 is a reply to message #600152] |
Fri, 01 November 2013 08:07 |
gazzag
Messages: 1119 Registered: November 2010 Location: Bedwas, UK
|
Senior Member |
|
|
John meant this one:
sqlplus '/as sysdba' << EOF
alter database open resetlogs;
shutdown abort
startup
exit
EOF
Which is not required after your alter database open resetlogs;
|
|
|
|
|
|