[ 
https://issues.apache.org/jira/browse/BOOKKEEPER-619?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13686528#comment-13686528
 ] 

Ivan Kelly commented on BOOKKEEPER-619:
---------------------------------------

It's mostly a usability thing. I've been caught out by this a couple of times 
and I've seen others caught by it as well. The problem is that you extract the 
tarball on a server, try to run a bookie without running the format command. 
This is a mistake, so you run the metaformat. Then you run the bookieformat, 
and it warns you that you're about to destroy data (i.e. the cookie that was 
created in the previous run). This is confusing, and awkward. In fact, the only 
reason you need to run the bookieformat is because the previous run created the 
cookies. If, on a clean cluster you run metaformat and then just start the 
bookie, you have the same effect.

The purpose this this patch is to avoid this confusing situation. If you run a 
bookie against a nonformatted metadata, it doesn't put up any new barriers to 
running it again once metadata is formatted.
                
> Bookie should not create local cookie files if zookeeper is uninitialized
> -------------------------------------------------------------------------
>
>                 Key: BOOKKEEPER-619
>                 URL: https://issues.apache.org/jira/browse/BOOKKEEPER-619
>             Project: Bookkeeper
>          Issue Type: Bug
>    Affects Versions: 4.2.1
>            Reporter: Ivan Kelly
>            Assignee: Ivan Kelly
>             Fix For: 4.2.2, 4.3.0
>
>         Attachments: 
> 0001-BOOKKEEPER-619-Bookie-should-not-create-local-cookie.patch
>
>
> If you download a distribution of bookkeeper-4.2.1 and try to start the 
> bookie before initializing zookeeper, then the bookie will fail to start, but 
> write the local cookie files with a null instance id. If you then initialize 
> zookeeper with the "bin/bookkeeper shell metaformat", you will not be able to 
> start the bookie as instance id of in zk will not match the null instance id 
> in the bookie files.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to