One danger in making online backups is the possibility of inconsistent data within a block. For example, assume that you are backing up block 100 in datafile users.dbf. Also, assume that the copy utility reads the entire block while DBWR is in the middle of updating the block. In this case, the copy utility may read the old data in the top half of the block and the new data in the bottom top half of the block. The result is called a fractured block, meaning that the data contained in this block is not consistent. at a given SCN.

When performing backups of an open tablespace without using RMAN, you must put tablespaces in backup mode to prevent the creation of fractured blocks in your backup. When not in backup mode, the database records only changed bytes in the redo stream. When a tablespace is in backup mode, each time a block is changed the database writes the before-image of the entire block to the redo stream before modifying the block. Then, the database also records the changes to the block in the redo log. During user-managed recovery using SQL*Plus, the database applies both the captured block images and the recorded block changes from the redo logs. Applying the block images repairs any possible fractured blocks in the backup being restored and recovered.

RMAN does not require that you put datafiles into backup mode. During an RMAN backup, a database server session reads each block of the datafile and checks whether each block is fractured by comparing the block header and footer. If a block is fractured, the session re-reads the block. If the same fracture is found, then the block is considered permanently corrupt. If MAXCORRUPT is exceeded, the backup stops.

Fractured Block explanation [ID 1392417.1]

   

In this Document
  Symptoms
  Cause
  Solution


Applies to:

Oracle Server - Enterprise Edition - Version: 10.2.0.4 and later   [Release: 10.2 and later ]
Information in this document applies to any platform.

Symptoms

Fractured block found causing ORA-1578 error

Cause

ORA-1578 error could be an indication of a fractured block. A fractured block is a clear symptom about serious issues within the O.S./H.W. layers.

In order to understand why a fractured block happens, we need to understand how a block is written into disk.

The block size at OS level does not match the block size at Oracle level, so in order to write an Oracle block, we need to perform more that one OS write.

As an example: if OS block size is 512 bytes and Oracle block is 8K, we need to perform 16 writes at OS level in order to complete the write process.

Oracle keeps track off the header of each block and constructs before writing down to disk by building a small 4 byte field/value in the tail of each block (tailchk) to guarantee it is correctly written

Example of a Fractured (Broken) block

Page 264462 is influx - most likely media corrupt
Corrupt block relative dba: 0x0284090e (file 10, block 264462)
Fractured block found during dbv:
Data in bad block:
type: 6 format: 2 rdba: 0x0284090e
last change scn: 0x0003.da17adf8 seq: 0x1 flg: 0x04
spare1: 0x0 spare2: 0x0 spare3: 0x0
consistency value in tail: 0xaead0601 <----------
check value in block header: 0x8564
computed block checksum: 0x355

-------------------------------------------------------------------------------------------

. tailchk: (current: 0xaead0601)
----------
It is built, at the footer of the block to guarantee the beginning and end of the block corresponds to the same version.
it is 4 bytes built as:

.- lower order 2 bytes of scn base - 0x....adf8
.- block type - 0x06
.- scn sequence number - 0x01

-> tailchk should have been 0xadf80601 in this block whilst it's 0xaead0601
-------------------------------------------------------------------------------------------

This value was right on the block oracle asked o.s. to write but, unfortunately, the write did not complete as a whole and only partial write was done or the write completed but invalid information was actually written in the block.

The tail check only verifies if the header and the tail of the block has been written correctly, but does not warranty that the complete block was written.

In order to warranty this, we have the database parameter DB_BLOCK_CHECKSUM
If this parameter is set to TRUE, we calculate a checksum value for the complete block and we write this information in the block header before writing the block. When the block is read again, this values is recomputed and compared with the one at block header.

There are checks that may be run against datafiles to ensure the validity of all tail values on all blocks of them.
DBV catches this kind of failures and may be used against your DB file(s) to check this.

Identically, there is a clear path to follow when this happens.
These blocks are badly written by o.s./h.w. and as such, Oracle operations over the block(s) affected are correct.
(otherwise, a different kind of error would have been printed out)

In addition, restoring and recovering the block is not introducing the issue again, what indicates that the redo changes generated are correct, so the issue is clearly related with other layer (most probably hardware layer)

Solution

Restore and recover the block from a valid backup

关于Oracle备份中的fractured block的更多相关文章

  1. Actifio中如何分析Oracle备份恢复的报错

    场景不同,可以分析的日志不同. 有关oracle备份 (L0/L1) 或者Oracle Log smart backups的日志:UDSAgent.log (on target host locate ...

  2. Oracle存储过程中异常Exception的捕捉和处理

    Oracle存储过程中异常的捕捉和处理 CREATE OR REPLACE Procedure Proc_error_process ( v_IN in Varchar2, v_OUT Out Var ...

  3. Oracle备份之RMAN

    1.备份:物理备份时文件层次的备份,逻辑备份时数据层次的备份,物理备份为主,逻辑备份作为补充.物理备份分为用户管理备份和RMAN备份,前者使用SQL命令和OS的cp命令进行文件备份,后者使用RMAN工 ...

  4. 【转】在rman增量备份中,有差异增量和累积增量的概念

    本文转自hougoo的博客 1.概念 差异增量:是备份上级及同级备份以来所有变化的数据块,差异增量是默认增量备份方式 累积增量:是备份上级备份以来所有变化的块 因为累积增量是备份上级备份以来所有变化的 ...

  5. oracle BBED 直接改动数据库block块

    1.BBED配置 1)将相应文件放到$ORACLE_HOME/rdbms/mesg和$ORACLE_HOME/rdbms/lib中:     --将lib中bbedus.msb和bbedus.msg ...

  6. [转帖]oracle备份恢复之recover database的四条语句区别

    oracle备份恢复之recover database的四条语句区别 https://www.cnblogs.com/andy6/p/5925433.html 需要学习一下. 1  recover d ...

  7. Oracle 备份与还原

    oracle 备份与还原 一.备份数据库(exp) 1.完全备份 exp demo/demo@orcl buffer=1024 file=d:\back.dmp full=y demo:用户名.密码 ...

  8. 关于Oracle GoldenGate中Extract的checkpoint的理解 转载

    什么是checkpoint? 在Oracle 数据库中checkpoint的意思是将内存中的脏数据强制写入到磁盘的事件,其作用是保持内存中的数据与磁盘上的数据一致.SCN是用来描述该事件发生的准确的时 ...

  9. Oracle数据库中SYS、SYSTEM、DBSNMP、SYSMAN四用户的区别

    [转]   SYS.SYSTEM.DBSNMP. Oracle 数据库中 SYS.SYSTEM.DBSNMP.SYSMAN 四用户的区别 用户: SYS 用户: SYS,默认密码为 CHANGE_ON ...

随机推荐

  1. BZOJ 1833 ZJOI2010 count 数字计数 数位DP

    题目大意:求[a,b]间全部的整数中0~9每一个数字出现了几次 令f[i]为i位数(算前导零)中每一个数出现的次数(一定是同样的,所以仅仅记录一个即可了) 有f[i]=f[i-1]*10+10^(i- ...

  2. IOS 开展 分别制定了iphone 和 ipad 好? 或开发一个 Universal好?

    最近因为工作的需要,.因为时间短的开发周期 开发的需要 积 至iphone 和 ipad 台 执行 优势的版本号 1.安装包,轻松管理,分布 2.您下载iphone,ipad 会自己主动下载 3.审核 ...

  3. 纯CSS绘制三角形

    扒segmentfault的导航栏时候发现的,用了个span标签写了个三角形出来,第一次发现,好神奇,查了下还有挺多种玩法的.基本的用法就是将盒子的width和height设为0,然后用border搭 ...

  4. UVA 1603 Square Destroyer

    题意: 给定一个火柴棒拼成的方格阵,然后去掉一些火柴棒,问至少再去掉几根火柴棒能够让图中一个正方形都没有. 思路: 1. 由于题目中给定了 n 的范围,2 * n * (n + 1) <= 60 ...

  5. HTML——CSS样式表&布局页面

    CSS样式表: 一.作用:美化网页,页面布局. 二.分类: 内联,写在body里标签style=""里面的样式,优点是控制精确,可重用性差. 内嵌,嵌在网页的head里面,可重用性 ...

  6. mysql 批量更新

    bs_user 表,我们叫他 bu表, 字段user_id,len_id, think_wellUser 表,我们简称为tw表,中的user_id ,len_id 其中tw表的user_id 是bu表 ...

  7. jQuery绑定事件-多种方式实现

    jQuery绑定事件-多种方式实现: <html> <head> <meta charset="utf-8" /> <script src ...

  8. PHP学习日记(一)——类、函数的使用

    一.自定义函数 function add($a,$b){ $c=$a+$b; echo 'add test:'; echo $c; return $c; } add(1,2); 输出结果: add t ...

  9. Spring与Mybatis配置问题

    Spring和Mybatis的整合,主要借助于Spring的依赖注入和控制反转来简化Mybatis的配置,使用两个配置文件[注:此种配置文件网上已经有很多]: spring.xml: <?xml ...

  10. 验证身份证合法性的js

    分别对15和18位的身份证号进行验证,非常严格. function idCardNo(value){ //验证身份证号方法 : : : : : : : : : : : : : : : : : : : ...