-
Notifications
You must be signed in to change notification settings - Fork 24.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Voting Only Master Node #14340
Comments
This is definitely on our horizon. We need to do some infra work before we get there though... on it :) |
I'm new to ES, but won't it be better and maybe technically easier to give "points" to the master eligible nodes? Those points would give priority to the best ranked node to become master. And (new case) if you have a fast A and slow B and C, it means that B and C can take over if the cluster lost A, but as soon as the fast A node is back online, it takes its mastership back. It probably means changing the election process, but no new node status is needed. Does it make sense? Again i'm new to all this. |
@bertrandfalguiere no worries and welcome to the repo. If I read you correctly, you want to have some mechanics to influence master election and indicate you prefer one master over another. Putting all the trickiness of a distributed master election aside (it's not easy to add these things correctly), the main thing to realize here that you need to have a good working master at any given moment. Otherwise your cluster is in a big risk. So have a slow master and a fast master doesn't make sense - you need two fast masters etc. PS. We try to keep github for concrete issues. For more discussion-y things we ask people to go to https://discuss.elastic.co |
Pinging @elastic/es-distributed |
In some cloud use cases we might have a two zone deployment with a third zone containing only a tiebreaker master node. By default, this will be configured with 1 GB RAM, and may not be suitable for larger clusters. If this could be configured as a voting-only node, then it could provide quorum without becoming an active master. |
A voting-only master-eligible node is a node that can participate in master elections but will not act as a master in the cluster. In particular, a voting-only node can help elect another master-eligible node as master, and can serve as a tiebreaker in elections. High availability (HA) clusters require at least three master-eligible nodes, so that if one of the three nodes is down, then the remaining two can still elect a master amongst them-selves. This only requires one of the two remaining nodes to have the capability to act as master, but both need to have voting powers. This means that one of the three master-eligible nodes can be made as voting-only. If this voting-only node is a dedicated master, a less powerful machine or a smaller heap-size can be chosen for this node. Alternatively, a voting-only non-dedicated master node can play the role of the third master-eligible node, which allows running an HA cluster with only two dedicated master nodes. Closes #14340 Co-authored-by: David Turner <david.turner@elastic.co>
A voting-only master-eligible node is a node that can participate in master elections but will not act as a master in the cluster. In particular, a voting-only node can help elect another master-eligible node as master, and can serve as a tiebreaker in elections. High availability (HA) clusters require at least three master-eligible nodes, so that if one of the three nodes is down, then the remaining two can still elect a master amongst them-selves. This only requires one of the two remaining nodes to have the capability to act as master, but both need to have voting powers. This means that one of the three master-eligible nodes can be made as voting-only. If this voting-only node is a dedicated master, a less powerful machine or a smaller heap-size can be chosen for this node. Alternatively, a voting-only non-dedicated master node can play the role of the third master-eligible node, which allows running an HA cluster with only two dedicated master nodes. Closes #14340 Co-authored-by: David Turner <david.turner@elastic.co>
The current ideal setup for master nodes is to have 3 master nodes, thus giving high availability (HA) with a quorum of 2 master nodes at any given time.
However, in some cloud regions (and more frequently in internal data centers), this creates a problem because there may only be two available zones to place your nodes. In these scenarios, you do not want to give up HA just to maintain 3 master nodes (to be clear: it's better than not doing it, but it's less than ideal) because it means that you have a lopsided HA environment where one "half" cannot actually survive without the other.
The only real solution to this problem is to have a third zone, even if that third zone is a slightly higher latency (across the globe is not going to work), then plunk a master node into that zone to give a single master node per zone -- thus enabling the actual survivability of any single zone, but not of two zones.
Now, you could do this today with a master node and things would be generally okay except that the master node with the added latency may become the elected master node, which is obviously not ideal.
This is where a voting-only master node improves this setup significantly. If you have a master node that can itself not be elected, but that participates in elections only, then you can have a tiny node (careful with VM size due to automatic network throttling in cloud ecosystems!) that help to survive the loss of any single zone without seriously risking performance.
The text was updated successfully, but these errors were encountered: