Broker切换过程中原主库不能自启动
2015-12-25 11:40
218 查看
Oracle 11G 在配置好Data Guard使用Broker进行切换的过程中,出现报错,虽然不影响正常使用,但还是探其究竟,找到问题所在。
在Broker中进行一次切换后
DGMGRL> switchover to primary;
Performing switchover NOW, please wait...
New primary database "primary" is opening...
Operation requires shutdown of instance "king" on database "paris"
Shutting down instance "king"...
ORACLE instance shut down.
Operation requires startup of instance "king" on database "paris"
Starting instance "king"...
Unable to connect to database
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
Failed.
Warning: You are no longer connected to ORACLE.
Please complete the following steps to finish switchover:
start up instance "king" of database "paris"
切换完成之后,原主库需要手动startup,这种情况应该是可以自动启动的,并且自动应用日志,因为当前Broker Configuraion已经配好并且已经enable;
查询相关文档发现是因为GLOBAL_DBNAME=db_unique_name_DGMGRL.db_domain的格式,官方文档也有说明:
如果要启用DGMGRL在切换过程中可以重启实例,必须静态注册到本地监听文件中,格式如下:
To enable DGMGRL to restart instances during the course of broker operations, a service with a specific name must be statically registered with the local listener of each instance. The value for the GLOBAL_DBNAME attribute must be set to a concatenation
of db_unique_name_DGMGRL. db_domain. For example, in the
LISTENER.ORA file:
LISTENER = (DESCRIPTION =
(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=host_name)
(PORT=port_num))))
SID_LIST_LISTENER=(SID_LIST=(SID_DESC=(SID_NAME=sid_name)
(GLOBAL_DBNAME=db_unique_name_DGMGRL. db_domain)
(ORACLE_HOME=oracle_home)))
重新静态注册过后,再次切换OK
DGMGRL> switchover to standby
Performing switchover NOW, please wait...
New primary database "standby" is opening...
Operation requires shutdown of instance "king" on database "primary"
Shutting down instance "king"...
ORACLE instance shut down.
Operation requires startup of instance "king" on database "primary"
Starting instance "king"...
ORACLE instance started.
Database mounted.
Database opened.
Switchover succeeded, new primary is "standby"
*****如果文件修改之后发现仍不能启动,检查/etc/hosts文件,observer,primary,standby的ip是否都被写进文件中*****
在Broker中进行一次切换后
DGMGRL> switchover to primary;
Performing switchover NOW, please wait...
New primary database "primary" is opening...
Operation requires shutdown of instance "king" on database "paris"
Shutting down instance "king"...
ORACLE instance shut down.
Operation requires startup of instance "king" on database "paris"
Starting instance "king"...
Unable to connect to database
ORA-12514: TNS:listener does not currently know of service requested in connect descriptor
Failed.
Warning: You are no longer connected to ORACLE.
Please complete the following steps to finish switchover:
start up instance "king" of database "paris"
切换完成之后,原主库需要手动startup,这种情况应该是可以自动启动的,并且自动应用日志,因为当前Broker Configuraion已经配好并且已经enable;
查询相关文档发现是因为GLOBAL_DBNAME=db_unique_name_DGMGRL.db_domain的格式,官方文档也有说明:
如果要启用DGMGRL在切换过程中可以重启实例,必须静态注册到本地监听文件中,格式如下:
To enable DGMGRL to restart instances during the course of broker operations, a service with a specific name must be statically registered with the local listener of each instance. The value for the GLOBAL_DBNAME attribute must be set to a concatenation
of db_unique_name_DGMGRL. db_domain. For example, in the
LISTENER.ORA file:
LISTENER = (DESCRIPTION =
(ADDRESS_LIST=(ADDRESS=(PROTOCOL=tcp)(HOST=host_name)
(PORT=port_num))))
SID_LIST_LISTENER=(SID_LIST=(SID_DESC=(SID_NAME=sid_name)
(GLOBAL_DBNAME=db_unique_name_DGMGRL. db_domain)
(ORACLE_HOME=oracle_home)))
重新静态注册过后,再次切换OK
DGMGRL> switchover to standby
Performing switchover NOW, please wait...
New primary database "standby" is opening...
Operation requires shutdown of instance "king" on database "primary"
Shutting down instance "king"...
ORACLE instance shut down.
Operation requires startup of instance "king" on database "primary"
Starting instance "king"...
ORACLE instance started.
Database mounted.
Database opened.
Switchover succeeded, new primary is "standby"
*****如果文件修改之后发现仍不能启动,检查/etc/hosts文件,observer,primary,standby的ip是否都被写进文件中*****
相关文章推荐
- 基于facebook thrift的压力测试的实现,登录举例
- MFC对话框美化
- (转)在Windows上以服务方式运行 MSOPenTech/Redis
- 模块和控制器包含在JS文件中
- 8、代理模式(Proxy)
- 手机自动化测试:Appium源码分析之跟踪代码分析五
- array地址问题(为何指向赋值,仍然地址不同)
- 修改Bundle identify引起的问题
- ASM创建spfile失败 $ORACLE_HOME/bin/oracle
- servlet中文乱码拦截器
- oracle 常用函数
- bootstrap-glyphicons图标
- 一知半见的load与get
- 为activity设置主题theme
- Joomla反序列化漏洞的查漏补缺
- Android项目重构之路:架构篇
- LeetCode---Sudoku Solver
- #!bin/bash
- MySQL 触发器简单实例
- 调用第三方应用导航