Verify that you can connect from each of the ZK hosts to all of the others
on the necessary three ports.  Make sure you use the right names so you test
your DNS configuration as well.

It looks from your logs like you can't.

On Wed, Sep 23, 2009 at 2:41 AM, Le Zhou <lezhouy...@gmail.com> wrote:

> Hi,
> I'm trying to install HBase 0.20.0 in fully distributed mode on my cluster.
> As HBase depends on Zookeeper, I have to know first how to make Zookeeper
> work.
> I download the release 3.2.1 and install it on each machine in my cluster.
>
> Zookeeper in standalone mode works well on each machine in my cluster. I
> follow the "Zookeeper Getting Started Guide" and get expected output. Then
> I
> come to the "Running replicated zookeeper"
>
> On each machine in my cluster(debian-0, debian-1, debian-5), I append the
> following lines to zoo.cfg, and create in dataDir a "myid" which contains
> the server id(1 for debian-0, 2 for debian-1, 3 for debian-5).
>
> server.1=debian-0:2888:3888
> server.2=debian-1:2888:3888
> server.3=debian-5:2888:3888
>
> then I start zookeeper server by "running bin/zkServer.sh start", and I got
> the following output:
>
> cl...@debian-0:~/zookeeper$ bin/zkServer.sh start
> JMX enabled by default
> Using config: /home/cloud/zookeeper-3.2.1/bin/../conf/zoo.cfg
> Starting zookeeper ...
> STARTED
> cl...@debian-0:~/zookeeper$ 2009-09-23 15:30:27,976 - INFO
>  [main:quorumpeercon...@80] - Reading configuration from:
> /home/cloud/zookeeper-3.2.1/bin/../conf/zoo.cfg
> 2009-09-23 15:30:27,981 - INFO  [main:quorumpeercon...@232] - Defaulting
> to
> majority quorums
> 2009-09-23 15:30:28,009 - INFO  [main:quorumpeerm...@118] - Starting
> quorum
> peer
> 2009-09-23 15:30:28,034 - INFO  [Thread-1:quorumcnxmanager$liste...@409] -
> My election bind port: 3888
> 2009-09-23 15:30:28,045 - INFO
>  [QuorumPeer:/0:0:0:0:0:0:0:0:2181:quorump...@487] - LOOKING
> 2009-09-23 15:30:28,070 - INFO
>  [QuorumPeer:/0:0:0:0:0:0:0:0:2181:fastleaderelect...@579] - New election:
> -1
> 2009-09-23 15:30:28,075 - INFO
>  [QuorumPeer:/0:0:0:0:0:0:0:0:2181:fastleaderelect...@618] - Notification:
> 1, -1, 1, 1, LOOKING, LOOKING, 1
> 2009-09-23 15:30:28,075 - WARN  [WorkerSender Thread:quorumcnxmana...@336]
> -
> Cannot open channel to 2 at election address debian-1/172.20.53.86:3888
> java.net.ConnectException: Connection refused
> at sun.nio.ch.Net.connect(Native Method)
> at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:507)
> at java.nio.channels.SocketChannel.open(SocketChannel.java:146)
> at
>
> org.apache.zookeeper.server.quorum.QuorumCnxManager.connectOne(QuorumCnxManager.java:323)
> at
>
> org.apache.zookeeper.server.quorum.QuorumCnxManager.toSend(QuorumCnxManager.java:302)
> at
>
> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.process(FastLeaderElection.java:323)
> at
>
> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.run(FastLeaderElection.java:296)
> at java.lang.Thread.run(Thread.java:619)
> 2009-09-23 15:30:28,085 - INFO
>  [QuorumPeer:/0:0:0:0:0:0:0:0:2181:fastleaderelect...@642] - Adding vote
> 2009-09-23 15:30:28,099 - WARN  [WorkerSender Thread:quorumcnxmana...@336]
> -
> Cannot open channel to 3 at election address debian-5/172.20.14.194:3888
> java.net.ConnectException: Connection refused
> at sun.nio.ch.Net.connect(Native Method)
> at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:507)
> at java.nio.channels.SocketChannel.open(SocketChannel.java:146)
> at
>
> org.apache.zookeeper.server.quorum.QuorumCnxManager.connectOne(QuorumCnxManager.java:323)
> at
>
> org.apache.zookeeper.server.quorum.QuorumCnxManager.toSend(QuorumCnxManager.java:302)
> at
>
> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.process(FastLeaderElection.java:323)
> at
>
> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.run(FastLeaderElection.java:296)
> at java.lang.Thread.run(Thread.java:619)
> 2009-09-23 15:30:28,288 - WARN
>  [QuorumPeer:/0:0:0:0:0:0:0:0:2181:quorumcnxmana...@336] - Cannot open
> channel to 2 at election address debian-1/172.20.53.86:3888
> java.net.ConnectException: Connection refused
> at sun.nio.ch.Net.connect(Native Method)
> at sun.nio.ch.SocketChannelImpl.connect(SocketChannelImpl.java:507)
> at java.nio.channels.SocketChannel.open(SocketChannel.java:146)
> at
>
> org.apache.zookeeper.server.quorum.QuorumCnxManager.connectOne(QuorumCnxManager.java:323)
> at
>
> org.apache.zookeeper.server.quorum.QuorumCnxManager.connectAll(QuorumCnxManager.java:356)
> at
>
> org.apache.zookeeper.server.quorum.FastLeaderElection.lookForLeader(FastLeaderElection.java:603)
> at org.apache.zookeeper.server.quorum.QuorumPeer.run(QuorumPeer.java:488)
>
> Terminal keeps on outputing the WARN info until I stop the zookeeper
> Server.
>
> I googled "zookeeper cannot open channel to at address" and searched in
> mailing list archives, but got nothing helpful.
>
> I need your help, thanks and best regards!
>



-- 
Ted Dunning, CTO
DeepDyve

Reply via email to