Email: service@parnassusdata.com 7 x 24 online support!
Oracle 在文件被重命名后ORA-27069或ORA-01113 或ORA-01251 ORA-27069: 试图超出文件范围执行 I/O
如果自己搞不定可以找诗檀软件专业ORACLE数据库修复团队成员帮您恢复!
诗檀软件专业数据库修复团队
服务热线 : 13764045638 QQ号:47079569 邮箱:service@parnassusdata.com
ORA-27069 oerr ora 27069 27069, 00000, "attempt to do I/O beyond the range of the file" // *Cause: internal error, the range of blocks being read or written is // outside the range of the file, additional information indicates // the starting block number, number of blocks in I/O, and the // last valid block in the file // *Action: check for trace file and contact Oracle Support ORA-01113 oerr ora 1113 01113, 00000, "file %s needs media recovery" // *Cause: An attempt was made to online or open a database with a file that // is in need of media recovery. // *Action: First apply media recovery to the file. 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-01115: IO error reading block from file ? (Block # ?)
ORA-01110: data file ?: ‘<filename>’
ORA-27091: skgfqio: unable to queue I/O
ORA-27069: skgfdisp: attempt to do I/O beyond the range of the file
或
ORA-01113: file ? needs media recovery
ORA-01110: data file ?: ‘<filename>’
或
ORA-01122: database file ? failed verification check
ORA-01110: data file ?: ‘<filename>’
ORA-01251: Unknown File Header Version read for file number ?
更改
~~~~~~~~~~
在你发出以下命令后看到这些错误:
ALTER DATABASE RENAME FILE ‘<filename>’ TO ‘<filename>’;
原因
~~~~~~~
重命名数据文件的正确步骤是
1) 使数据文件脱机,或使表空间脱机,或使数据库在mount模式
2) 将新文件复制到其适当的位置。
3) 发出命令:
ALTER DATABASE RENAME FILE ‘<filename>’ TO ‘<filename>’;
4) 更改alter数据文件联机(可能需要文件恢复),或alter表空间联机,或打开数据库。怎么做取决于你在步骤1中执行了什么行为。
你在步骤2,即复制步骤中的行为都可能导致这些错误,如下所述。
如果在步骤2中你使用Unix “touch”命令来创建新的文件而没有复制文件,你会看到以下错误:
ORA-01115: IO error reading block from file ? (Block # ?)
ORA-01110: data file ?: ‘<filename>’
ORA-27091: skgfqio: unable to queue I/O
ORA-27069: skgfdisp: attempt to do I/O beyond the range of the file
修正
~~~~
复制被重命名的正确文件到新文件名。不要使用Unix的touch命令来创建新的文件。在你将新文件名复制到正确文件后,你就能alter数据文件联机。
如果你复制了被重命名的文件的旧版本而不是最新的版本,你会看到以下错误:
ORA-01113: file ? needs media recovery
ORA-01110: data file ?: ‘<filename>’
修正
~~~~
复制被重命名的文件的最新的版本而不是旧版本。或者,如果你的数据库在归档日志模式下且你有所有的归档日志文件,恢复数据文件。在你将正确文件的最新版本到新文件名后,你就能alter 数据文件联机。
如果你将错误文件复制到新文件名,你会看到以下错误:
ORA-01122: database file ? failed verification check
ORA-01110: data file ?: ‘<filename>’
ORA-01251: Unknown File Header Version read for file number ?
作为示例,我们假设你想要为用户的表空间重命名一个文件。
你进行以下操作:
1) ALTER TABLESPACE USERS OFFLINE;
2) cp tools1.dbf users1.dbf
3) ALTER DATABASE RENAME FILE ‘/u01/oradata/users01.dbf’ to ‘/u01/oradata/users1.dbf’
4) ALTER TABLESPACE USERS ONLINE.
* ORA-01122, ORA-01110, ORA-01251 returned.
修正
~~~~
在步骤二中将正确文件复制到新文件名。以下是你应该执行的步骤:
1) ALTER TABLESPACE USERS OFFLINE;
2) cp users01.dbf users1.dbf
3) ALTER DATABASE RENAME FILE ‘/u01/oradata/users01.dbf’ to ‘/u01/oradata/users1.dbf’
4) ALTER TABLESPACE USERS ONLINE.
在将正确文件复制到新文件名后,你应该能够alter数据文件联机。