ITPub博客

首页 > Linux操作系统 > Linux操作系统 > ora-16188 log_archive_config cause instance can not startup

ora-16188 log_archive_config cause instance can not startup

原创 Linux操作系统 作者:benn_wpj 时间:2009-06-13 00:10:17 0 删除 编辑

SQL> show parameter log_archive_config

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
log_archive_config string DG_CONFIG=(test,teststby)
SQL> alter system set log_archive_config = '';

系统已更改。

SQL> show parameter log_archive_config

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
log_archive_config string

由于这个参数的修改不需要重启,所以修改很轻松,即修改了当前实例,也修改了SPFILE,使得数据库所有的实例重启都使用新设置的值。似乎没有什么问题,然后这个操作已经埋下了问题。

如果当前的实例需要重启,则会碰到错误:

SQL> select instance_name from v$instance;

INSTANCE_NAME
----------------
test1

SQL> select instance_name from gv$instance;

INSTANCE_NAME
----------------
test1
test2

SQL> shutdown immediate数据库已经关闭。已经卸载数据库。
ORACLE
例程已经关闭。
SQL> startup
ORACLE
例程已经启动。

Total System Global Area 776896512 bytes
Fixed Size 2098776 bytes
Variable Size 220912040 bytes
Database Buffers 549453824 bytes
Redo Buffers 4431872 bytes
数据库装载完毕。
ORA-03113:
通信通道的文件结束进程 ID: 24455会话 ID: 58 序列号: 6

重启居然碰到了ORA-3113错误,检查alert文件可以发现,问题就是LOG_ARCHIVE_CONFIG参数在两个实例上配置不同造成的:

Fri Apr 24 16:31:47 2009
ALTER DATABASE MOUNT
NOTE:Loaded library: System
SUCCESS: diskgroup DATA was mounted
Errors in file /data/oracle/diag/rdbms/test/test1/trace/test1_ping_24656.trc:
Setting recovery target incarnation to 1
Successful mount of redo thread 1, with mount id 1983157714
Database mounted in Shared Mode (CLUSTER_DATABASE=TRUE)
Lost write protection disabled
Completed: ALTER DATABASE MOUNT
Fri Apr 24 16:31:54 2009
ALTER DATABASE OPEN
Picked broadcast on commit scheme to generate SCNs
WARNING: The 'LOG_ARCHIVE_CONFIG' init.ora parameter settings
are inconsistent with another started instance. This may be
caused by the 'DB_UNIQUE_NAME' init.ora parameter being specified
differently on one or more of the other RAC instances; the
DB_UNIQUE_NAME parameter value MUST be identical for all
instances of the database.
Errors in file /data/oracle/diag/rdbms/test/test1/trace/test1_lgwr_24686.trc:
ORA-16188: LOG_ARCHIVE_CONFIG settings inconsistent with previously started instance
Errors in file /data/oracle/diag/rdbms/test/test1/trace/test1_lgwr_24686.trc:
ORA-16188: LOG_ARCHIVE_CONFIG settings inconsistent with previously started instance
LGWR (ospid: 24686): terminating the instance due to error 16188
Fri Apr 24 16:31:54 2009
ORA-1092 : opitsk aborting process
Fri Apr 24 16:31:54 2009
System state dump is made for local instance
System State dumped to trace file /data/oracle/diag/rdbms/test/test1/trace/test1_diag_24652.trc
Trace dumping is performing id=[cdmp_20090424163154]
Fri Apr 24 16:31:56 2009
Instance terminated by LGWR, pid = 24686

即使修改另外实例上的LOG_ARCHIVE_CONFIG参数,也无法解决这个问题:

SQL> select instance_name from v$instance;

INSTANCE_NAME
----------------
test2

SQL> alter system set log_archive_config = '' scope = memory;

系统已更改。

重启实例1仍然是ORA-3113错误,只能重启整个数据库:

SQL> conn / as sysdba已连接到空闲例程。
SQL> startup
ORACLE
例程已经启动。

Total System Global Area 776896512 bytes
Fixed Size 2098776 bytes
Variable Size 220912040 bytes
Database Buffers 549453824 bytes
Redo Buffers 4431872 bytes
数据库装载完毕。
ORA-03113:
通信通道的文件结束进程 ID: 29431会话 ID: 145 序列号: 1

这时把该instance 起到mount 状态,查询视图SQL>select * from v$dataguard_config 你会发现它的结果与剩余其他节点上不一样,该instance查询结果已经包括teststby这个standby database,而其他节点的查询结果仍旧含有teststby这个standby database。正因为此RAC环境认为你要起的instance与其他instance在这个参数值上不一致,所以启动失败。


SQL> exit Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options
断开

bash-3.00$ srvctl stop db -d test
PRKP-1002 : Error stopping instance test1 on node ser1
CRS-0233: ??????????????????????????????????????
bash-3.00$ srvctl start db -d test
bash-3.00$ sqlplus "/ as sysdba"

SQL*Plus: Release 11.1.0.6.0 - Production on 星期五 4 24 16:43:56 2009

Copyright (c) 1982, 2007, Oracle. All rights reserved.

连接到:
Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - 64bit Production
With the Partitioning, Real Application Clusters, OLAP, Data Mining
and Real Application Testing options

SQL> show parameter log_archive_config

NAME TYPE VALUE
------------------------------------ ----------- ------------------------------
log_archive_config string
SQL> select instance_name from gv$instance;

INSTANCE_NAME
----------------
test1
test2

需要注意LOG_ARCHIVE_CONFIG参数只是在清除参数设置的时候才会有问题,如果是设置不同的值并不会导致上面的错误。

载自http://yangtingkun.itpub.net/post/468/483433

http://download.oracle.com/docs/cd/B19306_01/server.102/b14237/initparams098.htm#REFRN10237

该链接提示 正确的步骤是 LOG_ARCHIVE_CONFIG=NODG_CONFIG 清除原来该参数设置的DATA GUARD所列出的SERVICE_NAME,这时再重启其中的实例OK,接着可以选择的之前的空值设置。

所以该问题的前提是:用 LOG_ARCHIVE_CONFIG=NODG_CONFIG 清除之前配置的SERVICE_NAME,接着查询v$dataguard_config发现data guard配置中只有原primary db_name.


来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/13790829/viewspace-606166/,如需转载,请注明出处,否则将追究法律责任。

请登录后发表评论 登录
全部评论

注册时间:2008-04-26

  • 博文量
    57
  • 访问量
    128158