无法用任何种子cassandra八卦

时间:2016-07-27 10:32:35

标签: cassandra datastax

我在我的Windows机器上安装了Data Stax 3.7(IP:10.175.12.249)并在我的cassandra.yaml文件中进行了以下更改:

cluster_name:' Test_cluster' listen_address:" 10.175.12.249" start_rpc:true rpc_address:" 0.0.0.0" broadcast_rpc_address:" 10.175.12.249" 种子:" 10.175.12.249" endpoint_snitch:SimpleSnitch

现在,我启动了服务,cassandra在种子节点上正常运行。

我尝试将另一个节点添加到我的群集中。所以我在另一台Windows机器上安装了Data Stax 3.7(IP:192.168.158.78)并在cassandra.yaml文件中进行了以下更改:

cluster_name:' Test_cluster' listen_address:" 192.168.158.78" start_rpc:true rpc_address:" 0.0.0.0" broadcast_rpc_address:" 192.168.158.78" 种子:" 10.175.12.249" endpoint_snitch:SimpleSnitch

现在当我在第二台机器上启动cassandra服务时,我收到以下错误:

INFO  09:41:27 Cassandra version: 3.7.0
INFO  09:41:27 Thrift API version: 20.1.0
INFO  09:41:27 CQL supported versions: 3.4.2 (default: 3.4.2)
INFO  09:41:27 Initializing index summary manager with a memory pool size of 100 MB and a resize interval of 60 minutes
INFO  09:41:27 Starting Messaging Service on /192.168.158.78:7000 (Intel(R) Centrino(R) Advanced-N 6235)
INFO  09:41:27 Scheduling approximate time-check task with a precision of 10 milliseconds
Exception (java.lang.RuntimeException) encountered during startup: Unable to gossip with any seeds
java.lang.RuntimeException: Unable to gossip with any seeds
        at org.apache.cassandra.gms.Gossiper.doShadowRound(Gossiper.java:1386)
        at org.apache.cassandra.service.StorageService.checkForEndpointCollision(StorageService.java:561)
        at org.apache.cassandra.service.StorageService.prepareToJoin(StorageService.java:855)
        at org.apache.cassandra.service.StorageService.initServer(StorageService.java:725)
        at org.apache.cassandra.service.StorageService.initServer(StorageService.java:625)
        at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:370)
        at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:585)
        at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:714)
ERROR 09:41:58 Exception encountered during startup
java.lang.RuntimeException: Unable to gossip with any seeds
        at org.apache.cassandra.gms.Gossiper.doShadowRound(Gossiper.java:1386) ~[apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.StorageService.checkForEndpointCollision(StorageService.java:561) ~[apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.StorageService.prepareToJoin(StorageService.java:855) ~[apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.StorageService.initServer(StorageService.java:725) ~[apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.StorageService.initServer(StorageService.java:625) ~[apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.CassandraDaemon.setup(CassandraDaemon.java:370) [apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.CassandraDaemon.activate(CassandraDaemon.java:585) [apache-cassandra-3.7.0.jar:3.7.0]
        at org.apache.cassandra.service.CassandraDaemon.main(CassandraDaemon.java:714) [apache-cassandra-3.7.0.jar:3.7.0]
WARN  09:41:58 No local state or state is in silent shutdown, not announcing shutdown
INFO  09:41:58 Waiting for messaging service to quiesce

以下是种子节点上的nodetool状态的输出(IP:10.175.12.249): C:\ Program Files \ DataStax-DDC \ apache-cassandra \ bin> nodetool status

Datacenter: datacenter1
========================
Status=Up/Down
|/ State=Normal/Leaving/Joining/Moving
--  Address         Load       Tokens       Owns (effective)  Host ID                               Rack
DN  192.168.158.78  ?          256          68.1%             6bc4e927-3def-4dfc-b5e7-31f5882ce475  rack1
UN  10.175.12.249   257.76 KiB  256          65.7%             300d731e-a27c-4922-aacc-6d42e8e49151  rack1

感谢!!!

1 个答案:

答案 0 :(得分:7)

conf / cassandra.yaml中的- seeds:在同一个conf文件中应与listen_address:具有相同的值(相同的IP或主机名)。

当IP地址不匹配时,我遇到了这个错误。尝试保持相同并重新启动群集。希望这会有所帮助...