zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Garry Turkington <g.turking...@improvedigital.com>
Subject RE: ZooKeeper ensemble. Size and Impact ?
Date Mon, 13 Jul 2015 06:35:39 GMT

I claim no ZK expertise but did have a similar scenario so I'll share my conclusion and then
the ZK experts can point out how wrong I am. :)

The odd number of servers requirement is because a ZK consensus can only be formed by an *absolute*
majority of nodes in the ensemble. With an even number of servers fault-tolerance isn't as
expected. A cluster of 4 nodes can only survive 1 server loss before the ensemble goes down.
Which is the same as an ensemble of 3. The added server in the group of 4 gives no additional
fault tolerance in terms of the number of live nodes.

An ensemble of 2 does though seem to be a special case in that it has a somewhat unintuitive
quality; since it cannot survive the loss of either server (1 is *not* an absolute  majority
of 2) then it seems that the availability of a 2-node ensemble is worse than a single node
setup. If either node in the 2-node ensemble is lost then the ensemble will  go down.

That's why when faced with a similar scenario to your own -- where 3 hosts was overkill/not
available for the use case -- I went with a single node. Fortunately it was not a production


-----Original Message-----
From: Srinivasan Veerapandian [mailto:srinivasan.veerapandian@ericsson.com] 
Sent: 13 July 2015 07:18
To: user@zookeeper.apache.org
Subject: ZooKeeper ensemble. Size and Impact ?


We know ZK demands odd number of servers to provide reliability.
My requirement on having zookeeper in my application is to "know the application status" from
all the clients(Max 100).
And today my application can support deployment 1+1(=2) to N+1(=100) Given this I would like
to go with 2 ZK servers in two different instances because adding one more server for this
purpose would be demand one more instance itself in my 1+1 deployment model.


1.       What would happen to ensemble formed ? Would the service goes down automatically

2.       What would be the impact if number ZK server instances are even (E.g. 2)

How do I size a Zoo Keeper ensemble (cluster)?

Designing a Zoo Keeper Deployment


No virus found in this message.
Checked by AVG - www.avg.com
Version: 2014.0.4821 / Virus Database: 4365/10205 - Release Date: 07/11/15

View raw message