cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paulo Motta (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-12485) Always require replace_address to replace existing token
Date Mon, 10 Oct 2016 13:27:20 GMT

    [ https://issues.apache.org/jira/browse/CASSANDRA-12485?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15562307#comment-15562307
] 

Paulo Motta commented on CASSANDRA-12485:
-----------------------------------------

bq. So it seems as though, for the check in StorageService.checkForEndpointCollision, the
new containsTokensOfLiveOwners (still working on the name) method in Gossiper should simply
grab the current node's token list with StorageService.getTokens() and then iterate through
the liveEndpoints and do something like a Collections.disjoint to see if there are any common
elements in any of the lists.

bq. Does that seem correct? 

Yes, but this check should probably be in {{StorageService}}, and verify that no live or unreachable
token owner contains the tokens of the bootstrapping node if {{replace_address}} is not specified
(see {{StorageService.getLiveRingMembers}} for an example).

> Always require replace_address to replace existing token
> --------------------------------------------------------
>
>                 Key: CASSANDRA-12485
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12485
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Distributed Metadata
>            Reporter: Paulo Motta
>            Priority: Minor
>              Labels: lhf
>
> CASSANDRA-10134 prevented replace an existing node unless {{\-Dcassandra.replace_address}}
or {{\-Dcassandra.allow_unsafe_replace=true}} is specified.
> We should extend this behavior to tokens, preventing a node from joining the ring if
another node with the same token already existing in the ring, unless {{\-Dcassandra.replace_address}}
or {{\-Dcassandra.allow_unsafe_replace=true}} is specified in order to avoid catastrophic
scenarios.
> One scenario where this can easily happen is if you replace a node with another node
with a different IP, and after some time you restart the original node by mistake. The original
node will then take over the tokens of the replaced node (since it has a newer gossip generation).



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message