现象:
有个oracle 空间不足崩掉了,扩容后现在open不起来,报
ERROR at line 1:
ORA-01113: file 1 needs media recovery
ORA-01110: data file 1: '/oradata/GCMC/data/1_SYSTEM.datafile1.dbf'
检查:查到文件头不一致:
set numw 30
select file#,checkpoint_change# from v$datafile_header;
FILE# CHECKPOINT_CHANGE#
------------------------------ ------------------------------
1 15750737758493 相差约3w
2 15750737788082
3 15750737788082
解决方法:
1、修改参数文件,加上下面几个参数
*.event="21307096 trace name context forever,level 1"
*._allow_error_simulation=TRUE
*._allow_resetlogs_corruption=TRUE
2、启动库到nomount
3、重建控制文件
CREATE CONTROLFILE REUSE set DATABASE "GCMC" RESETLOGS FORCE LOGGING NOARCHIVELOG
MAXLOGFILES 192
MAXLOGMEMBERS 3
MAXDATAFIL