zookeeper-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Thilo-Alexander Ginkel <th...@ginkel.com>
Subject Strange zoo.cfg.dynamic.next generated via zookeeper Docker image
Date Wed, 15 Jul 2020 21:43:04 GMT
Hi there,

I am running a three-node Zookeeper cluster based on the official
zookeeper Docker image (currently at v3.6.1). I have been seeing
sporadic problems during a rolling restart where the ensemble often
loses its integrity requiring all nodes to be stopped and restarted to
recover.

The containers are connected to the bridge network, so I need to
replace each node's own IP with 0.0.0.0 in the server declaration, as
in (for server #1):

ZOO_MY_ID=1
ZOO_SERVERS=server.1=0.0.0.0:2888:3888:participant;2181 \
  server.2=x.x.x.2:2888:3888:participant;2181 \
  server.3=x.x.x.3:2888:3888:participant;2181

Server #2, #3 have their IP replaced with 0.0.0.0, respectively.

>From this configuration Zookeeper seems to generate the following
zoo.cfg.dynamic.next config file (identical on all three servers),
which is somewhat surprising as it contains 0.0.0.0 as address of
server #2:

-- 8< --
server.1=x.x.x.1:2888:3888:participant;0.0.0.0:2181
server.2=0.0.0.0:2888:3888:participant;0.0.0.0:2181
server.3=x.x.x.3:2888:3888:participant;0.0.0.0:2181
version=1f00000000
-- 8< --

Is this how things are supposed to be? Naively, I would have assumed
that server #1/#3 should know the real ip of server #2 and not
0.0.0.0...

Is there a way to configure an advertised address? If not, what is the
recommended setup to operate Zookeeper within Docker (without having
to resort to using the host network)?

Thanks,
Thilo

Mime
View raw message