程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
 程式師世界 >> 數據庫知識 >> Oracle數據庫 >> Oracle教程 >> RMAN-06023: no backup or copy of datafile 1 found to restore,rman-06023datafile

RMAN-06023: no backup or copy of datafile 1 found to restore,rman-06023datafile

編輯:Oracle教程

RMAN-06023: no backup or copy of datafile 1 found to restore,rman-06023datafile


在ORACLE 10g數據庫還原過程遭遇RMAN-06023: no backup or copy of datafile x found to restore,具體情況如下所示

.....................................................................................
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_10_bdcwsc6t_.arc
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_23_bdcxwwx6_.arc
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_16_bdcxwgmd_.arc
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_39_bdczfb6o_.arc
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_40_bdczzotd_.arc
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_19_bdcxwmoy_.arc
File Name: /u03/flash_recovery_area/EPPS/archivelog/2015_01_26/o1_mf_1_31_bdcyvsk0_.arc
 
using channel ORA_DISK_1
 
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of restore command at 03/06/2015 21:56:26
RMAN-06026: some targets not found - aborting restore
RMAN-06023: no backup or copy of datafile 4 found to restore
RMAN-06023: no backup or copy of datafile 3 found to restore
RMAN-06023: no backup or copy of datafile 1 found to restore
 
RMAN>

在RMAN裡面使用restore database validate驗證備份時也報RMAN-06023錯誤

RMAN> list backup of datafile 1;
 
using target database control file instead of recovery catalog
 
List of Backup Sets
===================
 
BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
46739   Full    1.75G      DISK        00:16:07     05-MAR-15      
        BP Key: 50263   Status: AVAILABLE  Compressed: YES  Tag: TAG20150305T010709
        Piece Name: /u03/flash_recovery_area/backup/backupsets/ora_df873514789_s46810_s1
  List of Datafiles in backup set 46739
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  1       Full 17572554495 05-MAR-15 /u01/app/oracle/oradata/epps/system01.dbf
 
RMAN> list backup of datafile 3;
 
 
List of Backup Sets
===================
 
BS Key  Type LV Size       Device Type Elapsed Time Completion Time
------- ---- -- ---------- ----------- ------------ ---------------
46736   Full    8.83G      DISK        00:52:30     05-MAR-15      
        BP Key: 50260   Status: AVAILABLE  Compressed: YES  Tag: TAG20150305T010709
        Piece Name: /u03/flash_recovery_area/backup/backupsets/ora_df873508030_s46807_s1
  List of Datafiles in backup set 46736
  File LV Type Ckp SCN    Ckp Time  Name
  ---- -- ---- ---------- --------- ----
  3       Full 17571362089 05-MAR-15 /u01/app/oracle/oradata/epps/sysaux01.dbf

[oracle@getlnx01 archivelog]$ ls /u03/flash_recovery_area/backup/backupsets/ora_df873508030_s46807_s1
 
/u03/flash_recovery_area/backup/backupsets/ora_df873508030_s46807_s1
 

檢查備份文件,發現都是存在的,根本沒有問題。最後檢查發現是incarnation的問題,因為中間我對該數據庫做了一次不完全恢復,做了resetlogs操作。

RMAN>  list incarnation;
 
 
List of Database Incarnations
DB Key  Inc Key DB Name  DB ID            STATUS  Reset SCN  Reset Time
------- ------- -------- ---------------- --- ---------- ----------
1       1       EPPS     2179993557       PARENT  1          30-JUN-05
2       2       EPPS     2179993557       PARENT  446075     19-JUL-09
3       3       EPPS     2179993557       CURRENT 16926695161 23-JAN-15

 

解決方法:

   重置數據庫的incarnation到2,然後還原數據庫,問題解決。關於incarnation的資料,可以參考官方資料7.6.2 Point-in-Time Recovery and Database Incarnations: Concepts

RMAN> reset database to incarnation 2;
 
database reset to incarnation 2

  1. 上一頁:
  2. 下一頁:
Copyright © 程式師世界 All Rights Reserved