*********************************************************************
BBED> p kcvfhckp
struct kcvfhckp, 36 bytes @484
struct kcvcpscn, 8 bytes @484
ub4 kscnbas @484 0x0003c905-------->修改此处开始
的四个字节
ub2 kscnwrp @488 0x0000
ub4 kcvcptim @492 0x329a78ad
ub2 kcvcpthr @496 0x0001
union u, 12 bytes @500
struct kcvcprba, 12 bytes @500
ub4 kcrbaseq @500 0x0000000f-------->修改此处开始的
四个字节
ub4 kcrbabno @504 0x0000020b
ub2 kcrbabof @508 0x0010
ub1 kcvcpetb[0] @512 0x02
ub1 kcvcpetb[1] @513 0x00
ub1 kcvcpetb[2] @514 0x00
ub1 kcvcpetb[3] @515 0x00
ub1 kcvcpetb[4] @516 0x00
ub1 kcvcpetb[5] @517 0x00
ub1 kcvcpetb[6] @518 0x00
ub1 kcvcpetb[7] @519 0x00
*********************************************************************
--找到
set file 4 block 1---好的文件
dump /v offset 484 count 16
dump /v offset 500 count 16
set file 5 block 1---坏的文件
set offset 484
dump
modify /x cf6f0800 dba 5,1 offset 484
其中 cf6f0800 就是 dump 显示的内容,这个可能因为字节序的问题与 p kcvfhckp 的输出顺序相反,以
dump 为准
dump
d /v dba 5,1 offset 484 count 16
set offset 500
dump
modify /x 0b dba 5,1 offset 500
dump
d /v dba 5,1 offset 500 count 16
sum
sum apply
exit
############恢复并 online 数据文件
SQL>recover datafile 5
SQL>alter database datafile 5 online;
select file#,name,status,checkpoint_change#,last_change# from v$datafile order
by 1;
select file#,name,status,checkpoint_change# from v$datafile_header order by 1;
select * from v$recover_file;
SQL>alter database open;
评论