check oracle corruption block总结

1:  db_block_checksum=true
     该参数在把dirty block 写入datafile时,做checksum符号位的检查。当buffer中checksum的和datafile的checksum值不匹配时,报ORA-1578错误。
     Oracle 9.0.1 - 10g: default is true, Oracle auto check logical corruption.
     Oracle 8.1.7及之前版本: default is false 
     另,在8.1.5, 当db_block_checksum=true时,同时开启错误check log buffer写入   redo logfile。但在8.1.5之前,是通过参数log_block_checksum控制的

2:  rman
      run{
       allocate channel d1 type disk;
       backup check logical validate database;
       release channel d1;
       }
      如果是8i, 可以从日志中看到corruption block的信息,
      如果是9i, 可以查询v$database_block_corruption。你能通过以下sql观察rman的check进度:
      select sid, serial#, context, sofar, totalwork,
   round(sofar/totalwork*100,2) "%_complete"
   from v$session_longops
       where opname like 'RMAN%'
         and opname not like '%aggregate%'
         and totalwork != 0
         and sofar <> totalwork

3:  DBVERIFY 
C:\oracle\oradata\mydb>dbv file=users01.dbf blocksize=8192

DBVERIFY: Release 9.0.1.1.1 - Production on Mon Mar 31 20:16:01 2008

(c) Copyright 2001 Oracle Corporation.  All rights reserved.

DBVERIFY - Verification starting : FILE = users01.dbf


DBVERIFY - Verification complete

Total Pages Examined         : 3200
Total Pages Processed (Data) : 27
Total Pages Failing   (Data) : 0
Total Pages Processed (Index): 0
Total Pages Failing   (Index): 0
Total Pages Processed (Other): 11
Total Pages Processed (Seg)  : 0
Total Pages Failing   (Seg)  : 0
Total Pages Empty            : 3162
Total Pages Marked Corrupt   : 0
Total Pages Influx           : 0

4: analyze table/index  validate statistics 
    当online analyze 时,oracle不分析table/index的信息
    当analyze iot时, 只分析compression的信息
    如行数据不能正确分析, 则执行分析,将该行的rowid记录到table invalid_rows(utlvalid.sql).
     anaylze table name validate structure into invalid_rows;
    

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/26684/viewspace-220472/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/26684/viewspace-220472/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值