You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@zookeeper.apache.org by Will Johnson <wi...@attivio.com> on 2012/07/05 18:53:36 UTC

multiple zookeepers - same data directory

We recently ran into an issue where two zookeepers servers which were a part of two separate quorums were configured to use the same data directory.  Interestingly, the zookeeper servers did not seem to complain and both seemed to work fine until one of them was restarted.  Once that happened all sort of chaos ensued.  I understand that this is a misconfiguration should zookeeper complain about this or do users need to protect themselves in some external fashion?  Is a simple file lock enough or are there other things I should take into consideration if it's up to me to handle?

I'm happy to file a jira for this as I didn't see any doc related to it but I wanted to see if I missed something first.


-          will

Re: multiple zookeepers - same data directory

Posted by David Nickerson <da...@gmail.com>.
I too have encountered this, when I was running two standalone servers.

On Thu, Jul 5, 2012 at 1:34 PM, Will Johnson <wi...@attivio.com> wrote:

> https://issues.apache.org/jira/browse/ZOOKEEPER-1502
>
> thanks
>
> - will
>
> -----Original Message-----
> From: Patrick Hunt [mailto:phunt@apache.org]
> Sent: Thursday, July 05, 2012 1:10 PM
> To: user@zookeeper.apache.org
> Subject: Re: multiple zookeepers - same data directory
>
> Yes, please file a jira for this.
>
> Patrick
>
> On Thu, Jul 5, 2012 at 10:01 AM, Camille Fournier <ca...@apache.org>
> wrote:
> > There's nothing to prevent this as it stands, no, except user action.
> > A lock file might not be a bad idea.
> >
> > C
> >
> > On Thu, Jul 5, 2012 at 12:53 PM, Will Johnson <wi...@attivio.com> wrote:
> >
> >> We recently ran into an issue where two zookeepers servers which were
> >> a part of two separate quorums were configured to use the same data
> >> directory.  Interestingly, the zookeeper servers did not seem to
> >> complain and both seemed to work fine until one of them was
> >> restarted.  Once that happened all sort of chaos ensued.  I
> >> understand that this is a misconfiguration should zookeeper complain
> >> about this or do users need to protect themselves in some external
> >> fashion?  Is a simple file lock enough or are there other things I
> >> should take into consideration if it's up to me to handle?
> >>
> >> I'm happy to file a jira for this as I didn't see any doc related to
> >> it but I wanted to see if I missed something first.
> >>
> >>
> >> -          will
> >>
>

RE: multiple zookeepers - same data directory

Posted by Will Johnson <wi...@attivio.com>.
https://issues.apache.org/jira/browse/ZOOKEEPER-1502

thanks

- will

-----Original Message-----
From: Patrick Hunt [mailto:phunt@apache.org] 
Sent: Thursday, July 05, 2012 1:10 PM
To: user@zookeeper.apache.org
Subject: Re: multiple zookeepers - same data directory

Yes, please file a jira for this.

Patrick

On Thu, Jul 5, 2012 at 10:01 AM, Camille Fournier <ca...@apache.org> wrote:
> There's nothing to prevent this as it stands, no, except user action. 
> A lock file might not be a bad idea.
>
> C
>
> On Thu, Jul 5, 2012 at 12:53 PM, Will Johnson <wi...@attivio.com> wrote:
>
>> We recently ran into an issue where two zookeepers servers which were 
>> a part of two separate quorums were configured to use the same data 
>> directory.  Interestingly, the zookeeper servers did not seem to 
>> complain and both seemed to work fine until one of them was 
>> restarted.  Once that happened all sort of chaos ensued.  I 
>> understand that this is a misconfiguration should zookeeper complain 
>> about this or do users need to protect themselves in some external 
>> fashion?  Is a simple file lock enough or are there other things I 
>> should take into consideration if it's up to me to handle?
>>
>> I'm happy to file a jira for this as I didn't see any doc related to 
>> it but I wanted to see if I missed something first.
>>
>>
>> -          will
>>

Re: multiple zookeepers - same data directory

Posted by Patrick Hunt <ph...@apache.org>.
Yes, please file a jira for this.

Patrick

On Thu, Jul 5, 2012 at 10:01 AM, Camille Fournier <ca...@apache.org> wrote:
> There's nothing to prevent this as it stands, no, except user action. A
> lock file might not be a bad idea.
>
> C
>
> On Thu, Jul 5, 2012 at 12:53 PM, Will Johnson <wi...@attivio.com> wrote:
>
>> We recently ran into an issue where two zookeepers servers which were a
>> part of two separate quorums were configured to use the same data
>> directory.  Interestingly, the zookeeper servers did not seem to complain
>> and both seemed to work fine until one of them was restarted.  Once that
>> happened all sort of chaos ensued.  I understand that this is a
>> misconfiguration should zookeeper complain about this or do users need to
>> protect themselves in some external fashion?  Is a simple file lock enough
>> or are there other things I should take into consideration if it's up to me
>> to handle?
>>
>> I'm happy to file a jira for this as I didn't see any doc related to it
>> but I wanted to see if I missed something first.
>>
>>
>> -          will
>>

Re: multiple zookeepers - same data directory

Posted by Camille Fournier <ca...@apache.org>.
There's nothing to prevent this as it stands, no, except user action. A
lock file might not be a bad idea.

C

On Thu, Jul 5, 2012 at 12:53 PM, Will Johnson <wi...@attivio.com> wrote:

> We recently ran into an issue where two zookeepers servers which were a
> part of two separate quorums were configured to use the same data
> directory.  Interestingly, the zookeeper servers did not seem to complain
> and both seemed to work fine until one of them was restarted.  Once that
> happened all sort of chaos ensued.  I understand that this is a
> misconfiguration should zookeeper complain about this or do users need to
> protect themselves in some external fashion?  Is a simple file lock enough
> or are there other things I should take into consideration if it's up to me
> to handle?
>
> I'm happy to file a jira for this as I didn't see any doc related to it
> but I wanted to see if I missed something first.
>
>
> -          will
>