I have a database that I can't open after a power failure. It's a sandbox environment and the data is not important. However, I would like to learn how to recover this database without losing more than a minute of data. I have a redo log that didn't get written out and it appears that skipping an unrecoverable log file isn't working. I got some of these steps from https://community.oracle.com/message/13313818#13313818. This is 11.2.0.4 on Linux and is a two-node RAC database.
Here are the steps I went through. I expected that the hidden parameter would allow me to recover the database but that failed, as did the clear commands:
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1: '+DATA/racdb/datafile/system.256.860444845'
SQL> recover database;
ORA-00283: recovery session canceled due to errors
ORA-00742: Log read detects lost write in thread %d sequence %d block %d
ORA-00312: online log 1 thread 1: '+DATA/racdb/onlinelog/group_1.261.860444949'
SQL> alter system set "_allow_resetlogs_corruption"=true scope=spfile;
SQL> shutdown immediate;
SQL> startup mount;
ORACLE instance started.
SQL> alter database open;
alter database open
*
ERROR at line 1:
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1: '+DATA/racdb/datafile/system.256.860444845'
SQL> recover database;
ORA-00283: recovery session canceled due to errors
ORA-00742: Log read detects lost write in thread %d sequence %d block %d
ORA-00312: online log 1 thread 1: '+DATA/racdb/onlinelog/group_1.261.860444949'
SQL> alter database clear unarchived logfile group 1;
alter database clear unarchived logfile group 1
*
ERROR at line 1:
ORA-01624: log 1 needed for crash recovery of instance racdb1 (thread 1)
ORA-00312: online log 1 thread 1: '+DATA/racdb/onlinelog/group_1.261.860444949'
SQL> alter database clear unarchived logfile group 1 unrecoverable datafile;
alter database clear unarchived logfile group 1 unrecoverable datafile
*
ERROR at line 1:
ORA-01624: log 1 needed for crash recovery of instance racdb1 (thread 1)
ORA-00312: online log 1 thread 1: '+DATA/racdb/onlinelog/group_1.261.860444949'