《终日打雁,叫雁啄了眼》-- Error is 16047

DG搭建过程中一直报错:

Sat Feb 12 15:50:09 2022 PING[ARC2]: Heartbeat failed to connect to standby 'standby'. Error is 16047. 
Sat Feb 12 15:51:10 2022 PING[ARC2]: Heartbeat failed to connect to standby 'standby'. Error is 16047. 
Sat Feb 12 15:52:10 2022 PING[ARC2]: Heartbeat failed to connect to standby 'standby'. Error is 16047.

检查了tsname.ora

standby =
 (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.5.89)(PORT = 1521))
    (CONNECT_DATA =
      (SERVER = DEDICATED)
      (SERVICE_NAME = standby)
    )
  )

检查参数设置:

SQL> show parameter log_archive_config;
NAME 		  TYPE        VALUE
log_archive_config string DG_CONFIG=(primary,standby)

SQL> show parameter log_archive_dest_2;
NAME 		   TYPE        VALUE
log_archive_dest_2 string  SERVICE=standbyLGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=standby
-- 重新执行了一次:
SQL> alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG=(primary,standby)' scope=both;
SQL> alter system set log_archive_dest_2='SERVICE=standbyLGWR ASYNC VALID_FOR=(ONLINE_LOGFILES,PRIMARY_ROLE) DB_UNIQUE_NAME=standby' scope=both;

密码文件重新拷贝了一份到备库:

[oracle@primary dbs]$ scp orapwprimary  192.168.5.89:/u01/oracle/11.2.0.3/product/dbs/
oracle@192.168.5.89's password: 
orapwprimary               100% 1536     1.5KB/s   00:00   

该想的都检查了,但还是报错,然后查看trc文件:

[oracle@primary trace]$  ls -lrt *arc*
-rw-r----- 1 oracle asmadmin 5560 2月  12 15:58 primary_arc2_1441.trc
-rw-r----- 1 oracle asmadmin  177 2月  12 15:58 primary_arc3_1445.trm
-rw-r----- 1 oracle asmadmin 2566 2月  12 15:58 primary_arc3_1445.trc
[oracle@primary trace]$ tail -f primary_arc3_1445.trc 
Redo shipping client performing standby login

*** 2022-02-12 15:58:11.661
*** 2022-02-12 15:58:11.661 4645 krsu.c
Logged on to standby successfully
Client logon and security negotiation successful!   -- 发现登录备库成功
Error 16047 attaching to destination LOG_ARCHIVE_DEST_2 standby host 'standby'
*** 2022-02-12 15:58:11.676 2932 krsi.c
krsi_dst_fail: dest:2 err:16047 force:0 blast:1
kcrrwkx: unknown error:16047

最后发现犯了个低级错误:备库的参数没有设置:log_archive_config

[oracle@standby dbs]$ sqlplus / as sysdba

SQL*Plus: Release 11.2.0.3.0 Production on Sat Feb 12 16:02:39 2022

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


Connected to:
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
With the Partitioning, Real Application Clusters, Automatic Storage Management, OLAP,
Data Mining and Real Application Testing options

SQL> show parameter log_archive_config;

NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
log_archive_config                   string
SQL> alter system set LOG_ARCHIVE_CONFIG='DG_CONFIG=(primary,standby)' scope=both;

System altered.

问题解决!!!

总结:松懈是一切低级的错误的根源。

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

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

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

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

two_rain

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

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

余额充值