oracle数据文件system01.dbf上有坏块,如何修复
问题:数据库被一同事shutdown abort后,无法启动,报错如下:
ksedmp: internal or fatal error
ORA-00600: internal error code, arguments: , , , [], [], [], [], []
Current SQL statement for this session:
update undo$ set name=:2,file#=:3,block#=:4,status$=:5,user#=:6,undosqn=:7,xactsqn=:8,scnbas=:9,scnwrp=:10,inst#=:11,ts#=:12,spare1=:13 where us#=:1
我的操作:
因为没备份,不能直接恢复;
1)加隐含参数,等都试过,还是无法跳过坏块;
报错如下:
Thu Sep 12 20:37:38 CST 2013
Errors in file /opt/oracle/admin/orcl/udump/orcl_ora_6754.trc:
ORA-00600: internal error code, arguments: , , , [], [], [], [], []
Thu Sep 12 20:37:42 CST 2013
Doing block recovery for file 1 block 11
Resuming block recovery (PMON) for file 1 block 11
Block recovery from logseq 6, block 3 to scn 223208881779
2)用bbed将(file # 1, block # 11)设置为坏块: seq: 0xff,修改tailchk
但启动的时候还是报错:
ORA-01578: ORACLE data block corrupted (file # 1, block # 11)
ORA-01110: data file 1: '/opt/oracle/oradata/orcl/system01.dbf'
为什么设置了(file # 1, block # 11)为坏块,数据库还是无法跳过呢?
下面是相关信息,请各位帮我看看:
1、 OS
Linux orcl 2.6.18-164.el5 #1 SMP Tue Aug 18 15:51:48 EDT 2009 x86_64 x86_64 x86_64 GNU/Linux
2、db
SQL> startup mount pfile='/u01/oracle/rdb0912/pf0926.ora';
ORACLE instance started.
Total System Global Area 2516582400 bytes
Fixed Size 2098368 bytes
Variable Size 536873792 bytes
Database Buffers 1962934272 bytes
Redo Buffers 14675968 bytes
Database mounted.
SQL> select * from v$version;
BANNER
----------------------------------------------------------------
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bi
PL/SQL Release 10.2.0.5.0 - Production
CORE 10.2.0.5.0 Production
TNS for Linux: Version 10.2.0.5.0 - Production
NLSRTL Version 10.2.0.5.0 - Production
SQL>
3,alert log
Hex dump of (file 1, block 11) in trace file /opt/oracle/admin/orcl/udump/orcl_ora_24126.trc
Corrupt block relative dba: 0x0040000b (file 1, block 11)
Bad check value found during buffer read
Data in bad block:
type: 2 format: 2 rdba: 0x0040000b
last change scn: 0x0033.f847b6e3 seq: 0xff flg: 0x04
spare1: 0x0 spare2: 0x0 spare3: 0x0
consistency value in tail: 0xb6e302ff
check value in block header: 0x9fe1
computed block checksum: 0x515e
Reread of rdba: 0x0040000b (file 1, block 11) found same corrupted data
Fri Sep 27 13:19:16 CST 2013
Errors in file /opt/oracle/admin/orcl/udump/orcl_ora_24126.trc:
ORA-00604: error occurred at recursive SQL level 1
ORA-01578: ORACLE data block corrupted (file # 1, block # 11)
ORA-01110: data file 1: '/opt/oracle/oradata/orcl/system01.dbf'
Error 604 happened during db open, shutting down database
USER: terminating instance due to error 604
Instance terminated by USER, pid = 24126
ORA-1092 signalled during: ALTER DATABASE OPEN...
4,orcl_ora_24126.trc
$ more /opt/oracle/admin/orcl/udump/orcl_ora_24126.trc
/opt/oracle/admin/orcl/udump/orcl_ora_24126.trc
Oracle Database 10g Enterprise Edition Release 10.2.0.5.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORACLE_HOME = /opt/oracle/product/10.2.0/db
System name: Linux
Node name: orcl
Release: 2.6.18-164.el5
Version: #1 SMP Tue Aug 18 15:51:48 EDT 2009
Machine: x86_64
Instance name: orcl
Redo thread mounted by this instance: 1
Oracle process number: 15
Unix process pid: 24126, image: oracle@orcl (TNS V1-V3)
Corrupt block relative dba: 0x0040000b (file 1, block 11)
Bad check value found during buffer read
Data in bad block:
type: 2 format: 2 rdba: 0x0040000b
last change scn: 0x0033.f847b6e3 seq: 0xff flg: 0x04
spare1: 0x0 spare2: 0x0 spare3: 0x0
consistency value in tail: 0xb6e302ff
check value in block header: 0x9fe1
computed block checksum: 0x515e
Reread of rdba: 0x0040000b (file 1, block 11) found same corrupted data
ORA-00604: error occurred at recursive SQL level 1
ORA-01578: ORACLE data block corrupted (file # 1, block # 11)
ORA-01110: data file 1: '/opt/oracle/oradata/orcl/system01.dbf'
是啊,加了隐含参数,还是无法跳过,所以用bbed,尝试把这个块标为坏块,希望open的时候可以跳过去,但是还没跳过啊
现在我重建了 undo,用隐含参数打开数据库,报下面的错误:SQL> oradebug setmypid
Statement processed.
SQL> oradebug EVENT 10046 TRACE NAME CONTEXT FOREVER, LEVEL 12
Statement processed.
SQL> alter session set db_file_multiblocK_read_count=1;
Session altered.
SQL> oradebug TRACEFILE_NAME
/opt/oracle/admin/yunst/udump/yunst_ora_20413.trc
SQL> alter database Open;
alter database Open
*
ERROR at line 1:
ORA-00600: internal error code, arguments: , , , [], [],
[], [], []
Misses in library cache during parse: 0
2 user SQL statements in session.
0 internal SQL statements in session.
2 SQL statements in session.
********************************************************************************
Trace file: /opt/oracle/admin/yunst/udump/yunst_ora_20413.trc
Trace file compatibility: 10.01.00
Sort options: default
1 session in tracefile.
2 user SQL statements in trace file.
0 internal SQL statements in trace file.
2 SQL statements in trace file.
2 unique SQL statements in trace file.
106614 lines in trace file.
21 elapsed seconds in trace file.
$
请问这个trace 文件能看出哪儿有问题吗 ?
早上来,在pfile中加了 event="10231 trace name context forever, level 10",再做如下操作:
SQL> startup mount pfile='/u01/oracle/rdb0912/pf0926.ora';
ORACLE instance started.
Total System Global Area 2516582400 bytes
Fixed Size 2098368 bytes
Variable Size 536873792 bytes
Database Buffers 1962934272 bytes
Redo Buffers 14675968 bytes
Database mounted.
SQL> oradebug setmypid
Statement processed.
SQL> oradebug EVENT 10046 TRACE NAME CONTEXT FOREVER, LEVEL 12
Statement processed.
SQL> alter session set db_file_multiblocK_read_count=1;
Session altered.
SQL> oradebug TRACEFILE_NAME
/opt/oracle/admin/yunst/udump/yunst_ora_25894.trc
SQL> alter database Open;
alter database Open
*
ERROR at line 1:
ORA-01092: ORACLE instance terminated. Disconnection forced
alert日志:
---------------------
Thread 1 opened at log sequence 2
Current log# 2 seq# 2 mem# 0: /u01/oracle/oradata2/redo02
Successful open of redo thread 1
Sat Sep 28 09:16:45 CST 2013
MTTR advisory is disabled because FAST_START_MTTR_TARGET is not set
Sat Sep 28 09:16:45 CST 2013
SMON: enabling cache recovery
Sat Sep 28 09:16:45 CST 2013
Errors in file /opt/oracle/admin/yunst/udump/yunst_ora_25894.trc:
ORA-00604: error occurred at recursive SQL level 1
ORA-01578: ORACLE data block corrupted (file # 1, block # 11)
ORA-01110: data file 1: '/opt/oracle/oradata/yunst/system01.dbf'
Sat Sep 28 09:16:45 CST 2013
Error 604 happened during db open, shutting down database
USER: terminating instance due to error 604
Instance terminated by USER, pid = 25894
ORA-1092 signalled during: alter database Open...
页:
[1]