To use Rman to duplicate database be careful of db_file_name_convert
Actually, it's very easy for every dba to use rman to duplicate database.However,because of its simple, so we are likely to make mistakes. The following is typical errors,Let me share with you,Happy every day:
When i input rman command which is duplicate target database to newdb_name,
record log :
恢復管理器: Release 10.2.0.1.0 - Production on 星期二 7月 21 17:09:47 2009
Copyright (c) 1982, 2005, Oracle. All rights reserved.
連線到目標資料庫: DG2 (DBID=1468921071)
已連線到輔助資料庫: AUXDB (未裝載)
RMAN>
RMAN-03036: 除錯的設定為級別 =9, 型別 =ALL
RMAN>
RMAN-03090: 啟動 Duplicate Db 於 21-7月 -09
RMAN-06009: 使用目標資料庫控制檔案替代恢復目錄
RMAN-08030: 分配的通道: ORA_AUX_DISK_1
RMAN-08500: 通道 ORA_AUX_DISK_1: sid=158 devtype=DISK
RMAN-08030: 分配的通道: ORA_AUX_DISK_2
RMAN-08500: 通道 ORA_AUX_DISK_2: sid=159 devtype=DISK
RMAN-08161: 記憶體指令碼的內容:
{
set until scn 808318;
set newname for datafile 1 to
"D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\SYSTEM01.DBF";
set newname for datafile 2 to
"D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\UNDOTBS01.DBF";
set newname for datafile 3 to
"D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\SYSAUX01.DBF";
set newname for datafile 4 to
"D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\DG2\DATAFILE\USERS.258.692722797";
restore
check readonly
clone database
;
}
RMAN-08162: 正在執行記憶體指令碼
RMAN-03023: 正在執行命令: SET until clause
RMAN-03023: 正在執行命令: SET NEWNAME
RMAN-03023: 正在執行命令: SET NEWNAME
RMAN-03023: 正在執行命令: SET NEWNAME
RMAN-03023: 正在執行命令: SET NEWNAME
RMAN-03090: 啟動 restore 於 21-7月 -09
RMAN-12016: 使用通道 ORA_AUX_DISK_1
RMAN-12016: 使用通道 ORA_AUX_DISK_2
RMAN-06716: 正在略過資料檔案 2; 已恢復到檔案 D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\UNDOTBS01.DBF
RMAN-06716: 正在略過資料檔案 3; 已恢復到檔案 D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\SYSAUX01.DBF
RMAN-08016: 通道 ORA_AUX_DISK_1: 正在開始恢復資料檔案備份集
RMAN-08089: 通道 ORA_AUX_DISK_1: 正在指定從備份集恢復的資料檔案
RMAN-08523: 正將資料檔案00001恢復到D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\SYSTEM01.DBF
RMAN-08523: 正將資料檔案00004恢復到D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\DG2\DATAFILE\USERS.258.692722797
RMAN-08003: 通道 ORA_AUX_DISK_1: 正在讀取備份段 D:\ORACLE\PRODUCT\10.2.0\FLASH_RECOVERY_AREA\DG2\BACKUPSET\2009_07_21\O1_MF_NNNDF_TAG20090721T164140_56BZT52G_.BKP
RMAN-01005:
RMAN-05016: 故障轉移到上一個備份
RMAN-08019: 通道 ORA_AUX_DISK_1: 正在恢復資料檔案00001
RMAN-08507: 輸入資料檔案副本 recid=8 stamp=692813389 檔名=D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\DATA_D-DG2_I-1468921071_TS-SYSTEM_FNO-1_1LKKMVG3
RMAN-08509: 資料檔案 00001 的恢復目標: D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\SYSTEM01.DBF
RMAN-08019: 通道 ORA_AUX_DISK_2: 正在恢復資料檔案00004
RMAN-08507: 輸入資料檔案副本 recid=11 stamp=692813643 檔名=D:\ORACLE\PRODUCT\10.2.0\FLASH_RECOVERY_AREA\DG2\DATAFILE\O1_MF_USERS_56BY6B00_.DBF
RMAN-08509: 資料檔案 00004 的恢復目標: D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\DG2\DATAFILE\USERS.258.692722797
RMAN-01005:
RMAN-08007: 通道 ORA_AUX_DISK_1: 已複製資料檔案 00001 的資料檔案副本
RMAN-08505: 輸出檔名=D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\SYSTEM01.DBF
RMAN-05016: 故障轉移到上一個備份
RMAN-08019: 通道 ORA_AUX_DISK_1: 正在恢復資料檔案00004
RMAN-08507: 輸入資料檔案副本 recid=10 stamp=692813398 檔名=D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\DATA_D-DG2_I-1468921071_TS-USERS_FNO-4_1OKKMVIL
RMAN-08509: 資料檔案 00004 的恢復目標: D:\ORACLE\PRODUCT\10.2.0\ORADATA\TEST\DG2\DATAFILE\USERS.258.692722797
RMAN-01005:
RMAN-05016: 故障轉移到上一個備份
MAN-00571: ===========================================================
RMAN-00569: =============== ERROR MESSAGE STACK FOLLOWS ===============
RMAN-00571: ===========================================================
RMAN-03002: Duplicate Db 命令 (在 07/21/2009 17:23:53 上) 失敗
RMAN-03015: 在儲存的指令碼Memory Script中出現錯誤
RMAN-06026: 有些目標沒有找到 - 終止恢復
RMAN-06023: 沒有找到資料檔案4的副本來恢復
Errors shows: It cannot find any copy of datafile 4 from target database,but I have two copies of datafile 4.I'm confused that why rman cannot identify that copy.
I check parameters of auxiliary database:
SQL> show parameter db_file_name
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
db_file_name_convert string D:\oracle\product\10.2.0\orada
ta\dg2, D:\oracle\product\10.2
.0\oradata\test, +STANDBY, D:\oracle\product\10
.2.0\oradata\test
I know the reason why rman cannot identifiy.Obviously,rman cannot automatically identify ASM diskgroup catalog,so i must modify that parameter through db_file_name_convert to tell rman detail catalog of that datafile.
Modified parameteres:
SQL> show parameter db_file_name
NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
db_file_name_convert string D:\oracle\product\10.2.0\orada
ta\dg2, D:\oracle\product\10.2
.0\oradata\test, +STANDBY/dg2/
datafile, D:\oracle\product\10
.2.0\oradata\test
To again duplicate database is ok.Good Luck!!
Never Failed To Seize Day,Go-!!!
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/175005/viewspace-609861/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- RMAN duplicate databaseDatabase
- 通過rman duplicate database!Database
- RMAN duplicate database到新主機Database
- How to use rman backup a noarchivelog databaseHiveDatabase
- Oracle 11g Rman Active database duplicateOracleDatabase
- Duplicate Database from ASM to Non- ASM Database Using RMANDatabaseASM
- Oracle11g RMAN Duplicate from Active DatabaseOracleDatabase
- Duplicating Database using RMAN duplicate commandDatabase
- oracle實驗記錄Rman duplicate database(1)OracleDatabase
- oracle實驗記錄Rman duplicate database 2OracleDatabase
- 11g rman新特性 duplicate target database for standby from active databaseDatabase
- RMAN duplicate from active database 複製資料庫Database資料庫
- RMAN 'Duplicate Database' Feature in 11G [ID 452868.1]Database
- duplicate databaseDatabase
- Performing duplicate database with ASM/OMF/RMAN (Doc ID 340848.1)ORMDatabaseASM
- RMAN Duplicate Database From RAC ASM To RAC ASM [ID 461479.1]DatabaseASM
- rman duplicate target database RMAN-03002 RMAN-03015 RMAN-06136Database
- Creating a Physical Standby using RMAN DUPLICATE FROM ACTIVE DATABASEDatabase
- 使用RMAN DUPLICATE...FROM ACTIVE DATABASE命令來建立DataGuard物理備庫Database
- 11g RMAN新特性active database duplicate 資料庫異構Database資料庫
- DUPLICATE DATABASE 注意事項Database
- RMAN duplicate On Windows7Windows
- rman duplicate建立異地auxiliary Database oracle_11g oracle_sid不同UXDatabaseOracle
- rman duplicate建立異地auxiliary Database oracle_11g oracle_sid相同UXDatabaseOracle
- Oracle 11gR2 使用 RMAN duplicate from active database 複製資料庫OracleDatabase資料庫
- Duplicate Active Database Failing with: RMAN-03009, ORA-17628DatabaseAI
- Creating a Data Guard Database with RMAN using Duplicate Command [ID 183570.1]Database
- Oracle 11G Duplicate DatabaseOracleDatabase
- 使用oracle 11g rman新特性 duplicate target database for standby from active database 建立物理dataguard並開啟RealOracleDatabase
- 使用 RMAN DUPLICATE...FROM ACTIVE DATABASE 建立物理備用資料庫的分步指南Database資料庫
- oracle 10g rman duplicate target database for standby會自動新增臨時檔案Oracle 10gDatabase
- RMAN Duplicate Database 的學習與測試_20100129Database
- rman duplicate操作手冊
- RMAN duplicat databaseDatabase
- rman recover databaseDatabase
- Step by Step Guide on Creating Physical Standby Using RMAN DUPLICATE...FROM ACTIVE DATABASE WithoutGUIIDEDatabase
- Exclusive access could not be obtained because the database is in useAIDatabase
- Oracle rman duplicate遷移測試Oracle