Loading

adg搭建-ora-01034 ora-27101

在adg搭建过程中,备库启动到nomount状态,并且使用连接字符串测试可以连接上主备库,但是执行脚本就报错ora-01034 ora-27101

 

 遇到这种报错,也是先百度了下,然后也没有遇到相关案例,这个报错就是提示服务备库没有启动,实际情况是备库已经启动到了nomount状态。

 

 最终排查tnsnames.ora文件,因为adg是4个节点的,因此我在节点4将备库启动到了nomount状态,其他节点的数据库并未启动到nomount状态,并且tnsnams.ora里面的连接字符串我是按照node1/node2/node3/node4进行设置的

db_namexxx =
 (description =
   (load_balance= off)(failover = on)(connect_timeout=1)(retry_count=3)
   (address_list =
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node1)(port = 1521))
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node2)(port = 1521))
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node3)(port = 1521))
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node4)(port = 1521))
    )
    (connect_data =
      (service_name = xxx_name)
    )
  )

将连接字符串修改为如下

db_namexxx =
 (description =
   (load_balance= off)(failover = on)(connect_timeout=1)(retry_count=3)
   (address_list =
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node4)(port = 1521))
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node2)(port = 1521))
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node3)(port = 1521))
      (address = (protocol = tcp)(host = xxx.xxx.xxx.node1)(port = 1521))
    )
    (connect_data =
      (service_name = xxx_name)
    )
  )

 

posted @ 2022-10-18 17:24  李行行  阅读(66)  评论(0编辑  收藏  举报