Copy that. Thanks very much. Regards, ---- Da Ma (马达), PMP® | Advisory Software Engineer Platform Symphony & MapReduce Development & Support, STG, IBM GCG +86-10-8245 4084 | [email protected] | http://www.cguru.net
> On May 25, 2015, at 14:04, Michi Mutsuzaki <[email protected]> wrote: > > It can bind to 3888, but other servers can't connect to it since it's > a loopback address. > > On Sun, May 24, 2015 at 6:55 PM, Da Ma <[email protected]> wrote: >> Thanks, it’s worked after updating /etc/hosts. >> >> That’s interesting that cua02/127.0.0.1 is localhost, but it can not bind >> (3888) port on it. >> >> >> Regards, >> ---- >> Da Ma (马达), PMP® | Advisory Software Engineer >> Platform Symphony & MapReduce Development & Support, STG, IBM GCG >> +86-10-8245 4084 | [email protected] | http://www.cguru.net >> >>> On May 25, 2015, at 07:03, Michi Mutsuzaki <[email protected]> wrote: >>> >>> It looks like these hostnames are resolving to 127.0.0.1 locally. >>> >>>> 2015-05-24 17:35:40,439 [myid:2] - INFO [Thread >>>> 1:QuorumCnxManager$Listener@504] - My election bind port: >>>> cua02/127.0.0.1:3888 >>> >>> You can either configure zookeeper with ip addresses instead of >>> hostnames, or make sure these hostnames resolve to correct ip >>> addresses. >>> >>> >>> On Sun, May 24, 2015 at 5:08 AM, Da Ma <[email protected]> wrote: >>>> Hi team, >>>> >>>> I’m using openJDK 1.6 & 1.7, does zookeeper support them? >>>> >>>> Regards, >>>> ---- >>>> Da Ma (马达), PMP® | Advisory Software Engineer >>>> Platform Symphony & MapReduce Development & Support, STG, IBM GCG >>>> +86-10-8245 4084 | [email protected] | http://www.cguru.net >>>> >>>>> On May 24, 2015, at 17:53, Da Ma <[email protected]> wrote: >>>>> >>>>> Hi team, >>>>> >>>>> I’m a new player of ZooKeeper; when I following the steps in wiki to >>>>> start zookeeper with 3 hosts. It keep reporting the following exception; >>>>> >>>>> 2015-05-24 17:35:40,280 [myid:] - INFO [main:QuorumPeerConfig@103] - >>>>> Reading configuration from: /root/zookeeper-3.4.6/bin/../conf/zoo.cfg >>>>> 2015-05-24 17:35:40,292 [myid:] - INFO [main:QuorumPeerConfig@340] - >>>>> Defaulting to majority quorums >>>>> 2015-05-24 17:35:40,297 [myid:2] - INFO [main:DatadirCleanupManager@78] >>>>> - autopurge.snapRetainCount set to 3 >>>>> 2015-05-24 17:35:40,297 [myid:2] - INFO [main:DatadirCleanupManager@79] >>>>> - autopurge.purgeInterval set to 0 >>>>> 2015-05-24 17:35:40,298 [myid:2] - INFO [main:DatadirCleanupManager@101] >>>>> - Purge task is not scheduled. >>>>> 2015-05-24 17:35:40,312 [myid:2] - INFO [main:QuorumPeerMain@127] - >>>>> Starting quorum peer >>>>> 2015-05-24 17:35:40,336 [myid:2] - INFO [main:NIOServerCnxnFactory@94] - >>>>> binding to port 0.0.0.0/0.0.0.0:2181 >>>>> 2015-05-24 17:35:40,411 [myid:2] - INFO [main:QuorumPeer@959] - tickTime >>>>> set to 2000 >>>>> 2015-05-24 17:35:40,411 [myid:2] - INFO [main:QuorumPeer@979] - >>>>> minSessionTimeout set to -1 >>>>> 2015-05-24 17:35:40,411 [myid:2] - INFO [main:QuorumPeer@990] - >>>>> maxSessionTimeout set to -1 >>>>> [root@cua02 zookeeper-3.4.6]# head zookeeper.out -n 100 >>>>> 2015-05-24 17:35:40,280 [myid:] - INFO [main:QuorumPeerConfig@103] - >>>>> Reading configuration from: /root/zookeeper-3.4.6/bin/../conf/zoo.cfg >>>>> 2015-05-24 17:35:40,292 [myid:] - INFO [main:QuorumPeerConfig@340] - >>>>> Defaulting to majority quorums >>>>> 2015-05-24 17:35:40,297 [myid:2] - INFO [main:DatadirCleanupManager@78] >>>>> - autopurge.snapRetainCount set to 3 >>>>> 2015-05-24 17:35:40,297 [myid:2] - INFO [main:DatadirCleanupManager@79] >>>>> - autopurge.purgeInterval set to 0 >>>>> 2015-05-24 17:35:40,298 [myid:2] - INFO [main:DatadirCleanupManager@101] >>>>> - Purge task is not scheduled. >>>>> 2015-05-24 17:35:40,312 [myid:2] - INFO [main:QuorumPeerMain@127] - >>>>> Starting quorum peer >>>>> 2015-05-24 17:35:40,336 [myid:2] - INFO [main:NIOServerCnxnFactory@94] - >>>>> binding to port 0.0.0.0/0.0.0.0:2181 >>>>> 2015-05-24 17:35:40,411 [myid:2] - INFO [main:QuorumPeer@959] - tickTime >>>>> set to 2000 >>>>> 2015-05-24 17:35:40,411 [myid:2] - INFO [main:QuorumPeer@979] - >>>>> minSessionTimeout set to -1 >>>>> 2015-05-24 17:35:40,411 [myid:2] - INFO [main:QuorumPeer@990] - >>>>> maxSessionTimeout set to -1 >>>>> 2015-05-24 17:35:40,412 [myid:2] - INFO [main:QuorumPeer@1005] - >>>>> initLimit set to 10 >>>>> 2015-05-24 17:35:40,439 [myid:2] - INFO >>>>> [Thread-1:QuorumCnxManager$Listener@504] - My election bind port: >>>>> cua02/127.0.0.1:3888 >>>>> 2015-05-24 17:35:40,451 [myid:2] - INFO >>>>> [QuorumPeer[myid=2]/0:0:0:0:0:0:0:0:2181:QuorumPeer@714] - LOOKING >>>>> 2015-05-24 17:35:40,452 [myid:2] - INFO >>>>> [QuorumPeer[myid=2]/0:0:0:0:0:0:0:0:2181:FastLeaderElection@815] - New >>>>> election. My id = 2, proposed zxid=0x0 >>>>> 2015-05-24 17:35:40,466 [myid:2] - WARN >>>>> [WorkerSender[myid=2]:QuorumCnxManager@382] - Cannot open channel to 1 at >>>>> election address cua01/9.111.159.80:3888 >>>>> java.net.ConnectException: Connection refused >>>>> at java.net.PlainSocketImpl.socketConnect(Native Method) >>>>> at >>>>> java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) >>>>> at >>>>> java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) >>>>> at >>>>> java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) >>>>> at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) >>>>> at java.net.Socket.connect(Socket.java:579) >>>>> at >>>>> org.apache.zookeeper.server.quorum.QuorumCnxManager.connectOne(QuorumCnxManager.java:368) >>>>> at >>>>> org.apache.zookeeper.server.quorum.QuorumCnxManager.toSend(QuorumCnxManager.java:341) >>>>> at >>>>> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.process(FastLeaderElection.java:449) >>>>> at >>>>> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.run(FastLeaderElection.java:430) >>>>> at java.lang.Thread.run(Thread.java:745) >>>>> 2015-05-24 17:35:40,473 [myid:2] - INFO >>>>> [WorkerReceiver[myid=2]:FastLeaderElection@597] - Notification: 1 >>>>> (message format version), 2 (n.leader), 0x0 (n.zxid), 0x1 (n.round), >>>>> LOOKING (n.state), 2 (n.sid), 0x0 (n.peerEpoch) LOOKING (my state) >>>>> 2015-05-24 17:35:40,480 [myid:2] - WARN >>>>> [WorkerSender[myid=2]:QuorumCnxManager@382] - Cannot open channel to 3 at >>>>> election address cua03/9.111.159.76:3888 >>>>> java.net.ConnectException: Connection refused >>>>> at java.net.PlainSocketImpl.socketConnect(Native Method) >>>>> at >>>>> java.net.AbstractPlainSocketImpl.doConnect(AbstractPlainSocketImpl.java:339) >>>>> at >>>>> java.net.AbstractPlainSocketImpl.connectToAddress(AbstractPlainSocketImpl.java:200) >>>>> at >>>>> java.net.AbstractPlainSocketImpl.connect(AbstractPlainSocketImpl.java:182) >>>>> at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:392) >>>>> at java.net.Socket.connect(Socket.java:579) >>>>> at >>>>> org.apache.zookeeper.server.quorum.QuorumCnxManager.connectOne(QuorumCnxManager.java:368) >>>>> at >>>>> org.apache.zookeeper.server.quorum.QuorumCnxManager.toSend(QuorumCnxManager.java:341) >>>>> at >>>>> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.process(FastLeaderElection.java:449) >>>>> at >>>>> org.apache.zookeeper.server.quorum.FastLeaderElection$Messenger$WorkerSender.run(FastLeaderElection.java:430) >>>>> at java.lang.Thread.run(Thread.java:745) >>>>> >>>>> >>>>> Here’s my configuration: >>>>> [root@cua02 zookeeper-3.4.6]# cat conf/zoo.cfg >>>>> # The number of milliseconds of each tick >>>>> tickTime=2000 >>>>> # The number of ticks that the initial >>>>> # synchronization phase can take >>>>> initLimit=10 >>>>> # The number of ticks that can pass between >>>>> # sending a request and getting an acknowledgement >>>>> syncLimit=5 >>>>> # the directory where the snapshot is stored. >>>>> # do not use /tmp for storage, /tmp here is just >>>>> # example sakes. >>>>> dataDir=/var/lib/zookeeper/ >>>>> # the port at which the clients will connect >>>>> clientPort=2181 >>>>> # the maximum number of client connections. >>>>> # increase this if you need to handle more clients >>>>> #maxClientCnxns=60 >>>>> # >>>>> # Be sure to read the maintenance section of the >>>>> # administrator guide before turning on autopurge. >>>>> # >>>>> # >>>>> http://zookeeper.apache.org/doc/current/zookeeperAdmin.html#sc_maintenance >>>>> # >>>>> # The number of snapshots to retain in dataDir >>>>> #autopurge.snapRetainCount=3 >>>>> # Purge task interval in hours >>>>> # Set to "0" to disable auto purge feature >>>>> #autopurge.purgeInterval=1 >>>>> >>>>> >>>>> server.1=cua01:2888:3888 >>>>> server.2=cua02:2888:3888 >>>>> server.3=cua03:2888:3888 >>>>> >>>>> >>>>> The iptables service is stopped. >>>>> >>>>> And when I check the listening port, no 3888 on the host. >>>>> >>>>> Can anyone help me on this issue? >>>>> >>>>> Regards, >>>>> ---- >>>>> Da Ma (马达), PMP® | Advisory Software Engineer >>>>> Platform Symphony & MapReduce Development & Support, STG, IBM GCG >>>>> +86-10-8245 4084 | [email protected] | http://www.cguru.net >>>>> >>>> >>
