Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Zookeeper >> mail # user >> Q about majority voting, # of nodes, even node number


Copy link to this message
-
Re: Q about majority voting, # of nodes, even node number
My understanding (which is admittedly limited):

There are 2 nodes left out of 3, so when both machines respond they will
get 2/3 of the vote, thus forming a majority. If you only had 2 machines in
your cluster for example, then if 1 died, then the others vote would only
make up 1/2 of the vote, which is not the majority, so you get no extra
redundancy in having 2 machines over having 1.
On Thu, Jan 16, 2014 at 3:59 PM, Otis Gospodnetic <
[EMAIL PROTECTED]> wrote:

> Hi,
>
> Somebody asked me recently and I "got stuck" trying to explain this.
> When people ask how many ZK nodes they should have a common answer is "odd
> number: 3 or 5 or ...", so ZK can do majority voting.  Correct so far?
> Another reason is for HA - if one ZK node dies, there are still 2 of them
> left.  And this is where I am missing something core - with just 2 nodes
> left, how can ZK do majority voting now?
>
> Thanks,
> Otis
> --
> Performance Monitoring * Log Analytics * Search Analytics
> Solr & Elasticsearch Support * http://sematext.com/
>
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB