dataguard主库添加的数据文件路径在从库不存在

WARNING: File being created with same name as in Primary
Existing file may be overwritten
Errors in file /u01/app/oracle/diag/rdbms/slnngkdg/slnngkdg/trace/slnngkdg_pr00_2875.trc:
ORA-01119: error in creating database file '/u02/oradata/tps_data10.dbf'
ORA-27054: NFS file system where the file is created or resides is not mounted with correct options
Linux-x86_64 Error: 13: Permission denied
File #15 added to control file as 'UNNAMED00015'.
Originally created as:
'/u02/oradata/tps_data10.dbf'
Recovery was unable to create the file as:
'/u02/oradata/tps_data10.dbf'
MRP0: Background Media Recovery terminated with error 1274
Errors in file /u01/app/oracle/diag/rdbms/slnngkdg/slnngkdg/trace/slnngkdg_pr00_2875.trc:
ORA-01274: cannot add datafile '/u02/oradata/tps_data10.dbf' - file could not be created

 

这里提示无法创建/u02/oradata/tps_data10.dbf文件,检查发现在从库根本没用/u02目录,尝试创建

处理办法,创建相应的目录:

su - root

mkdir -p /u02/oradata

chown -R oracle:oinstall /u02


Wed Dec 04 16:50:15 2019
Errors in file /u01/app/oracle/diag/rdbms/slnngkdg/slnngkdg/trace/slnngkdg_dbw0_24235.trc:
ORA-01186: file 15 failed verification tests
ORA-01157: cannot identify/lock data file 15 - see DBWR trace file
ORA-01111: name for data file 15 is unknown - rename to correct file
ORA-01110: data file 15: '/u01/app/oracle/product/11.2.0.4/db_1/dbs/UNNAMED00015'
File 15 not verified due to error ORA-01157
MRP0: Background Media Recovery terminated with error 1111
Errors in file /u01/app/oracle/diag/rdbms/slnngkdg/slnngkdg/trace/slnngkdg_pr00_4577.trc:
ORA-01111: name for data file 15 is unknown - rename to correct file
ORA-01110: data file 15: '/u01/app/oracle/product/11.2.0.4/db_1/dbs/UNNAMED00015'
ORA-01157: cannot identify/lock data file 15 - see DBWR trace file
ORA-01111: name for data file 15 is unknown - rename to correct file
ORA-01110: data file 15: '/u01/app/oracle/product/11.2.0.4/db_1/dbs/UNNAMED00015'
Managed Standby Recovery not using Real Time Apply
Recovery Slave PR00 previously exited with exception 1111
MRP0: Background Media Recovery process shutdown (slnngkdg)

这里提示unnamed00015未知,因为dataguard在同步的时候要是从库的路径不存在,会尝试在../dbs/目录下创建unnamedXXXX这样的文件

处理办法:
shutdown immediate
startup mount
SQL> select status from v$instance;

STATUS
------------
MOUNTED

alter system set standby_file_management=manual;
alter database create datafile '/u01/app/oracle/product/11.2.0.4/db_1/dbs/UNNAMED00015' as '/u02/oradata/tps_data10.dbf';

不清楚数据文件的话,可以在主库通过如下查询找到文件路径:

Select Name,file#,creation_time From v$datafile Order By creation_time Desc;


alter system set standby_file_management=auto;
alter database recover managed standby database using current logfile disconnect from session;
select process,status from v$managed_standby;

posted @ 2019-12-04 17:13  slnngk  阅读(528)  评论(0编辑  收藏  举报