Chinaunix首页 | 论坛 | 博客
  • 博客访问: 506343
  • 博文数量: 105
  • 博客积分: 3040
  • 博客等级: 中校
  • 技术积分: 1450
  • 用 户 组: 普通用户
  • 注册时间: 2005-07-08 13:04
文章分类

全部博文(105)

文章存档

2008年(105)

我的朋友

分类: Oracle

2008-08-25 10:59:47

问题陈述
dataguard为physical、maximum availability、real_time apply模式
主机在线日志和standby日志为:
3 ONLINE /u02/oracle/oradata/oract/redo03.log NO
2 ONLINE /u02/oracle/oradata/oract/redo02.log NO
1 ONLINE /u02/oracle/oradata/oract/redo01.log NO
4 STANDBY /u02/oracle/oradata/oract/standby01A.log NO
5 STANDBY /u02/oracle/oradata/oract/standby02A.log NO
6 STANDBY /u02/oracle/oradata/oract/standby03A.log NO
7 STANDBY /u02/oracle/oradata/oract/standby04A.log NO
4 STANDBY /u02/oracle/oradata/oract/standby01B.log NO
5 STANDBY /u02/oracle/oradata/oract/standby02B.log NO
6 STANDBY /u02/oracle/oradata/oract/standby03B.log NO
7 STANDBY /u02/oracle/oradata/oract/standby04B.log

standby机在线日志和standby 日志为:
3 ONLINE /u02/oracle/oradata/oract/redo03.log NO
2 ONLINE /u02/oracle/oradata/oract/redo02.log NO
1 ONLINE /u02/oracle/oradata/oract/redo01.log NO
4 STANDBY /u02/oracle/oradata/oract/standby01A.log NO
5 STANDBY /u02/oracle/oradata/oract/standby02A.log NO
6 STANDBY /u02/oracle/oradata/oract/standby03A.log NO
7 STANDBY /u02/oracle/oradata/oract/standby04A.log NO
4 STANDBY /u02/oracle/oradata/oract/standby01B.log NO
5 STANDBY /u02/oracle/oradata/oract/standby02B.log NO
6 INVALID STANDBY /u02/oracle/oradata/oract/standby03B.log NO
7 INVALID STANDBY /u02/oracle/oradata/oract/standby04B.log

LOG_FILE_NAME_CONVERT 没有设置
在standby机器启动后总是报如下错误:
ORA-19527: physical standby redo log must be renamed
ORA-00312: online log 1 thread 1: '/u02/oracle/oradata/oract/redo01.log'

解决办法
$ oerr ora 19527
19527, 00000, "physical standby redo log must be renamed"
// *Cause: The CLEAR LOGFILE command was used at a physical standby
// database. This command cannot be used at a physical standby
// database unless the LOG_FILE_NAME_CONVERT initialization
// parameter is set. This is required to avoid overwriting
// the primary database's logfiles.
// *Action Set the LOG_FILE_NAME_CONVERT initialization parameter.


没什么特别的操作,现在dataguard运行正常,只是每次standby启动alter database recover managed standby database using current logfile disconnect from session 或者 alter database recover managed standby database disconnect from session 的时候都会在警报日志里面有上述警报

另:
我的standby机器 v$standby_log 现实好像只有一组standby日志被应用过

SQL> select * from v$standby_log;

GROUP# DBID THREAD# SEQUENCE# BYTES USED ARCHIVED STATUS FIRST_CHANGE# FIRST_TIME LAST_CHANGE# LAST_TIME
---------- ---------------------------------------- ---------- ---------- ---------- ---------- -------- ---------- ------------- ----------- ------------ -----------
4 UNASSIGNED 1 0 52428800 512 NO UNASSIGNED 0 0
5 1257885094 1 50 52428800 183808 YES ACTIVE 552319 2006-12-28 552619 2006-12-28
6 UNASSIGNED 0 0 52428800 512 YES UNASSIGNED 0 0
7 UNASSIGNED 0 0 52428800 512 YES UNASSIGNED 0 0


Physical Standby Database mounted.
Completed: ALTER DATABASE MOUNT
ARC9 started with pid=25, OS id=8925
Thu Dec 28 14:23:57 2006
alter database recover managed standby database using current logfile disconnect from session
Thu Dec 28 14:23:58 2006
Attempt to start background Managed Standby Recovery process (oract)
MRP0 started with pid=26, OS id=8928
Thu Dec 28 14:23:59 2006
MRP0: Background Managed Standby Recovery process started (oract)
Managed Standby Recovery starting Real Time Apply
Clearing online redo logfile 1 /u02/oracle/oradata/oract/redo01.log
Clearing online log 1 of thread 1 sequence number 50
Thu Dec 28 14:24:04 2006
Completed: alter database recover managed standby database using current logfile disconnect from session
Thu Dec 28 14:24:08 2006
Clearing online redo logfile 1 complete
Clearing online redo logfile 2 /u02/oracle/oradata/oract/redo02.log
Clearing online log 2 of thread 1 sequence number 49
Clearing online redo logfile 2 complete
Clearing online redo logfile 3 /u02/oracle/oradata/oract/redo03.log
Clearing online log 3 of thread 1 sequence number 50
Clearing online redo logfile 3 complete
Thu Dec 28 14:24:16 2006
Recovery of Online Redo Log: Thread 1 Group 5 Seq 50 Reading mem 0
Mem# 0 errs 0: /u02/oracle/oradata/oract/standby02A.log
Mem# 1 errs 0: /u02/oracle/oradata/oract/standby02B.log

做法是设置 LOG_FILE_NAME_CONVERT='/u02/oracle/oradata/oract/','/u02/oracle/oradata/oract/'
因为主备机分离而且目录结构完全一致所以设置LOG_FILE_NAME_CONVERT就不会再提示警告了
现在想想感觉警告主要是提示在主备同机情况下避免清除主机在线日志的


一开始我就是用的copy方式建立的standby,所以所有的转换参数都没有设置。

出现这个问题可以考虑在Standby 端临时设置一下 LOG_FILE_NAME_CONVERT ,清掉日志后,不报错误后可以把这个参数设置回去

阅读(8813) | 评论(0) | 转发(0) |
0

上一篇:转网站构架

下一篇:再谈系统性能分析

给主人留下些什么吧!~~