如果自己搞不定可以找诗檀软件专业ORACLE数据库修复团队成员帮您恢复!
诗檀软件专业数据库修复团队
服务热线 : 13764045638 QQ号:47079569 邮箱:[email protected]
ORA-01171 oerr ora 1171 01171, 00000, "datafile %s going offline due to error advancing checkpoint" // *Cause: The checkpoint in the file header could not be advanced. See // accompanying errors for the reason. The datafile will be taken // offline the same as for a write error of a data block. // *Action: See accompanying errors for details. Restore access to the file, // do media recovery, and bring it back online. ORA-01122 oerr ora 1122 01122, 00000, "database file %s failed verification check" // *Cause: The information in this file is inconsistent with information // from the control file. See accompanying message for reason. // *Action: Make certain that the db files and control files are the correct // files for this database. ORA-01251 oerr ora 1251 01251, 00000, "Unknown File Header Version read for file number %s" // *Cause: Read of the file header returned a record but its version cannot // be identified. Either the header has been corrupted, or the file // is not a valid database file. // *Action: Have the operating system make the correct file available to // the database, or recover the file. ORA-01186 oerr ora 1186 01186, 00000, "file %s failed verification tests" // *Cause: The data file did not pass the checks to insure it is part of the // database. See the accompanying error messages for the reason the // verification failed. // *Action: Make the correct file available to the database. Then, either open // the database, or execute ALTER SYSTEM CHECK DATAFILES.
适用于:
Oracle Database – Enterprise Edition – 版本 8.1.7.4 到 10.2.0.1 [Release 8.1.7 到 10.2]
本文信息适用于任何平台。
症状
在读数据文件头时报告损坏。
警报日志显示信息如下:
ORA-01171: datafile 8 going offline due to error advancing checkpoint
ORA-01122: database file 8 failed verification check
ORA-01110: data file 8: ‘/oracle/test_lob12.dbf’
ORA-01251: Unknown File Header Version read for file number 8
或
ORA-01186: file 8 failed verification tests
原因
块文件头损坏(块1)。
可能是由于一个遗漏读或写,硬件问题或任何对Oracle的外部操作,将块文件头中的内容覆盖引起的。
解决方案
选项 1: 从备份中还原数据文件
数据库需要在归档日志模式。
使有问题的数据文件脱机,从报告中还原它,应用媒体恢复并将它设回到联机:
SQL> alter database datafile <fileno> offline ;
Rename the file at OS level (mv <original name> <original name_old>)
Restore datafile from backup (rman or user managed backup)
Recover the datafile
SQL> alter database datafile <fileno> online;
选项 2: 数据文件的备份不可用但从数据文件的创建日期的所有归档日志可用。
- 数据库需必须在归档日志模式.
- 需要从数据文件创建起的所有归档日志文件。
- 控制文件有数据文件创建信息。如果控制文件在数据文件创建后被重建,则以下方法不适用且第2步会显示错误ORA-01178。
遵循下列步骤:
第1步:
使有问题的数据文件脱机。
SQL> alter database datafile ‘/oracle/test_lob12.dbf’ offline;
Copy the file to an alternate backup location.
第2步:
发出以下命令来重建文件:
SQL> alter database create datafile ‘/oracle/test_lob12.dbf’;
第3步:
开始应用归档日志文件来重建数据文件。
SQL> Recover datafile ‘/oracle/test_lob12.dbf’;
第4步:
当恢复完成,使数据文件联机。
SQL> alter database datafile ‘/oracle/test_lob12.dbf’ online;
选项3: 数据文件的备份和归档日志不可用。
解决方法是使数据文件脱机并drop表空间:
alter database datafile ‘<file name and path>’ offline drop;
alter database open; (if the instance is down)
drop tablespace <tablespace name> including contents;
Leave a Reply