【发布时间】:2020-12-06 22:56:53
【问题描述】:
有没有办法在 ActiveMQ Artemis 中诊断 HA 问题?我有一对运行良好的共享存储服务器。当我关闭主服务器时,辅助服务器会接管,直到主服务器告诉它它已备份,然后主服务器接管,辅助服务器恢复为辅助服务器。
我把配置复制到另一对服务器上,但是这个不工作。
据我所知,一切看起来都很好。集群出现在控制台中,两台服务器连接。当我关闭主服务器时,辅助服务器会记录以下消息:
2020-12-06 16:59:26,379 WARN [org.apache.activemq.artemis.core.client] AMQ212037: Connection failure to <Primary IP>/<Primary IP>:61616 has been detected: AMQ219015: The connection was disconnected because of server shutdown [code=DISCONNECTED]
在工作对中,在这条消息之后,辅助节点迅速部署我所有的地址和队列并接管。但是新的对,从属在这之后什么都不做。
我不确定从哪里开始寻找。我只是不断将非工作对的配置与工作对的配置进行比较。
我正在使用 NFS 挂载。共享文件的类型是 Azure 的 NetApp。
这是我的代理配置。这是正确的,因为它适用于另一对......
初级:
<connectors>
<connector name="artemis">tcp://<primary URL>:61616</connector>
<connector name="artemis-backup">tcp://<secondary URL>:61616</connector>
</connectors>
<cluster-user>activemq</cluster-user>
<cluster-password>artemis123</cluster-password>
<ha-policy>
<shared-store>
<master>
<failover-on-shutdown>true</failover-on-shutdown>
</master>
</shared-store>
</ha-policy>
<cluster-connections>
<cluster-connection name="cluster-1">
<connector-ref>artemis</connector-ref>
<static-connectors>
<connector-ref>artemis-backup</connector-ref>
</static-connectors>
</cluster-connection>
</cluster-connections>
中学:
<connectors>
<connector name="artemis-live">tcp://<primary URL>:61616</connector>
<connector name="artemis">tcp://<secondary URL>:61616</connector>
</connectors>
<cluster-user>activemq</cluster-user>
<cluster-password>artemis123</cluster-password>
<ha-policy>
<shared-store>
<slave>
<allow-failback>true</allow-failback>
<failover-on-shutdown>true</failover-on-shutdown>
</slave>
</shared-store>
</ha-policy>
<cluster-connections>
<cluster-connection name="cluster-1">
<connector-ref>artemis</connector-ref>
<static-connectors>
<connector-ref>artemis-live</connector-ref>
</static-connectors>
</cluster-connection>
</cluster-connections>
【问题讨论】:
标签: high-availability activemq-artemis