No backup software backs up online redo log files. Because it is almost always written, it makes no sense to back up a single time point. In a sense, archiving logs are also a backup of redo logs on the couplet. The core of redo log file protection on the couplet is redundancy. Including Multi-Channel images, raid methods, and HA applications (such as DG ).
1) view the current online redo log file
sys@ORCL> select group#,members,sequence#,status from v$log; GROUP# MEMBERS SEQUENCE# STATUS---------- ---------- ---------- ---------------- 1 2 5 CURRENT 2 2 4 INACTIVE 3 2 3 INACTIVEsys@ORCL> col member for a70 wrappedsys@ORCL> select group#,member from v$logfile where group#=1; GROUP# MEMBER---------- ---------------------------------------------------------------------- 1 /u01/app/oracle/oradata/ORCL/onlinelog/o1_mf_1_8050hhn1_.log 1 /u01/app/oracle/flash_recovery_area/ORCL/onlinelog/o1_mf_1_8050hkdv_.l og
2) Simulated file loss
sys@ORCL> shutdown immediateDatabase closed.Database dismounted.ORACLE instance shut down.sys@ORCL> host rm -rf /u01/app/oracle/oradata/ORCL/onlinelog/o1_mf_1_8050hhn1_.logsys@ORCL> host rm -rf /u01/app/oracle/flash_recovery_area/ORCL/onlinelog/o1_mf_1_8050hkdv_.logsys@ORCL> startupORACLE instance started.Total System Global Area 419430400 bytesFixed Size 1219760 bytesVariable Size 155190096 bytesDatabase Buffers 260046848 bytesRedo Buffers 2973696 bytesDatabase mounted.ORA-00313: open failed for members of log group 1 of thread 1ORA-00312: online log 1 thread 1: '/u01/app/oracle/oradata/ORCL/onlinelog/o1_mf_1_8050hhn1_.log'ORA-00312: online log 1 thread 1:'/u01/app/oracle/flash_recovery_area/ORCL/onlinelog/o1_mf_1_8050hkdv_.log'
3) Modify _ allow_resetlogs_uption
Because there is no backup, it can only be forcibly restored. So here we need to modify a hidden initialization parameter:
sys@ORCL> alter system set "_ALLOW_RESETLOGS_CORRUPTION"=TRUE SCOPE=SPFILE;
When this parameter is set to true, Oracle skips some consistency checks during open.
4) Close and re-mount the database
sys@ORCL> shutdown immediateORA-01109: database not openDatabase dismounted.ORACLE instance shut down.sys@ORCL> startup mountORACLE instance started.Total System Global Area 419430400 bytesFixed Size 1219760 bytesVariable Size 155190096 bytesDatabase Buffers 260046848 bytesRedo Buffers 2973696 bytesDatabase mounted.
5) incomplete execution recovery
sys@ORCL> recover database until cancel;Media recovery complete.
6) Open the database through open resetlogs
sys@ORCL> alter database open resetlogs;Database altered.
7) Aftercare
This is a desperate practice. "The magic of the magic ". Recovery in this way may result in inconsistent data in the database. For example, committed data has not been written, but not committed data has been written. An error 600 may be reported in the alarm log. We strongly recommend that you execute full exp immediately through exp, create a new database, and then import the exported binary files through imp.