You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@zookeeper.apache.org by WangYQ <wa...@163.com> on 2016/05/02 12:52:48 UTC

how to make a server be leader permanently

i want to make a server with lower load be the zookeeper leader permanently. is there any method or configuration?

Re: how to make a server be leader permanently

Posted by Flavio Junqueira <fp...@apache.org>.
+1

> On 02 May 2016, at 23:00, Alexander Shraer <sh...@gmail.com> wrote:
> 
> If you're interested to work on something like that, a good starting point
> could be
> implementing a leader handoff API: ZOOKEEPER-2076
> 
> On Mon, May 2, 2016 at 4:19 AM, Flavio P JUNQUEIRA <fp...@apache.org> wrote:
> 
>> We don't have this kind of behavior enabled because it'd affect
>> availability. If your single leader fails, then the zookeeper ensemble
>> becomes unavailable until the server comes back and might require manual
>> intervention if the server is permanently down.
>> 
>> Also, upon recovery, the configured leader might not have the most recent
>> committed state,  which could cause you to lose data.
>> 
>> The bottom line is that you can't really force this kind of behavior
>> currently with zookeeper.
>> 
>> -Flavio
>> On 2 May 2016 11:53, "WangYQ" <wa...@163.com> wrote:
>> 
>> i want to make a server with lower load be the zookeeper leader
>> permanently. is there any method or configuration?
>> 


Re: how to make a server be leader permanently

Posted by Alexander Shraer <sh...@gmail.com>.
If you're interested to work on something like that, a good starting point
could be
implementing a leader handoff API: ZOOKEEPER-2076

On Mon, May 2, 2016 at 4:19 AM, Flavio P JUNQUEIRA <fp...@apache.org> wrote:

> We don't have this kind of behavior enabled because it'd affect
> availability. If your single leader fails, then the zookeeper ensemble
> becomes unavailable until the server comes back and might require manual
> intervention if the server is permanently down.
>
> Also, upon recovery, the configured leader might not have the most recent
> committed state,  which could cause you to lose data.
>
> The bottom line is that you can't really force this kind of behavior
> currently with zookeeper.
>
> -Flavio
> On 2 May 2016 11:53, "WangYQ" <wa...@163.com> wrote:
>
> i want to make a server with lower load be the zookeeper leader
> permanently. is there any method or configuration?
>

Re: how to make a server be leader permanently

Posted by Flavio P JUNQUEIRA <fp...@apache.org>.
We don't have this kind of behavior enabled because it'd affect
availability. If your single leader fails, then the zookeeper ensemble
becomes unavailable until the server comes back and might require manual
intervention if the server is permanently down.

Also, upon recovery, the configured leader might not have the most recent
committed state,  which could cause you to lose data.

The bottom line is that you can't really force this kind of behavior
currently with zookeeper.

-Flavio
On 2 May 2016 11:53, "WangYQ" <wa...@163.com> wrote:

i want to make a server with lower load be the zookeeper leader
permanently. is there any method or configuration?