于是呼、shutdown 掉实例后、open 实例竟然淘气地起不来
sys@ORACLE10> alter database open; alter database open * ERROR at line 1: ORA-00313: open failed for members of log group 1 of thread 1 ORA-00312: online log 1 thread 1: '/u01/app/oracle/oradata/oracle10/redo01.log'
在这里、我们大概可知日志组1的日志文件损坏了
查看 v$log 视图
sys@ORACLE10> select group#,sequence#,archived,status from v$log; GROUP# SEQUENCE# ARC STATUS ---------- ---------- --- ---------------- 1 2 YES INACTIVE 3 1 YES INACTIVE 2 3 NO CURRENT
可以知道、改组是非当前状态、而且已经归档
用 clear 命令重建该日志文件
sys@ORACLE10> alter database clear logfile group 1; Database altered.
如果该日志组还没有归档、则需要:
alter database clear unarchived logfile group 1;
打开数据库、然后建议重新备份数据库
sys@ORACLE10> alter database open; Database altered.