我是靠谱客的博主 醉熏小猫咪,最近开发中收集的这篇文章主要介绍空间不足导致dataguard同步apply停止,觉得挺不错的,现在分享给大家,希望可以做个参考。

概述

      今天接到通知说,主库的数据没有同步到备库

查看日志,发现异常如下:

Errors in file/u01/app/oracle/diag/rdbms/shdb/shdb/trace/shdb_dbw0_21769.trc:

ORA-01186: file 77 failed verification tests

ORA-01157: cannot identify/lock data file 77 -see DBWR trace file

ORA-01111: name for data file 77 is unknown -rename to correct file

ORA-01110: data file 77: '/u01/app/oracle/product/11.2.0.4/dbhome_1/dbs/UNNAMED00077'

File 77 not verified due to error ORA-01157

Mon Dec 21 11:11:02 2015

MRP0: Background Media Recovery terminatedwith error 1111

Errors in file/u01/app/oracle/diag/rdbms/shdb/shdb/trace/shdb_pr00_13928.trc:

ORA-01111: name for data file 77 is unknown -rename to correct file

ORA-01110: data file 77:'/u01/app/oracle/product/11.2.0.4/dbhome_1/dbs/UNNAMED00077'

ORA-01157: cannot identify/lock data file 77 -see DBWR trace file

ORA-01111: name for data file 77 is unknown -rename to correct file

ORA-01110: data file 77: '/u01/app/oracle/product/11.2.0.4/dbhome_1/dbs/UNNAMED00077'

Managed Standby Recovery not using Real TimeApply

 

找度娘问问,得到以下步骤:

alter system setstandby_file_management=manual;

SQL>alter database create datafile '/u01/app/oracle/product/11.2.0.4/dbhome_1/dbs/UNNAMED00077' as'/u01/app/oradata/shdb/data_xxsh11.dbf';

alter system set standby_file_management=auto;

recover managed standby database disconnectfrom session;

 

然后,重启系统,并Mount,同时按照以上步骤操作。因为这次共建了5个文件,系统重新处理

相关日志如下:

 

 

Media Recovery Log /u01/app/archlog/shdb/shdb_1_114246_820585054.arc

Mon Dec 21 14:17:41 2015

RFS[28]: Selected log 15 for thread 1sequence 114582 dbid 1635205303 branch 820585054

Mon Dec 21 14:17:46 2015

Archived Log entry 201091 added for thread1 sequence 114578 ID 0x66a4d95f dest 1:

Mon Dec 21 14:19:41 2015

Archived Log entry 201092 added for thread1 sequence 114580 ID 0x66a4d95f dest 1:

Mon Dec 21 14:19:45 2015

Archived Log entry 201093 added for thread1 sequence 114579 ID 0x66a4d95f dest 1:

Mon Dec 21 14:20:24 2015

Archived Log entry 201094 added for thread1 sequence 114581 ID 0x66a4d95f dest 1:

Mon Dec 21 14:24:05 2015

RFS[28]: Selected log 11 for thread 1sequence 114583 dbid 1635205303 branch 820585054

Mon Dec 21 14:24:59 2015

Archived Log entry 201095 added for thread1 sequence 114582 ID 0x66a4d95f dest 1:

Mon Dec 21 14:29:54 2015

RFS[28]: Selected log 12 for thread 1sequence 114584 dbid 1635205303 branch 820585054

Mon Dec 21 14:30:32 2015

Archived Log entry 201096 added for thread1 sequence 114583 ID 0x66a4d95f dest 1:

Mon Dec 21 14:39:13 2015

RFS[28]: Selected log 11 for thread 1sequence 114585 dbid 1635205303 branch 820585054

Mon Dec 21 14:39:14 2015

Archived Log entry 201097 added for thread1 sequence 114584 ID 0x66a4d95f dest 1:

Mon Dec 21 14:39:35 2015

WARNING: File beingcreated with same name as in Primary

Existing file may beoverwritten

 

总结

从这次观察来看,系统做同步时,会先建临时文件,名称如下:

/u01/app/oracle/product/11.2.0.4/dbhome_1/dbs/UNNAMED00080

如果空间足够,就会成功同步,并将文件更名为正确的名称和路径。

select * from V$ARCHIVE_GAP;

 

查看dbfile的信息

SELECT*  FROM V$DBFILE ORDER BY FILE#

查看archivelog同步和应用的进度代码:

selectSEQUENCE#  ,APPLIED,completion_time fromv$archived_log

where

APPLIED  !='YES' order by 1;

 

--停止apply archivelog

alter database recover managed standby database cancel;

开启apply archivelog

alterdatabase recover managed standby database using current logfile disconnect fromsession;


以后新建数据文件的时候,要注意看看备库的空间是否充足。

最后

以上就是醉熏小猫咪为你收集整理的空间不足导致dataguard同步apply停止的全部内容,希望文章能够帮你解决空间不足导致dataguard同步apply停止所遇到的程序开发问题。

如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。

本图文内容来源于网友提供,作为学习参考使用,或来自网络收集整理,版权属于原作者所有。
点赞(46)

评论列表共有 0 条评论

立即
投稿
返回
顶部