本帖最后由 ylw6006 于 2012-4-27 11:30 编辑
测试了下oracle adg 物理备库,主库和备库的日志传输和实时应用都正常,只是备库的alert日志不断的出现如下的错误!
Fri Apr 27 11:07:32 2012
Errors in file /u01/app/oracle/diag/rdbms/primary/xxx/trace/xxx_arc2_10592.trc:
ORA-00314: log 4 of thread 1, expected sequence# 143 doesn't match 141
ORA-00312: online log 4 thread 1: '/u01/app/oracle/fast_recovery_area/PRIMARY/onlinelog/o1_mf_4_7rtvgbwx_.log'
[oracle@server199 ~]$ cat /u01/app/oracle/diag/rdbms/primary/xxx/trace/xxx_arc2_10592.trc
Trace file /u01/app/oracle/diag/rdbms/primary/xxx/trace/xxx_arc2_10592.trc
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
ORACLE_HOME = /u01/app/oracle/product/11.2.0/db1
System name: Linux
Node name: server199
Release: 2.6.18-164.el5
Version: #1 SMP Thu Sep 3 03:28:30 EDT 2009
Machine: x86_64
Instance name: xxx
Redo thread mounted by this instance: 1
Oracle process number: 23
Unix process pid: 10592, image: [url=mailto
racle@server199]oracle@server199[/url] (ARC2)
*** 2012-04-27 10:51:32.000
*** SESSION ID
1712.1) 2012-04-27 10:51:32.000
*** CLIENT ID
) 2012-04-27 10:51:32.000
*** SERVICE NAME
) 2012-04-27 10:51:32.000
*** MODULE NAME
) 2012-04-27 10:51:32.000
*** ACTION NAME
) 2012-04-27 10:51:32.000
Redo shipping client performing standby login
OCISessionBegin failed. Error -1
.. Detailed OCI error val is 1031 and errmsg is 'ORA-01031: insufficient privileges
'
OCISessionBegin failed. Error -1
.. Detailed OCI error val is 1031 and errmsg is 'ORA-01031: insufficient privileges
'
*** 2012-04-27 10:51:32.637 4645 krsu.c
Logged on to standby successfully
Client logon and security negotiation successful!
*** 2012-04-27 10:51:34.049
DDE rules only execution for: ORA 312
----- START Event Driven Actions Dump ----
---- END Event Driven Actions Dump ----
----- START DDE Actions Dump -----
Executing SYNC actions
----- START DDE Action: 'DB_STRUCTURE_INTEGRITY_CHECK' (Async) -----
Successfully dispatched
----- END DDE Action: 'DB_STRUCTURE_INTEGRITY_CHECK' (SUCCESS, 0 csec) -----
Executing ASYNC actions
----- END DDE Actions Dump (total 0 csec) -----
ORA-00314: log 4 of thread 1, expected sequence# 143 doesn't match 141
ORA-00312: online log 4 thread 1: '/u01/app/oracle/fast_recovery_area/PRIMARY/onlinelog/o1_mf_4_7rtvgbwx_.log'
DDE rules only execution for: ORA 312
*** 2012-04-27 11:07:32.095
----- START Event Driven Actions Dump ----
---- END Event Driven Actions Dump ----
----- START DDE Actions Dump -----
Executing SYNC actions
----- START DDE Action: 'DB_STRUCTURE_INTEGRITY_CHECK' (Async) -----
Successfully dispatched
----- END DDE Action: 'DB_STRUCTURE_INTEGRITY_CHECK' (SUCCESS, 0 csec) -----
Executing ASYNC actions
----- END DDE Actions Dump (total 0 csec) -----
ORA-00314: log 4 of thread 1, expected sequence# 143 doesn't match 141
ORA-00312: online log 4 thread 1: '/u01/app/oracle/fast_recovery_area/PRIMARY/onlinelog/o1_mf_4_7rtvgbwx_.log'
DDE rules only execution for: ORA 312
*** 2012-04-27 11:22:32.441
----- START Event Driven Actions Dump ----
---- END Event Driven Actions Dump ----
----- START DDE Actions Dump -----
Executing SYNC actions
----- START DDE Action: 'DB_STRUCTURE_INTEGRITY_CHECK' (Async) -----
Successfully dispatched
----- END DDE Action: 'DB_STRUCTURE_INTEGRITY_CHECK' (SUCCESS, 0 csec) -----
Executing ASYNC actions
----- END DDE Actions Dump (total 0 csec) -----
ORA-00314: log 4 of thread 1, expected sequence# 143 doesn't match 141
ORA-00312: online log 4 thread 1: '/u01/app/oracle/fast_recovery_area/PRIMARY/onlinelog/o1_mf_4_7rtvgbwx_.log'
主库:
SQL> archive log list;
Database log mode Archive Mode
Automatic archival Enabled
Archive destination /u01/app/oracle/archivelog/standbylog
Oldest online log sequence 240
Next log sequence to archive 242
Current log sequence 242
备库:
SQL> archive log list;
Database log mode Archive Mode
Automatic archival Enabled
Archive destination /u01/app/oracle/archivelog/standbylog
Oldest online log sequence 241
Next log sequence to archive 0
Current log sequence 242
SQL> select applied,sequence# from v$archived_log where sequence# > 240;
APPLIED SEQUENCE#
--------- ----------
IN-MEMORY 241
SQL> select status,group# from v$standby_log;
STATUS GROUP#
---------- ----------
ACTIVE 4
ACTIVE 5
UNASSIGNED 6
UNASSIGNED 7
这里的standby日志组4,就是alert日志中的onlinelog/o1_mf_4_7rtvgbwx_.log,对应的日志也应经成功应用到备库,且在备库上这些日志已删除
SQL> select applied,sequence# from v$archived_log where sequence# >=140 and sequence# <=145;
APPLIED SEQUENCE#
--------- ----------
YES 140
YES 141
YES 142
YES 143
YES 144
YES 145
6 rows selected.
虽然目前不影响ADG的主备同步,但不知道是否会影响到将来的switchover,要如何解决这个问题,烦请大神们指点一二!