You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@zookeeper.apache.org by Biju N <bi...@gmail.com> on 2014/09/30 18:53:03 UTC

Finding current quorum size

Hi There,
   What is the best approach to find the number of active servers in the
quorum? Thank you in advance for your input.

- Biju

RE: Finding current quorum size

Posted by Rakesh R <ra...@huawei.com>.
Hi Biju,

Please see four letter word - mntr, which gives the cluster status, probably you can parse necessary details from this. Will this be sufficient for you?

http://zookeeper.apache.org/doc/r3.5.0-alpha/zookeeperAdmin.html#The+Four+Letter+Words


Regards,
Rakesh
-----Original Message-----
From: Biju N [mailto:bijuatapache@gmail.com] 
Sent: 01 October 2014 23:35
To: dev@zookeeper.apache.org
Subject: Re: Finding current quorum size

If we can have an additional JMX attribute which stores the quorum size at the node sees it that should help. The leader node should have the correct quorum size at any point in time. Correct?

On Wed, Oct 1, 2014 at 12:06 PM, Dutch Meyer <ho...@gmail.com> wrote:

> Different zookeeper servers may have different views of who has 
> failed.  If a node is failed from the perspective of some members of 
> the ensemble but not others, what ;would you expect to be reported?
>
>
> On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com> wrote:
>
> > Looks like JMX data is static based zoo.cfg. If any of the nodes 
> > fail or
> a
> > new node gets added, the size doesn't gets updated until zoo.cfg is 
> > updated. Let me know otherwise.
> >
> > On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com> wrote:
> >
> > > AFAIR JMX shows this.
> > >
> > > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> > >
> > > > Hi There,
> > > >    What is the best approach to find the number of active 
> > > > servers in
> > the
> > > > quorum? Thank you in advance for your input.
> > > >
> > > > - Biju
> > > >
> > >
> >
>
>
>
> --
> -=-Dutch
>

Re: Finding current quorum size

Posted by Alexander Shraer <sh...@gmail.com>.
Consider proposing a patch to export it if its helpful for your usecase.
If you can make the case why others may need this, it could probably be
added to ZK

Re: Finding current quorum size

Posted by Biju N <bi...@gmail.com>.
Thanks Alexander. Unfortunately the count doesn't get exported.

On Wed, Oct 1, 2014 at 4:51 PM, Alexander Shraer <sh...@gmail.com> wrote:

> I don't think there is a plan to have this patch for < 3.5.0 since those
> versions use a static configuration.
> As mentioned here by others its not clear how to account for node failures
> as the system is asynchronous.
>
> The leader maintains a count of synced followers, perhaps you could use
> this count some how ? I'm not sure
> if its exported though.
>
> On Wed, Oct 1, 2014 at 12:23 PM, Biju N <bi...@gmail.com> wrote:
>
> > Thanks Alexander. Is there a plan to make the patch available in prior
> > versions. Also if it is not planned, it would be helpful to have an
> > attribute to store the actual count of the nodes in the quorum which can
> be
> > used for monitoring along with the quorum size attribute currently
> > available.
> >
> > On Wed, Oct 1, 2014 at 3:00 PM, Alexander Shraer <sh...@gmail.com>
> > wrote:
> >
> > > if a node gets added JMX should reflect this (
> > > https://issues.apache.org/jira/browse/ZOOKEEPER-1659)
> > >
> > > On Wed, Oct 1, 2014 at 11:04 AM, Biju N <bi...@gmail.com>
> wrote:
> > >
> > > > If we can have an additional JMX attribute which stores the quorum
> size
> > > at
> > > > the node sees it that should help. The leader node should have the
> > > correct
> > > > quorum size at any point in time. Correct?
> > > >
> > > > On Wed, Oct 1, 2014 at 12:06 PM, Dutch Meyer <ho...@gmail.com>
> wrote:
> > > >
> > > > > Different zookeeper servers may have different views of who has
> > failed.
> > > > If
> > > > > a node is failed from the perspective of some members of the
> ensemble
> > > but
> > > > > not others, what ;would you expect to be reported?
> > > > >
> > > > >
> > > > > On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com>
> > wrote:
> > > > >
> > > > > > Looks like JMX data is static based zoo.cfg. If any of the nodes
> > fail
> > > > or
> > > > > a
> > > > > > new node gets added, the size doesn't gets updated until zoo.cfg
> is
> > > > > > updated. Let me know otherwise.
> > > > > >
> > > > > > On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <kuebzky@gmail.com
> >
> > > > wrote:
> > > > > >
> > > > > > > AFAIR JMX shows this.
> > > > > > >
> > > > > > > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> > > > > > >
> > > > > > > > Hi There,
> > > > > > > >    What is the best approach to find the number of active
> > servers
> > > > in
> > > > > > the
> > > > > > > > quorum? Thank you in advance for your input.
> > > > > > > >
> > > > > > > > - Biju
> > > > > > > >
> > > > > > >
> > > > > >
> > > > >
> > > > >
> > > > >
> > > > > --
> > > > > -=-Dutch
> > > > >
> > > >
> > >
> >
>

Re: Finding current quorum size

Posted by Alexander Shraer <sh...@gmail.com>.
I don't think there is a plan to have this patch for < 3.5.0 since those
versions use a static configuration.
As mentioned here by others its not clear how to account for node failures
as the system is asynchronous.

The leader maintains a count of synced followers, perhaps you could use
this count some how ? I'm not sure
if its exported though.

On Wed, Oct 1, 2014 at 12:23 PM, Biju N <bi...@gmail.com> wrote:

> Thanks Alexander. Is there a plan to make the patch available in prior
> versions. Also if it is not planned, it would be helpful to have an
> attribute to store the actual count of the nodes in the quorum which can be
> used for monitoring along with the quorum size attribute currently
> available.
>
> On Wed, Oct 1, 2014 at 3:00 PM, Alexander Shraer <sh...@gmail.com>
> wrote:
>
> > if a node gets added JMX should reflect this (
> > https://issues.apache.org/jira/browse/ZOOKEEPER-1659)
> >
> > On Wed, Oct 1, 2014 at 11:04 AM, Biju N <bi...@gmail.com> wrote:
> >
> > > If we can have an additional JMX attribute which stores the quorum size
> > at
> > > the node sees it that should help. The leader node should have the
> > correct
> > > quorum size at any point in time. Correct?
> > >
> > > On Wed, Oct 1, 2014 at 12:06 PM, Dutch Meyer <ho...@gmail.com> wrote:
> > >
> > > > Different zookeeper servers may have different views of who has
> failed.
> > > If
> > > > a node is failed from the perspective of some members of the ensemble
> > but
> > > > not others, what ;would you expect to be reported?
> > > >
> > > >
> > > > On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com>
> wrote:
> > > >
> > > > > Looks like JMX data is static based zoo.cfg. If any of the nodes
> fail
> > > or
> > > > a
> > > > > new node gets added, the size doesn't gets updated until zoo.cfg is
> > > > > updated. Let me know otherwise.
> > > > >
> > > > > On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com>
> > > wrote:
> > > > >
> > > > > > AFAIR JMX shows this.
> > > > > >
> > > > > > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> > > > > >
> > > > > > > Hi There,
> > > > > > >    What is the best approach to find the number of active
> servers
> > > in
> > > > > the
> > > > > > > quorum? Thank you in advance for your input.
> > > > > > >
> > > > > > > - Biju
> > > > > > >
> > > > > >
> > > > >
> > > >
> > > >
> > > >
> > > > --
> > > > -=-Dutch
> > > >
> > >
> >
>

Re: Finding current quorum size

Posted by Biju N <bi...@gmail.com>.
Thanks Alexander. Is there a plan to make the patch available in prior
versions. Also if it is not planned, it would be helpful to have an
attribute to store the actual count of the nodes in the quorum which can be
used for monitoring along with the quorum size attribute currently
available.

On Wed, Oct 1, 2014 at 3:00 PM, Alexander Shraer <sh...@gmail.com> wrote:

> if a node gets added JMX should reflect this (
> https://issues.apache.org/jira/browse/ZOOKEEPER-1659)
>
> On Wed, Oct 1, 2014 at 11:04 AM, Biju N <bi...@gmail.com> wrote:
>
> > If we can have an additional JMX attribute which stores the quorum size
> at
> > the node sees it that should help. The leader node should have the
> correct
> > quorum size at any point in time. Correct?
> >
> > On Wed, Oct 1, 2014 at 12:06 PM, Dutch Meyer <ho...@gmail.com> wrote:
> >
> > > Different zookeeper servers may have different views of who has failed.
> > If
> > > a node is failed from the perspective of some members of the ensemble
> but
> > > not others, what ;would you expect to be reported?
> > >
> > >
> > > On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com> wrote:
> > >
> > > > Looks like JMX data is static based zoo.cfg. If any of the nodes fail
> > or
> > > a
> > > > new node gets added, the size doesn't gets updated until zoo.cfg is
> > > > updated. Let me know otherwise.
> > > >
> > > > On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com>
> > wrote:
> > > >
> > > > > AFAIR JMX shows this.
> > > > >
> > > > > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> > > > >
> > > > > > Hi There,
> > > > > >    What is the best approach to find the number of active servers
> > in
> > > > the
> > > > > > quorum? Thank you in advance for your input.
> > > > > >
> > > > > > - Biju
> > > > > >
> > > > >
> > > >
> > >
> > >
> > >
> > > --
> > > -=-Dutch
> > >
> >
>

Re: Finding current quorum size

Posted by Alexander Shraer <sh...@gmail.com>.
if a node gets added JMX should reflect this (
https://issues.apache.org/jira/browse/ZOOKEEPER-1659)

On Wed, Oct 1, 2014 at 11:04 AM, Biju N <bi...@gmail.com> wrote:

> If we can have an additional JMX attribute which stores the quorum size at
> the node sees it that should help. The leader node should have the correct
> quorum size at any point in time. Correct?
>
> On Wed, Oct 1, 2014 at 12:06 PM, Dutch Meyer <ho...@gmail.com> wrote:
>
> > Different zookeeper servers may have different views of who has failed.
> If
> > a node is failed from the perspective of some members of the ensemble but
> > not others, what ;would you expect to be reported?
> >
> >
> > On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com> wrote:
> >
> > > Looks like JMX data is static based zoo.cfg. If any of the nodes fail
> or
> > a
> > > new node gets added, the size doesn't gets updated until zoo.cfg is
> > > updated. Let me know otherwise.
> > >
> > > On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com>
> wrote:
> > >
> > > > AFAIR JMX shows this.
> > > >
> > > > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> > > >
> > > > > Hi There,
> > > > >    What is the best approach to find the number of active servers
> in
> > > the
> > > > > quorum? Thank you in advance for your input.
> > > > >
> > > > > - Biju
> > > > >
> > > >
> > >
> >
> >
> >
> > --
> > -=-Dutch
> >
>

Re: Finding current quorum size

Posted by Biju N <bi...@gmail.com>.
If we can have an additional JMX attribute which stores the quorum size at
the node sees it that should help. The leader node should have the correct
quorum size at any point in time. Correct?

On Wed, Oct 1, 2014 at 12:06 PM, Dutch Meyer <ho...@gmail.com> wrote:

> Different zookeeper servers may have different views of who has failed.  If
> a node is failed from the perspective of some members of the ensemble but
> not others, what ;would you expect to be reported?
>
>
> On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com> wrote:
>
> > Looks like JMX data is static based zoo.cfg. If any of the nodes fail or
> a
> > new node gets added, the size doesn't gets updated until zoo.cfg is
> > updated. Let me know otherwise.
> >
> > On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com> wrote:
> >
> > > AFAIR JMX shows this.
> > >
> > > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> > >
> > > > Hi There,
> > > >    What is the best approach to find the number of active servers in
> > the
> > > > quorum? Thank you in advance for your input.
> > > >
> > > > - Biju
> > > >
> > >
> >
>
>
>
> --
> -=-Dutch
>

Re: Finding current quorum size

Posted by Dutch Meyer <ho...@gmail.com>.
Different zookeeper servers may have different views of who has failed.  If
a node is failed from the perspective of some members of the ensemble but
not others, what ;would you expect to be reported?


On Wed, Oct 1, 2014 at 8:38 AM, Biju N <bi...@gmail.com> wrote:

> Looks like JMX data is static based zoo.cfg. If any of the nodes fail or a
> new node gets added, the size doesn't gets updated until zoo.cfg is
> updated. Let me know otherwise.
>
> On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com> wrote:
>
> > AFAIR JMX shows this.
> >
> > 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
> >
> > > Hi There,
> > >    What is the best approach to find the number of active servers in
> the
> > > quorum? Thank you in advance for your input.
> > >
> > > - Biju
> > >
> >
>



-- 
-=-Dutch

Re: Finding current quorum size

Posted by Biju N <bi...@gmail.com>.
Looks like JMX data is static based zoo.cfg. If any of the nodes fail or a
new node gets added, the size doesn't gets updated until zoo.cfg is
updated. Let me know otherwise.

On Wed, Oct 1, 2014 at 10:19 AM, Kuba Lekstan <ku...@gmail.com> wrote:

> AFAIR JMX shows this.
>
> 2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:
>
> > Hi There,
> >    What is the best approach to find the number of active servers in the
> > quorum? Thank you in advance for your input.
> >
> > - Biju
> >
>

Re: Finding current quorum size

Posted by Kuba Lekstan <ku...@gmail.com>.
AFAIR JMX shows this.

2014-09-30 18:53 GMT+02:00 Biju N <bi...@gmail.com>:

> Hi There,
>    What is the best approach to find the number of active servers in the
> quorum? Thank you in advance for your input.
>
> - Biju
>