我正在嘗試運行簡單的包含兩個節點的Infinispan服務器羣集。問題在於Infinispan忽略了clustered.xml
文件中的我的bind_addr
jgroups設置。我可以使用-Djgroups.bind_addr=GLOBAL
指定此設置 - 它可以工作,但不方便。我使用bin/clustered.sh
腳本啓動羣集,使用TCP協議堆棧和MPING進行節點自動發現。Infinispan服務器忽略jgroups bind_addr
相關JGroups的配置文件standalone/configuration/clustered.xml
的一部分:
<subsystem xmlns="urn:jboss:domain:jgroups:1.2" default-stack="${jboss.default.jgroups.stack:tcp}">
<stack name="udp">
<transport type="UDP" socket-binding="jgroups-udp"/>
<protocol type="PING"/>
<protocol type="MERGE2"/>
<protocol type="FD_SOCK" socket-binding="jgroups-udp-fd"/>
<protocol type="FD_ALL"/>
<protocol type="pbcast.NAKACK"/>
<protocol type="UNICAST2"/>
<protocol type="pbcast.STABLE"/>
<protocol type="pbcast.GMS"/>
<protocol type="UFC"/>
<protocol type="MFC"/>
<protocol type="FRAG2"/>
<protocol type="RSVP"/>
</stack>
<stack name="tcp">
<transport type="TCP" socket-binding="jgroups-tcp"/>
<protocol type="MPING" socket-binding="jgroups-mping">
<property name="bind_addr">GLOBAL</property>
</protocol>
<protocol type="MERGE2"/>
<protocol type="FD_SOCK" socket-binding="jgroups-tcp-fd"/>
<protocol type="FD"/>
<protocol type="VERIFY_SUSPECT"/>
<protocol type="pbcast.NAKACK">
<property name="use_mcast_xmit">false</property>
</protocol>
<protocol type="UNICAST2"/>
<protocol type="pbcast.STABLE"/>
<protocol type="pbcast.GMS"/>
<protocol type="UFC"/>
<protocol type="MFC"/>
<protocol type="FRAG2"/>
<protocol type="RSVP"/>
</stack>
</subsystem>
我也試過-Djgroups.ignore.bind_addr = true選項,以防止Infinispan的推導bind_addr從系統屬性而不是XML設置,誰就可能設置 - 它沒有幫助。
Infinispan 6.0版。
更新:插座結合組和接口元素:
<interfaces>
<interface name="management">
<!-- <inet-address value="${jboss.bind.address.management:127.0.0.1}"/> -->
<any-address/>
</interface>
<interface name="public">
<!-- <inet-address value="${jboss.bind.address:127.0.0.1}"/> -->
<any-address/>
</interface>
</interfaces>
<socket-binding-group name="standard-sockets" default-interface="public" port-offset="${jboss.socket.binding.port-offset:0}">
<socket-binding name="management-native" interface="management" port="${jboss.management.native.port:9999}"/>
<socket-binding name="management-http" interface="management" port="${jboss.management.http.port:9990}"/>
<socket-binding name="management-https" interface="management" port="${jboss.management.https.port:9443}"/>
<socket-binding name="ajp" port="8009"/>
<socket-binding name="hotrod" port="11222"/>
<socket-binding name="http" port="8080"/>
<socket-binding name="https" port="8443"/>
<socket-binding name="jgroups-mping" port="0" multicast-address="${jboss.default.multicast.address:234.99.54.14}" multicast-port="45700"/>
<socket-binding name="jgroups-tcp" port="7600"/>
<socket-binding name="jgroups-tcp-fd" port="57600"/>
<socket-binding name="jgroups-udp" port="55200" multicast-address="${jboss.default.multicast.address:234.99.54.14}" multicast-port="45688"/>
<socket-binding name="jgroups-udp-fd" port="54200"/>
<socket-binding name="memcached" port="11211"/>
<socket-binding name="modcluster" port="0" multicast-address="224.0.1.115" multicast-port="23364"/>
<socket-binding name="remoting" port="4447"/>
<socket-binding name="txn-recovery-environment" port="4712"/>
<socket-binding name="txn-status-manager" port="4713"/>
<socket-binding name="websocket" port="8181"/>
</socket-binding-group>
</server>
任何幫助將不勝感激!
我剛剛試過了,它沒有幫助;我猜這是沒用的,因爲中的默認接口是「public」,它已經具有值 (它是GLOBAL的類似物,據我所知)。我已經使用這些設置更新了帖子。 此外,socket-binding-group中指定的接口與TCP中的[bind_addr](http://www.jgroups.org/manual/html/protlist.html#Transport)屬性中指定的接口之間的關係是什麼? jgroups設置中的UDP元素? –
ars
2014-10-01 12:48:46