Dear Friends, The content in this blog are purely based on my own opinion ,it is not reflecting any of my current or previous employers materials or official documents. All my posts here are not warranted to be free of errors. Please use at your own risk and after thorough testing in your environment. If you feel that i am violating any of the company's policies or documents, kindly mail me at jeyaseelan.hi@gmail.com,I am happy to take out those content from this blog.
Friday, 22 March 2019
How to restore a corrupted/missing datafile in standby:
How to restore a corrupted/missing datafile in standby:
Before 12.2
1. Cancel the recovery
dgmgrl > edit database <db> set state='APPLY-OFF';
(or) alter database recover managed standby database cancel;
2. From Primary take a datafile copy
rman target /
backup as copy datafile 2 format "/u01/app/oracle/data01/sysaux_01.dbk" ;
3. scp the file from primay server to standby server ( may be to the same location in standby server)
4. catalog the datafile copy ( in sby server)
rman target /
catalog datafilecopy '/u01/app/oracle/data01/sysaux_01.dbk'
5. Either do a switch copy or restore the datafile to the same location mentioned in the controlfile( in sby server)
rman target /
switch datafile 2 to copy;
report schema
alternatively
RUN {
ALLOCATE CHANNEL ch00 TYPE disk ;
restore datafile 2 ;
}
6. enable recovery
dgmgrl > edit database <db> set state='APPLY-ON';
(or) alter database recover managed standby database disconnect from session ;
After 12
rman target sys/oracle@prod
RMAN> run
{
set newname for datafile 4 to '/u01/oracle/data02/users01.dbf' section size 1G;
restore (datafile 4 from service prodservice) using compressed backupset;
catalog datafilecopy '/u01/oracle/data02/users01.dbf';
}
Subscribe to:
Post Comments (Atom)
-
We may not be able to disable the logtransport when the database is in maximum availabilty mode. We may get the below error DGMGRL...
-
Error Messages: We may get the following error messages while doing ASM operations ORA-15137: The ASM cluster is in rolling patch state....
-
MIRA - Multi Instance Redo Apply - 12cR2 onwards/18C With Oracle 12c Release 2, We can enable Multi Instance Redo apply ( MIR...
No comments:
Post a Comment