leonheart 发表于 2018-9-9 10:40:59

Oracle 学习之RMAN(十三)恢复实战--数据块修复

SQL> shutdown immediate  
Database closed.
  
Database dismounted.
  
ORACLE instance shut down.
  
SQL> startup
  
ORACLE instance started.
  

  
Total System Global Area839282688 bytes
  
Fixed Size    2233000 bytes
  
Variable Size553651544 bytes
  
Database Buffers281018368 bytes
  
Redo Buffers    2379776 bytes
  
Database mounted.
  
ORA-01157: cannot identify/lock data file 7 - see DBWR trace file
  
ORA-01110: data file 7: '/u01/app/oracle/oradata/devdb/blkerr01.dbf'
  
RMAN> restore datafile 7;
  

  
Starting restore at 2015/07/09 10:36:25
  
using target database control file instead of recovery catalog
  
allocated channel: ORA_DISK_1
  
channel ORA_DISK_1: SID=20 device type=DISK
  

  
channel ORA_DISK_1: starting datafile backup set restore
  
channel ORA_DISK_1: specifying datafile(s) to restore from backup set
  
channel ORA_DISK_1: restoring datafile 00007 to /u01/app/oracle/oradata/devdb/blkerr01.dbf
  
channel ORA_DISK_1: reading from backup piece /u01/app/oracle/fast_recovery_area/DEVDB/backupset/2015_07_09/o1_mf_nnndf_TAG20150709T103011_bsvq5mw9_.bkp
  
channel ORA_DISK_1: piece handle=/u01/app/oracle/fast_recovery_area/DEVDB/backupset/2015_07_09/o1_mf_nnndf_TAG20150709T103011_bsvq5mw9_.bkp tag=TAG20150709T103011
  
channel ORA_DISK_1: restored backup piece 1
  
channel ORA_DISK_1: restore complete, elapsed time: 00:00:01
  
Finished restore at 2015/07/09 10:36:27
  

  
RMAN> recover datafile 7;
  

  
Starting recover at 2015/07/09 10:36:40
  
using channel ORA_DISK_1
  

  
starting media recovery
  
media recovery complete, elapsed time: 00:00:00
  

  
Finished recover at 2015/07/09 10:36:41


页: [1]
查看完整版本: Oracle 学习之RMAN(十三)恢复实战--数据块修复