ORA-00313、00312、27047

来源:互联网 发布:木门销售软件 编辑:程序博客网 时间:2024/06/03 19:57

启动数据库

SQL> startupORACLE instance started.Total System Global Area 1252663296 bytesFixed Size            2252824 bytesVariable Size          805310440 bytesDatabase Buffers      436207616 bytesRedo Buffers            8892416 bytesDatabase mounted.ORA-03113: end-of-file on communication channelProcess ID: 40669Session ID: 125 Serial number: 5

查看alert日志

[oracle@vastdata1 ~]$ vi /u01/app/oracle/diag/rdbms/prod/PROD/trace/alert_PROD.log...... Errors in file /u01/app/oracle/diag/rdbms/prod/PROD/trace/PROD_lgwr_40796.trc:ORA-00313: open failed for members of log group 2 of thread 1ORA-00312: online log 2 thread 1: '/u01/app/oracle/oradata/PROD/redo02.log'ORA-27047: unable to read the header block of fileLinux-x86_64 Error: 25: Inappropriate ioctl for device......

解决:

SQL> conn / as sysdbaConnected to an idle instance.
SQL> startup mountORACLE instance started.Total System Global Area 1252663296 bytesFixed Size            2252824 bytesVariable Size          805310440 bytesDatabase Buffers      436207616 bytesRedo Buffers            8892416 bytesDatabase mounted.

清理损坏的日志

SQL> alter database clear logfile group 2;Database altered.

删除损坏的日志

SQL> alter database drop logfile group 2;Database altered.

现在可以正常打开数据库

SQL> alter database open;Database altered.

添加日志

SQL> alter database add logfile group 2 ('/u01/app/oracle/oradata/PROD/redo02.log') size 50M;Database altered.

总结:
对于非current redo log损坏,如果是处于inactive状态的redo,那么处理起来很简单,直接clear然后drop掉,不会有数据的丢失。

0 0