Background Media Recovery terminated with ORA-1274 after adding a Datafile (Doc ID 739618.1)
APPLIES TO:
Oracle Database - Enterprise Edition - Version 9.2.0.1 to 12.1.0.2 [Release 9.2 to 12.1]
Information in this document applies to any platform.
***Checked for relevance on 26-Sep-2012***
***Checked for relevance on 8-Jul-2015***
SYMPTOMS
Adding a Tablespace / Datafile in Primary Database causes the MRP in Physical Standby Database to terminate with the Error below. STANDBY_FILE_MANAGEMENT = MANUAL is set on the Standby Database.
ORA-01274: cannot add datafile '...dbf' - file could not be created
In Unix Environment you will get the below Message when try to restart the MRP
BEST Practice,
Keep the STANDBY_FILE_MANAGEMENT in AUTO.
CAUSE
This Error occurs if we add a Datafile OR Tablespace in PRIMARY Database and that could not be translated to the Standby Database due to these Reasons:
- Standby_file_management is set to MANUAL
- Primary & Physical Standby are having different file structures and DB_FILE_NAME_CONVERT is not set according to the Directory Structures in Primary and Standby
- Insufficient Space or wrong Permissions on the Standby Database to create the Datafile
- If standby_file_management is set to Auto ,but directory path of Primary and standby are different , db_file_name_convert is not set ,but db_create_file_dest has been set to wrong value on standby.
The Redo Log generated from Primary will have Information about the Tablespace / Datafile added however it could not be created successfully in Physical Standby Database due to the standby_file_management = MANUAL
or is not able to find the specified Folder due to a missing / incorrect Filename Conversion.
The File Entry is added to Standby Controlfile as "UNNAMED0000n" in /dbs or /database
folder depends on the Operating System and eventually the MRP terminates.
=================================================================
File #5 added to control file as 'UNNAMED00005' 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
Thu Sep 25 19:02:35 2008
Errors in file c:\oracle\product\10.2.0\admin\mystd\bdump\mystd_mrp0_3436.trc:
ORA-01274: cannot add datafile 'D:\ORADATA\PRIM\SALES01.DBF' - file could not be created
By default it is AUTO by broker.
SOLUTION
Perform all mentioned Steps on the Standby Database:
For version < 12c
Step 1: Ensure the standby_file_management = 'MANUAL.
NOTE : For the parameter db_file_name_convert change if the Data Guard Broker is enabled then edit the Parameters using the Broker
DGMGRL>edit database '<standby>' set property StandbyFileManagement=manual;
By default StandbyFileManagement is AUTO by broker.
Step 2: Identify the File which is "unnamedn"
NAME
--------------------------------------------------------------------------------
D:\ORADATA\MYSTD\SYSTEM.DBF
D:\ORADATA\MYSTD\UNDO.DBF
D:\ORADATA\MYSTD\SYSAUX.DBF
D:\ORADATA\MYSTD\SERVICE01.DBF
C:\ORACLE\PRODUCT\10.2.0\DB_1\DATABASE\UNNAMED00005
Step 3: Rename/create the Datafile to the correct Filename
If the standby is in ASM + OMF then use the below command,
or
Step 4: Verify the Filename is correct
NAME
--------------------------------------------------------------------------------
D:\ORADATA\MYSTD\SYSTEM.DBF
D:\ORADATA\MYSTD\UNDO.DBF
D:\ORADATA\MYSTD\SYSAUX.DBF
D:\ORADATA\MYSTD\SERVICE01.DBF
D:\ORADATA\MYSTD\SALES01.DBF
Step 5: Change the STANDBY_FILE_MANAGMENT to AUTO
Step 6: Start the MRP (this is using Real Time Apply)
Database altered.
Step 7: Verify the MRP is running as expected
--------- ------------ ----------
ARCH CLOSING 99
ARCH CLOSING 103
MRP0 APPLYING_LOG 104
RFS IDLE 0
RFS IDLE 0
RFS IDLE 104
For 12c Database with PDBs :-
Step 1: Ensure the standby_file_management = 'MANUAL'
DGMGRL>edit database '<standby>' set property DbFileNameConvert='<>','<>';
DGMGRL>edit database '<standby>' set property StandbyFileManagement=manual;
Step 2:- Identify the Pdb with datafile name UNNAMED
column name format a50
column pdb_name format a8
select a.file#,a.name,a.con_id,b.pdb_id,b.pdb_name from v$datafile a,dba_pdbs b where a.con_id=b.con_id and a.name like '%UNNAM%';
Step 3:- Set the container to that pdb
In Below example assuming pdb1 is the container
SQL> alter session set container = pdb1;
Session altered.
FILE# NAME CON_ID PDB_ID PDB_NAME
--------- -------------------------------------------------- ---------- ---------- --------
5 D:\ORADATA\MYSTD\UNNAMED00005 3 3 PDB1
SQL> alter pluggable database pdb1 CREATE DATAFILE 'D:\ORADATA\MYSTD\UNNAMED00005' as 'D:\ORADATA\MYSTD\SP385343393_ess.dbf';
Pluggable database altered.
Step 4-7 are same as listed for version < 12c
Background Media Recovery terminated with ORA-1274 after adding a Datafile (Doc ID 739618.1)的更多相关文章
- 诊断:MRP0: Background Media Recovery terminated with error 1111
表现: 灾备环境,无法继续应用日志. 日志: MRP0: Background Media Recovery terminated with error 1111 Fri Jan 18 15:55:2 ...
- 诊断:MRP0: Background Media Recovery process shutdown with error ORA-19909
oracle12c data guard,从库无法应用日志,检查alert日至发现 2019-10-21T14:55:40.087819+08:00 MRP0: Background Media Re ...
- Performing User-Managed Database-18.7、Performing Complete User-Managed Media Recovery
18.7.Performing Complete User-Managed Media Recovery 完毕一致性备份,把数据库恢复到当前的scn是最好的结果.能够恢复整个数据库.恢复单个表空间.或 ...
- ORA-01113: file xxxx needs media recovery
由于规范存储位置以及存储空间调整缘故需要移动表空间MRP_INDEX2的数据文件,如下所示,首先将表空间MRP_INDEX2脱机; 然后复制数据文件:接着重命名数据文件,最后将表空间MRP_INDEX ...
- ORA-10456:cannot open standby database;media recovery session may be in process
http://neeraj-dba.blogspot.com/2011/10/ora-10456-cannot-open-standby-database.html Once while star ...
- 关闭归档提示:ORA-38774: cannot disable media recovery - flashback database is enabled
SQL> select * from v$version; Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit P ...
- Basic Concepts of Block Media Recovery
Basic Concepts of Block Media Recovery Whenever block corruption has been automatically detected, yo ...
- 物理DG主备库切换时遇到ORA-16139: media recovery required错误
在物理DG主备库切换时遇到ORA-16139: media recovery required错误 SQL> ALTER DATABASE COMMIT TO SWITCHOVER TO PRI ...
- 11G新特性 -- 块介质恢复性能增强(block media recovery)
块介质恢复性能增强(block media recovery) :只是恢复受损的块.不需要将受损的数据文件offline.针对受损的数据块,使用备份中好的数据块进行restore和recover,避免 ...
随机推荐
- canvas放射粒子效果
这个也是别人的代码,就不多介绍了 写了些注释 body { overflow:hidden; margin:0; padding:0; background-color:#222222 } </ ...
- LR报错Error -27780: [GENERAL_MSG_CAT_SSL_ERROR]connect to host "XXX.XXX.com" failed解决方法
- BZOJ5071 小A的数字 BZOJ2017年10月月赛 其他
欢迎访问~原文出处——博客园-zhouzhendong 去博客园看该题解 题目传送门 - BZOJ5071 题意概括 题解 一开始蒙了. 感觉做过类似的题目. 但是找不到方法. 突然想到前缀和! 对于 ...
- BZOJ1264 [AHOI2006]基因匹配Match 动态规划 树状数组
欢迎访问~原文出处——博客园-zhouzhendong 去博客园看该题解 题目传送门 - BZOJ1264 题意概括 给出两个长度为5*n的序列,每个序列中,有1~n各5个. 求其最长公共子序列长度. ...
- POJ 3304 Segments (叉乘判断线段相交)
<题目链接> 题目大意: 给出一些线段,判断是存在直线,使得该直线能够经过所有的线段.. 解题思路: 如果有存在这样的直线,过投影相交区域作直线的垂线,该垂线必定与每条线段相交,问题转化为 ...
- 010.Docker Compose构建WordPress实战
一 前期规划 类型 版本 备注 WordPress镜像 wordpress:latest MySQL数据库 5.7 Docker已安装,参考<002.Docker版本及安装>. D ...
- 条件随机场之CRF++源码详解-特征
我在学习条件随机场的时候经常有这样的疑问,crf预测当前节点label如何利用其他节点的信息.crf的训练样本与其他的分类器有什么不同.crf的公式中特征函数是什么以及这些特征函数是如何表示的.在这一 ...
- 解决binwalk运行提示缺少LZMA模块
解决binwalk运行提示缺少LZMA模块 部分用户在使用binwalk提取固件内容,可能会遇到缺少LZMA模块的提示.提示内容为WARNING:The Python LZMA module co ...
- supervisor管理进程工具配置
Supervisor(http://supervisord.org/)是用Python开发的一个client/server服务,是Linux/Unix系统下的一个进程管理工具,不支持Windows系统 ...
- BZOJ.2756.[SCOI2012]奇怪的游戏(二分 黑白染色 最大流ISAP)
题目链接 \(Description\) \(Solution\) 这种题当然要黑白染色.. 两种颜色的格子数可能相同,也可能差1.记\(n1/n2\)为黑/白格子数,\(s1/s2\)为黑/白格子权 ...