oracle 12c ora 01033,ORA-01033: ORACLE initialization or shutdown in progress(12c中)

在oracle12c中,需要更改默认的pdb服务名,否则将会出现rac集群中,当有一个pdb出现问题时不可用(特别是当一个pdb服务没有起来时),整个rac集群不可用的状况。

如下是具体的处理办法。

Connecting To A 12c RAC Pluggable Database

Intermittently Fails With ORA-1033 (Doc ID 1998112.1)

ORA-01033: ORACLE initialization or shutdown in progress

1.1.1CAUSE

The issue is caused by 2 factors:

1. The service name used to connect to the PDB is the name of the PDB itself

2. The PDB is not open on all RAC instances

Using the name of a  PDB as a service name is not a good practice in a RAC

environment as the Instance will register thePDB name with the SCAN and node

listeners as soon as the PDB is mounted. This can cause connects to be directed

to database instances that have the PDB mounted (not open) and can result in an

ORA-1033 error when connecting a as non-SYSDBA user.

1.1.2SOLUTION

1. Create a CRS service with a name other than the PDB name -

e.g.:

$ORACLE_HOME/bin/srvctl add service -databaseracdb-pdbpdb_name-spdb_srv-i

"racinst1,racinst2"

2. Start the service through srvctl:

$ORACLE_HOME/bin/srvctl start service -databaseracdb-pdbpdb_name-spdb_srv

3. Have users connect using the new service - here's a sample TNS entry for the

tnames.ora:

PDB =

(DESCRIPTION =

(ADDRESS = (PROTOCOL = TCP)(HOST = lc4-scan)(PORT = 1521))

(CONNECT_DATA =

(SERVER = DEDICATED)

(SERVICE_NAME =pdb_srv)

)

)

1.1.3实际执行过程

oracle用户下执行,只需要在主节点一个节点执行就可以,如果在其他节点执行,会报该服务已经存在。

root@inmsh01

~]# su - oracle

[oracle@inmsh01

~]$  $ORACLE_HOME/bin/srvctl add service

-database znwgs -pdb tygisdb -s tygisdb_srv -preferred "ZNWGS1" -a

"ZNWGS2,ZNWGS3"

[oracle@inmsh01

~]$ $ORACLE_HOME/bin/srvctl start service -db znwgs  -s tygisdb_srv

[oracle@inmsh01 ~]$

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值