问题描述:
DATA COLLECTED
===============
CUSTOMER STATEMENT
------------------
不过在恢复数据的过程中,用8月1号的全备份,恢复到8月26号的时候有报错,好像是在8月26号时有在数据库中新增一个数据文件。
错误信息如下:
……
archive log filename=/image/oraywzkr/archive/arch_2bc2b0e5_1_684411423_3030.log thread=1
sequence=3030
archive log filename=/image/oraywzkr/archive/arch_2bc2b0e5_1_684411423_3031.log thread=1
sequence=3031
creating datafile fno=22 name=/ywzkr_db/ywzkr/jy_data_tbs04.dbf
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 10/23/2009 09:33:22
ORA-01119: error in creating database file '/ywzkr_db/ywzkr/jy_data_tbs04.dbf'
ORA-27040: file create error, unable to create file
HPUX-ia64 Error: 2: No such file or directory
其中/ywzkr_db/ywzkr/jy_data_tbs04.dbf 应该是8月26号在生产库中新增的一个数据文件,这个问题应该如何解决,敬请李顾问回电,谢谢!
看错误信息好像找不到ywzkr_db路径,做了一个软连接:
ln -s /image/oraywzkr/oradata /ywzkr_db
在执行recover操作:
RMAN> run {
2> set newname for datafile '/ywzkr_db/ywzkr/jy_data_tbs04.dbf' to
'/image/oraywzkr/oradata/ywzkr/jy_data_tbs04.dbf';
3> recover database until time '2009-08-26 22:00:00';
4> }
executing command: SET NEWNAME
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of set command at 10/23/2009 09:39:33
RMAN-20201: datafile not found in the recovery catalog
RMAN-06010: error while looking up datafile: /ywzkr_db/ywzkr/jy_data_tbs04.dbf
RMAN> recover database until time '2009-08-26 22:00:00';
Starting recover at 2009-10-23 09:43:27
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 10/23/2009 09:43:27
RMAN-06094: datafile 22 must be restored
RMAN> recover database until time '2009-08-25 22:00:00';
Starting recover at 2009-10-23 09:44:27
using channel ORA_DISK_1
RMAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: failure of recover command at 10/23/2009 09:44:28
RMAN-06094: datafile 22 must be restored
解决办法:
ACTION PLAN
============
1. recover database
run
{
set until time "to_date('2009-08-26 22:00:00','yyyy-mm-dd hh24:mi:ss')";
recover database;
}
2. Error occured then issue following sql.
SQL>select name from v$datafile where file#=22;
=>UNNAMED0002
SQL>alter database create datafile 'UNNAMED0002' as '/image/oraywzkr/oradata/ywzkr/jy_data_tbs04.dbf';
3. recover database again.
run
{
set until time "to_date('2009-08-26 22:00:00','yyyy-mm-dd hh24:mi:ss')";
recover database;
}
For more detail ,you can refer to Note 130724.1 RMAN-06023 Recover from Missing Datafile that is Never Backed Up
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/11411056/viewspace-734423/ ,如需转载,请注明出处,否则将追究法律责任。