分类: Oracle
2009-02-12 13:34:13
最近遇到一个current redo log损坏且没有备份和归档的案例,环境为aix 5.1 oracle 817处理过程记录如下1.mount db 查询宕机时是否完整性检查
$ sqlplus "/as sysdba"
SQL> startup mount;
SQL> select checkpoint_change#,last_change# from v$datafile;
CHECKPOINT_CHANGE# LAST_CHANGE#
------------------ ------------
4586417715
4586417715
4586417715
4586417715
4586417715
4586417715
4586417715
4586417715
4586417715
4586417715
4586417715
CHECKPOINT_CHANGE# LAST_CHANGE#
------------------ ------------
4586417715
4586417715
由此可知数据库在宕机时未执行检查点。
2._allow_resetlogs_corruption=true
sqlplus "/as sysdba"
startup mount;
recover database until cancel;
alter database open resetlogs;
参数文件加隐含参数_allow_resetlogs_corruption=true启动,alert报错
ORA-00600: internal error code, arguments: [2662], [1], [291470434], [1], [291543086], [12582914], [], []
3.设置10015 event
sqlplus "/as sysdba"
startup mount
alter session set events '10015 trace name adjust_scn level 10';
alter database open;
alert 报错ORA-00600: internal error code, arguments: [4193], [12425], [12433], [], [], [], [], []
ora-600 4193是回滚段数据和redo不一致,不能通过完整性检查
4.设置_corrupted_rollback_segments
_corrupted_rollback_segments=(rbs0,rbs1,rbs2,rbs3,rbs4,rbs5,rbs6,rbs7,rbs8,rbs9,rbs10,rbs11)
sqlplus "/as sysdba"
startup mount
alter database open
数据库打开正常
5.exp 导出数据
6.重建数据库
7. 导入数据
8. 校验数据