Wednesday, September 28, 2022

ORA-19821: an intentionally corrupt log file was found

 If this error appears while opening your database, it means that an instance crash happened before the database start and instance recovery needs redo data to be applied to the database, but redo data is not available in the redo log file. The reason of missing data is that redo data was not written to the log file when database instance crashed. The data flushing to the redo logs was probably stopped because of setting parameter “_disable_logging” to TRUE to speed up the data loading. Alert log file would show entries similar to the following.

Errors in file /u01/app/oracle/diag/rdbms/mydatabase/mydatabase/trace/mydatabase_pr00_14422.trc:
ORA-00283: recovery session canceled due to errors
ORA-19821: an intentionally corrupt log file was found
Slave exiting with ORA-283 exception
Errors in file
/u01/app/oracle/diag/rdbms/mydatabase/mydatabase/trace/mydatabase_pr00_14422.trc:
ORA-00283: recovery session canceled due to errors
ORA-19821: an intentionally corrupt log file was found
ORA-10877 signalled during: ALTER DATABASE RECOVER  database  ...
alter database open
Beginning crash recovery of 1 threads
 parallel recovery started with 31 processes
Started redo scan
Aborting crash recovery due to error 19821
Errors in file
u01/app/oracle/diag/rdbms/mydatabase/mydatabase/trace/mydatabase_ora_13810.trc:
ORA-19821: an intentionally corrupt log file was found
Errors in file
/u01/app/oracle/diag/rdbms/mydatabase/mydatabase/trace/mydatabase_ora_13810.trc:
ORA-19821: an intentionally corrupt log file was found
ORA-19821 signalled during: alter database open...
Thu Apr 19 04:36:25 2018
db_recovery_file_dest_size of 69632 MB is 0.00% used. This is a
user-specified limit on the amount of space that will be used by this
database for recovery-related files, and does not reflect the amount of
space available in the underlying filesystem or ASM diskgroup.
Thu Apr 19 06:44:21 2018
alter database open
Beginning crash recovery of 1 threads
parallel recovery started with 31 processes
Started redo scan
Aborting crash recovery due to error 19821
Errors in file
/u01/app/oracle/diag/rdbms/mydatabase/mydatabase/trace/mydatabase_ora_37741.trc:
ORA-19821: an intentionally corrupt log file was found
Errors in file
/u01/app/oracle/diag/rdbms/mydatabase/mydatabase/trace/mydatabase_ora_37741.trc:
ORA-19821: an intentionally corrupt log file was found
ORA-19821 signalled during: alter database open...

 Only possibility to bring database online is to perform recovery of the database without which opening of the database would not be possible.

Nomount or mount the instance and check the parameter’s value, and set it back to FALSE.

SQL> show parameter _disable_logging

NAME                                 TYPE        VALUE
------------------------------------ ----------- ----------------------------------------------------------------
_disable_logging                     boolean     TRUE
 
SQL> alter system set “_disable_logging”=FALSE SCOPE=SPFILE;

 After it has been set to FALSE again, perform cancel based or time based recovery and open the database.

Note: Never every set _disable_logging to FALSE. Oracle does not support this. If something is available from Oracle, it does not mean it should be used. Even if you are doing this for some testing of dataload to avoid extra IO, do a clean shutdown of the database to make sure that you are able to open the database next time.

No comments:

Post a Comment

Popular Posts - All Times