Which node will be elected if the cluster have only 2 master eligible node

Let us say I have nodes A(Master ) , B(Maser eligible ) & Node C (master eligible ) in a 3 node cluster and for some reason, the Node A is down and a master election is triggered since the quorum is 2 and we have two masters eligible nodes B & C in the cluster.
So how will the voting happen between b & c

According to the source code in ElectMasterService.java, the master-eligible node that is most likely to be elected as the new master is the one that has a higher cluster state version, i.e. the one which has the most up-to-date cluster state.

And if all master-eligible nodes have the same cluster state version, they are sorted by ID and the first one wins.

1 Like

That makes sense thanks a lot for the answer

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.