首页 > 解决方案 > 尽管具有连接性和匹配模式,但 Cassandra 仍进行了分区

问题描述

我有一个 3 节点 cassandra (3.0.15) 集群,其中节点似乎已分区。从不同节点看nodetool status,输出不一致。nodetool describecluster八卦信息 ( nodetool gossipinfo) 似乎在所有节点上都是最新的。除了读取超时之外,日志中没有错误,这似乎是由于分区造成的。

尝试解决此问题但无效:

  1. 滚动重启
  2. 全集群重启
  3. 在每个节点上禁用/启用八卦

节点 1 (192.168.2.247):

$ nodetool describecluster
Cluster Information:
        Name: Test Cluster
        Snitch: org.apache.cassandra.locator.DynamicEndpointSnitch
        Partitioner: org.apache.cassandra.dht.Murmur3Partitioner
        Schema versions:
                59ffe9aa-aca7-34b3-8c5e-b736d221b922: [192.168.2.248, 192.168.2.247]

                UNREACHABLE: [192.168.2.249]

$ nodetool status
Datacenter: datacenter1
=======================
Status=Up/Down
|/ State=Normal/Leaving/Joining/Moving
--  Address        Load       Tokens       Owns (effective)  Host ID                               Rack
UN  192.168.2.248  210.23 GB  256          67.7%             f6593c49-6739-4b8c-a8d9-8321915a660d  rack1
DN  192.168.2.249  190.9 GB   256          68.6%             6ac211c2-bab1-4e2b-bc84-18d911e005d0  rack1
UN  192.168.2.247  157.82 GB  256          63.7%             eb462857-cbfb-4e41-8be9-5d241d273b81  rack1

节点 2 (192.168.2.248):

$ nodetool describecluster
Cluster Information:
        Name: Test Cluster
        Snitch: org.apache.cassandra.locator.DynamicEndpointSnitch
        Partitioner: org.apache.cassandra.dht.Murmur3Partitioner
        Schema versions:
                59ffe9aa-aca7-34b3-8c5e-b736d221b922: [192.168.2.248, 192.168.2.249, 192.168.2.247]

$ nodetool status
Datacenter: datacenter1
=======================
Status=Up/Down
|/ State=Normal/Leaving/Joining/Moving
--  Address        Load       Tokens       Owns (effective)  Host ID                               Rack
UN  192.168.2.248  210.24 GB  256          67.7%             f6593c49-6739-4b8c-a8d9-8321915a660d  rack1
UN  192.168.2.249  190.9 GB   256          68.6%             6ac211c2-bab1-4e2b-bc84-18d911e005d0  rack1
UN  192.168.2.247  157.82 GB  256          63.7%             eb462857-cbfb-4e41-8be9-5d241d273b81  rack1

节点 3 (192.168.2.249):

$ nodetool describecluster
Cluster Information:
        Name: Test Cluster
        Snitch: org.apache.cassandra.locator.DynamicEndpointSnitch
        Partitioner: org.apache.cassandra.dht.Murmur3Partitioner
        Schema versions:
                59ffe9aa-aca7-34b3-8c5e-b736d221b922: [192.168.2.248]

                UNREACHABLE: [192.168.2.249, 192.168.2.247]

$ nodetool status
Datacenter: datacenter1
=======================
Status=Up/Down
|/ State=Normal/Leaving/Joining/Moving
--  Address        Load       Tokens       Owns (effective)  Host ID                               Rack
UN  192.168.2.248  210.24 GB  256          67.7%             f6593c49-6739-4b8c-a8d9-8321915a660d  rack1
UN  192.168.2.249  190.92 GB  256          68.6%             6ac211c2-bab1-4e2b-bc84-18d911e005d0  rack1
UN  192.168.2.247  157.84 GB  256          63.7%             eb462857-cbfb-4e41-8be9-5d241d273b81  rack1

标签: cassandracassandra-3.0

解决方案


推荐阅读