博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
Basic Concepts of Block Media Recovery
阅读量:6364 次
发布时间:2019-06-23

本文共 4530 字,大约阅读时间需要 15 分钟。

Basic Concepts of Block Media Recovery

Whenever block corruption has been automatically detected, you can perform block media recovery manually with the RECOVER ... BLOCK command. By default, RMAN first searches for good blocks in the real-time query physical standby database, then flashback logs and then blocks in full or level 0 incremental backups.

Identification of Corrupt Blocks

The V$DATABASE_BLOCK_CORRUPTION view displays blocks marked corrupt by database components such as RMAN, ANALYZE, dbv, and SQL queries.

The following types of corruption result in the addition of rows to this view:

Physical corruption (sometimes called media corruption) The database does not recognize the block: the checksum is invalid, the block contains all zeros, or the block header is corrupt. Physical corruption checking is enabled by default. You can turn off checksum checking by specifying the NOCHECKSUM option of the BACKUP command, but other physical consistency checks, such as checks of the block headers and footers, cannot be disabled.

Logical corruption:

The block has a valid checksum, the header and footer match, and so on, but the contents are logically inconsistent. Block media recovery may not be able to repair all logical block corruptions. In these cases, alternate recovery methods, such as tablespace point-in- time recovery, or dropping and re-creating the affected objects, may repair the corruption. Logical corruption checking is disabled by default. You can turn it on by specifying the CHECK LOGICAL option of the BACKUP, RESTORE, RECOVER, and VALIDATE commands.

The database can detect some corruptions by validating relationships between blocks and segments, but cannot detect them by a check of an individual block.

The V$DATABASE_BLOCK_CORRUPTION view does not record at this level of granularity.

Prerequisites for Block Media Recovery (link)

The following prerequisites apply to the RECOVER ... BLOCK command:

The target database must run in ARCHIVELOG mode and be open or mounted with a current control file.

If the target database is a standby database, then it must be in a consistent state, recovery cannot be in session, and the backup must be older than the corrupted file.

The backups of the data files containing the corrupt blocks must be full or level 0 backups and not proxy copies.

If only proxy copy backups exist, then you can restore them to a nondefault location on disk, in which case RMAN considers them data file copies and searches them for blocks during block media recovery.

RMAN can use only archived redo logs for the recovery. RMAN cannot use level 1 incremental backups. Block media recovery cannot survive a missing or inaccessible archived redo log, although it can sometimes survive missing redo records.

Flashback Database must be enabled on the target database for RMAN to search the flashback logs for good copies of corrupt blocks. If flashback logging is enabled and contains older, uncorrupted versions of the corrupt blocks, then RMAN can use these blocks, possibly speeding up the recovery. The target database must be associated with a real-time query physical standby database for RMAN to search the database for good copies of corrupt blocks.

Purpose of Block Media Recovery

You can use block media recovery to recover one or more corrupt data blocks within a data file. Block media recovery provides the following advantages over data file media recovery:

Lowers the mean time to recover (MTTR) because only blocks needing recovery are restored and recovered.

Enables affected data files to remain online during recovery

Without block media recovery, if even a single block is corrupt, then you must take the data file offline and restore a backup of the data file. You must apply all redo generated for the data file after the backup was created. The entire file is unavailable until media recovery completes. With block media recovery, only the blocks actually being recovered are unavailable during the recovery

Block media recovery is most useful for physical corruption problems that involve a small, well- known number of blocks. Block-level data loss usually results from intermittent, random I/O errors that do not cause widespread data loss, and memory corruptions that are written to disk. Block media recovery is not intended for cases where the extent of data loss or corruption is unknown and the entire data file requires recovery. In such cases, data file media recovery is the best solution.

转载于:https://www.cnblogs.com/rusking/p/4353049.html

你可能感兴趣的文章
协鑫集成第二批1000台E-KwBe光伏储能设备即将启运澳洲
查看>>
爱立信物联网广州路演
查看>>
云计算企业业绩分化明显 9家上市公司中期预喜
查看>>
《VMware Virtual SAN权威指南(原书第2版)》一3.5 可能发生的网络配置问题
查看>>
SK电讯发布Q2财报 净利润同比下降26.9%
查看>>
零售品牌如何驾驭大数据主导商业决策?
查看>>
经济模式UPS在数据中心的应用(上)
查看>>
Intel首款32核Xeon E5 v5跑分曝光:史上最强
查看>>
中国基于国产龙芯处理器的大数据一体机
查看>>
物联网影响商业发展三要素
查看>>
干货分享-FASTJSON那些事.pptx
查看>>
China Unicom and Chunghwa Telecom work together&nb
查看>>
Java图片上查找图片算法
查看>>
Python fabric实现远程操作和部署
查看>>
详解Java中staitc关键字
查看>>
《Unity着色器和屏幕特效开发秘笈》—— 第3章 利用镜面反射让游戏闪耀起来...
查看>>
前中情局局长:FBI目的是从根本上改善iPhone
查看>>
测试界和学术界应该架起桥梁
查看>>
大隐隐于市,你身边的那些安全隐患你都知道么?
查看>>
这个物联网处理器号称全世界体型最小
查看>>