Oracle Active Data Guard調整案例[2]
客戶的Oracle 11gR2 Active Data Guard環境,主資料庫的standby_file_management=AUTO,備用資料庫的standby_file_management=MANUAL,導致在主資料庫為表空間新增的資料檔案操作沒有同步到備用資料庫,在$ORACLE_HOME/dbs目錄下也沒有建立類似UNNAMED00003的檔案,備用資料庫有如下的告警日誌:
Tue Sep 02 17:37:36 2014
File #3 added to control file as 'UNNAMED00003' because
the parameter STANDBY_FILE_MANAGEMENT is set to MANUAL
The file should be manually created to continue.
MRP0: Background Media Recovery terminated with error 1274
Errors in file /u01/app/oracle/diag/rdbms/d012dg/d012band/trace/d012band_pr00_5702078.trc:
ORA-01274: cannot add datafile '/oradata1/d012band/tsmisc06.dbf' - file could not be created
Managed Standby Recovery not using Real Time Apply
Recovery interrupted!
Recovered data files to a consistent state at change 866102511
Tue Sep 02 17:37:46 2014
MRP0: Background Media Recovery process shutdown (d012band)
Tue Sep 02 17:52:14 2014
RFS[1]: Selected log 8 for thread 1 sequence 19136 dbid 2134147111 branch 809469738
Tue Sep 02 17:52:25 2014
Archived Log entry 511 added for thread 1 sequence 19135 ID 0x7f340827 dest 1:
Tue Sep 02 17:53:23 2014
alter database recover managed standby database using current logfile disconnect from session
Attempt to start background Managed Standby Recovery process (d012band)
Tue Sep 02 17:53:23 2014
MRP0 started with pid=42, OS id=7471452
MRP0: Background Managed Standby Recovery process started (d012band)
started logmerger process
Tue Sep 02 17:53:29 2014
Managed Standby Recovery starting Real Time Apply
Tue Sep 02 17:53:30 2014
Errors in file /u01/app/oracle/diag/rdbms/d012dg/d012band/trace/d012band_dbw0_4784178.trc:
ORA-01186: file 3 failed verification tests
ORA-01157: cannot identify/lock data file 3 - see DBWR trace file
ORA-01111: name for data file 3 is unknown - rename to correct file
ORA-01110: data file 3: '/u01/app/oracle/product/11.2.0/db_1/dbs/UNNAMED00003'
如果能夠找到/u01/app/oracle/product/11.2.0/db_1/dbs/UNNAMED00003檔案,可以參考文章:《11gR2 Active Data Guard調整案例[1]》http://blog.itpub.net/23135684/viewspace-759592/
File 3 not verified due to error ORA-01157
MRP0: Background Media Recovery terminated with error 1111
Errors in file /u01/app/oracle/diag/rdbms/d012dg/d012band/trace/d012band_pr00_8716760.trc:
ORA-01111: name for data file 3 is unknown - rename to correct file
ORA-01110: data file 3: '/u01/app/oracle/product/11.2.0/db_1/dbs/UNNAMED00003'
ORA-01157: cannot identify/lock data file 3 - see DBWR trace file
ORA-01111: name for data file 3 is unknown - rename to correct file
ORA-01110: data file 3: '/u01/app/oracle/product/11.2.0/db_1/dbs/UNNAMED00003'
Managed Standby Recovery not using Real Time Apply
Slave exiting with ORA-1111 exception
Errors in file /u01/app/oracle/diag/rdbms/d012dg/d012band/trace/d012band_pr00_8716760.trc:
ORA-01111: name for data file 3 is unknown - rename to correct file
ORA-01110: data file 3: '/u01/app/oracle/product/11.2.0/db_1/dbs/UNNAMED00003'
ORA-01157: cannot identify/lock data file 3 - see DBWR trace file
ORA-01111: name for data file 3 is unknown - rename to correct file
ORA-01110: data file 3: '/u01/app/oracle/product/11.2.0/db_1/dbs/UNNAMED00003'
Recovery Slave PR00 previously exited with exception 1111
MRP0: Background Media Recovery process shutdown (d012band)
Completed: alter database recover managed standby database using current logfile disconnect from session
解決這個問題的關鍵是手動建立新新增的資料檔案,參考如下的內容解決該問題:
How to resolve MRP stuck issues on a physical standby database? (文件 ID 1221163.1)
......
Solution 10 Add the new datafiles to the standby database manually.
1) Please take a hot backup of new datafiles from the primary database.
2) Create a new standby controlfile from the primary database by
SQL>alter database create standby controlfile as '/tmp/controlf.ctl';
If datafiles are on ASM, please follow the note below and you could ignore the rest of steps:
Note 734862.1 Step By Step Guide On How To Recreate Standby Control File
When Datafiles Are On ASM And Using Oracle Managed Files
Or you could modify the wrong datafile name in the standby controlfile by alter database rename command. For example,
SQL> ALTER DATABASE RENAME FILE '
3) If the new datafile location on the primary is different from the standby, please make sure
db_file_name_convert init parameter is set on the standby database.
Note 47325.1 Init.ora Parameter "DB_FILE_NAME_CONVERT" Reference Note
If db_file_name_convert init parameter has already been set, then you could ignore this step.
4) Cancel the managed recovery
SQL>alter database recover managed standby database cancel;
5) set standby_file_management=manual on the standby database and shutdown the standby database.
SQL>alter system set standby_file_management=manual sid='*';
SQL>shutdown immediate;
6) Copy the hot backup of the new datafiles and the new standby controlfile to the standby.
Please make sure the controlfiles are located in the right location with right names
according to the init parameter control_files. Please make sure the copied datafiles are
located in the right location as well according to name from v$datafile.
7) startup the standby database in mount mode and set standby_file_management=auto.
SQL>startup mount;
SQL>alter system set standby_file_management=auto sid='*';
8) Start the managed recovery.
SQL>alter database recover managed standby database disconnect;
......
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/23135684/viewspace-1262326/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- Oracle 11gR2 Database和Active Data Guard遷移案例OracleDatabase
- Oracle 11g Data Guard Enabling Active Data GuardOracle
- Active Data Guard初探(一)
- oracle active data guard real-time apply特性OracleAPP
- 搭建Active Data Guard環境
- Oracle 12.2 How to Generate AWRs in Active Data Guard Standby DatabasesOracleDatabase
- Oracle 12c 新特性 Active Data Guard Far SyncOracle
- Oracle 11g Data Guard 使用duplicate from active databaseOracleDatabase
- 2 Oracle Data Guard 安裝Oracle
- Oracle 12c新特性 - Active Data Guard功能增強Oracle
- Oracle 11g Data Guard (physical standby - active dataguard) [final]Oracle
- 11gR2 Active Data Guard 閃回 - flashback database / snapshot standby - 2Database
- G008-ORACLE-DG ORACLE 19C Active Data Guard DML RedirectionOracle
- oracle data guard!!Oracle
- Script to Collect Data Guard Physical and Active Standby Diagnostic InformationORM
- 【DataGuard】11g 新特性:Active Data Guard
- 實戰11g active data guard on rac
- 2 開始實用 Oracle Data GuardOracle
- Oracle goldengate 12c 新特性之完美支援Active Data GuardOracleGo
- Oracle 11g Data Guard 使用 duplicate from active database 建立 standby databaseOracleDatabase
- Oracle 11g Data Guard 使用duplicate from active database 建立 standby databaseOracleDatabase
- 【DataGuard】使用Grid Control調整Oracle物理Data Guard資料保護模式Oracle模式
- ORA-01555 on Active Data Guard Standby DatabaseDatabase
- 介紹ORACLE DATA GUARD——DATA GUARD概念和管理Oracle
- 11gR2 Active Data Guard 閃回 - flashback database / snapshot standby - 3Database
- Oracle Data Guard配置Oracle
- 【DataGuard】調整Data Guard資料保護模式詳細步驟模式
- oracle效能調整(2)Oracle
- ORACLE效能調整---2Oracle
- oracle效能調整2Oracle
- Oracle 11R2 snapshot Data GuardOracle
- 【DataGuard】使用Grid Control調整Oracle物理Data Guard備庫為Read OnlyOracle
- 搭建11g data guard(duplicate from active database方式)Database
- Oracle效能調整-2(轉)Oracle
- Oracle Data Guard Broker元件Oracle元件
- Oracle Data Guard簡介Oracle
- Oracle Data Guard 介紹Oracle
- ORACLE Data Guard--IOracle