块冲突的恢复

以下过程是在先备份的情况下出现datafile个别块的冲突,利用rman自动进行检查修复的过程
 
RMAN> connect target /
connected to target database: DAVID (DBID=311970017)
RMAN> connect catalog cat/cat@rcat
connected to recovery catalog database
RMAN> backup as copy tablespace bctbs;
Starting backup at 25-OCT-13
starting full resync of recovery catalog
full resync complete
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=36 device type=DISK
channel ORA_DISK_1: starting datafile copy
input datafile file number=00006 name=/opt/oracle/oradata/david/bctbs01.dbf
output file name=/opt/oracle/fast_recovery_area/DAVID/datafile/o1_mf_bctbs_96nbkvcb_.dbf tag=TAG20131025T162218 RECID=2 STAMP=829758139
channel ORA_DISK_1: datafile copy complete, elapsed time: 00:00:01
Finished backup at 25-OCT-13
Starting Control File and SPFILE Autobackup at 25-OCT-13
piece handle=/opt/oracle/fast_recovery_area/DAVID/autobackup/2013_10_25/o1_mf_s_829758141_96nbkx8n_.bkp comment=NONE
Finished Control File and SPFILE Autobackup at 25-OCT-13
RMAN> backup tablespace bctbs;
Starting backup at 25-OCT-13
using channel ORA_DISK_1
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00006 name=/opt/oracle/oradata/david/bctbs01.dbf
channel ORA_DISK_1: starting piece 1 at 25-OCT-13
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03009: failure of backup command on ORA_DISK_1 channel at 10/25/2013 16:37:23
ORA-19566: exceeded limit of 0 corrupt blocks for file /opt/oracle/oradata/david/bctbs01.dbf
RMAN>
RMAN>
RMAN>
RMAN> list failure detail;
List of Database Failures
=========================
Failure ID Priority Status    Time Detected Summary
---------- -------- --------- ------------- -------
202        HIGH     OPEN      25-OCT-13     Datafile 6: '/opt/oracle/oradata/david/bctbs01.dbf' contains one or more corrupt blocks
  Impact: Some objects in tablespace BCTBS might be unavailable
  List of child failures for parent failure ID 202
  Failure ID Priority Status    Time Detected Summary
  ---------- -------- --------- ------------- -------
  211        HIGH     OPEN      25-OCT-13     Block 130 in datafile 6: '/opt/oracle/oradata/david/bctbs01.dbf' is media corrupt
    Impact: Object BCCOPY owned by BC might be unavailable
  205        HIGH     OPEN      25-OCT-13     Block 129 in datafile 6: '/opt/oracle/oradata/david/bctbs01.dbf' is media corrupt
    Impact: Object BCCOPY owned by BC might be unavailable
RMAN> advise failure all;
List of Database Failures
=========================
Failure ID Priority Status    Time Detected Summary
---------- -------- --------- ------------- -------
202        HIGH     OPEN      25-OCT-13     Datafile 6: '/opt/oracle/oradata/david/bctbs01.dbf' contains one or more corrupt blocks
analyzing automatic repair options; this may take some time
using channel ORA_DISK_1
analyzing automatic repair options complete
Mandatory Manual Actions
========================
no manual actions available
Optional Manual Actions
=======================
no manual actions available
Automated Repair Options
========================
Option Repair Description
------ ------------------
1      Recover multiple corrupt blocks in datafile 6 
  Strategy: The repair includes complete media recovery with no data loss
  Repair script. /opt/oracle/diag/rdbms/david/david/hm/reco_202008186.hm
RMAN> repair failure;
Strategy: The repair includes complete media recovery with no data loss
Repair script. /opt/oracle/diag/rdbms/david/david/hm/reco_202008186.hm
contents of repair script.:
   # block media recovery for multiple blocks
   recover datafile 6 block 129 to 130;
Do you really want to execute the above repair (enter YES or NO)? yes
executing repair script
Starting recover at 25-OCT-13
using channel ORA_DISK_1
channel ORA_DISK_1: restoring block(s) from datafile copy /opt/oracle/fast_recovery_area/DAVID/datafile/o1_mf_bctbs_96nbkvcb_.dbf
starting media recovery
media recovery complete, elapsed time: 00:00:01
Finished recover at 25-OCT-13
repair failure complete
RMAN> list failure all;
no failures found that match specification
RMAN>

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

转载于:http://blog.itpub.net/26870952/viewspace-775040/

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值