Hi, I have spent a few hours getting zookeeper election to work on debian squeeze.
The zookeeper log contained the following error when trying to run an election: 2010-08-16 11:14:51,316 - WARN [WorkerSender Thread:quorumcnxmana...@361] - Cannot open channel to 2 at election address vm-024-squeeze-mw/ 172.30.30.67:3888 java.net.SocketException: Network is unreachable at sun.nio.ch.Net.connect(Native Method) at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:525) at java.nio.channels.SocketChannel.open(SocketChannel.java:164) at org.apache.zookeeper.server.quorum.QuorumCnxManager.connectOne(QuorumCnxManager.java:347) at org.apache.zookeeper.server.quorum.QuorumCnxManager.toSend(QuorumCnxManager.java:320) at org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.process(FastLeaderElection.java:353) at org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.run(FastLeaderElection.java:326) at java.lang.Thread.run(Thread.java:636) Looking at netstat output, each server was running the listener on the tcpv6 interface only, and I don't think that my network can handle this. The solution was to disable ipv6 on my servers. In /etc/default/grub add the line: GRUB_CMDLINE_LINUX="ipv6.disable=1" and then run "update-grub" and reboot. This fixed the problem. I am surprised that zookeeper (3.3.1) did not bind to all interfaces. Will the new clientPortBindHostAddress config support a specification that can distinguish between tcpv4 and tcpv6 if both are available ? Also, will an equivalent electionPortBindHostAddress be provided ? regards, Martin