Return-Path: X-Original-To: apmail-zookeeper-user-archive@www.apache.org Delivered-To: apmail-zookeeper-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 2A81810F93 for ; Sun, 1 Sep 2013 08:27:53 +0000 (UTC) Received: (qmail 60532 invoked by uid 500); 1 Sep 2013 08:27:51 -0000 Delivered-To: apmail-zookeeper-user-archive@zookeeper.apache.org Received: (qmail 60464 invoked by uid 500); 1 Sep 2013 08:27:43 -0000 Mailing-List: contact user-help@zookeeper.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@zookeeper.apache.org Delivered-To: mailing list user@zookeeper.apache.org Delivered-To: moderator for user@zookeeper.apache.org Received: (qmail 93539 invoked by uid 99); 31 Aug 2013 05:09:52 -0000 X-ASF-Spam-Status: No, hits=2.2 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of finchavenue@hotmail.com designates 65.55.116.108 as permitted sender) X-TMN: [jBZJOThyekq/enim25MZ5Qz82f1u8UZO] X-Originating-Email: [finchavenue@hotmail.com] Message-ID: From: Yi Jiang To: Subject: zookeeper on ec2 problem Date: Sat, 31 Aug 2013 01:09:26 -0400 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_00CD_01CEA5E6.BC5325F0" X-Mailer: Microsoft Outlook 15.0 Thread-Index: Ac6mBpQVpzF9wjypT1io/+NCPBe2Tw== Content-Language: zh-cn X-OriginalArrivalTime: 31 Aug 2013 05:09:26.0777 (UTC) FILETIME=[43CCD690:01CEA608] X-Virus-Checked: Checked by ClamAV on apache.org ------=_NextPart_000_00CD_01CEA5E6.BC5325F0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi, Everyone,=20 I am recently setting up zookeeper on ec2 I have followed the suggestion that using the internal ip of ec2, but it = still shows up the error: =20 root@ip-172-31-15-65:/home/yjiang/zookeeper-3.4.5/bin# ./zkServer.sh = status JMX enabled by default Using config: /home/yjiang/zookeeper-3.4.5/bin/../conf/zoo.cfg Error contacting service. It is probably not running. =20 But the instance is running in the background. Then when I use the ./zkCli.sh =E2=80=93server server-ip:2181 command, = it shows below =20 =20 root@ip-172-31-15-65:/home/yjiang/zookeeper-3.4.5/bin# ./zkCli.sh = -server ip-172-31-15-68.us-west-2.compute.internal:2181 Connecting to ip-172-31-15-68.us-west-2.compute.internal:2181 2013-08-31 05:05:45,823 [myid:] - INFO [main:Environment@100] - Client = environment:zookeeper.version=3D3.4.5-1392090, built on 09/30/2012 17:52 = GMT 2013-08-31 05:05:45,833 [myid:] - INFO [main:Environment@100] - Client = environment:host.name=3Dip-172-31-15-65.us-west-2.compute.internal 2013-08-31 05:05:45,833 [myid:] - INFO [main:Environment@100] - Client = environment:java.version=3D1.7.0_25 2013-08-31 05:05:45,834 [myid:] - INFO [main:Environment@100] - Client = environment:java.vendor=3DOracle Corporation 2013-08-31 05:05:45,835 [myid:] - INFO [main:Environment@100] - Client = environment:java.home=3D/usr/lib/jvm/java-7-oracle/jre 2013-08-31 05:05:45,836 [myid:] - INFO [main:Environment@100] - Client = environment:java.class.path=3D/home/yjiang/zookeeper-3.4.5/bin/../build/c= lasses:/home/yjiang/zookeeper-3.4.5/bin/../build/lib/*.jar:/home/yjiang/z= ookeeper-3.4.5/bin/../lib/slf4j-log4j12-1.6.1.jar:/home/yjiang/zookeeper-= 3.4.5/bin/../lib/slf4j-api-1.6.1.jar:/home/yjiang/zookeeper-3.4.5/bin/../= lib/netty-3.2.2.Final.jar:/home/yjiang/zookeeper-3.4.5/bin/../lib/log4j-1= .2.15.jar:/home/yjiang/zookeeper-3.4.5/bin/../lib/jline-0.9.94.jar:/home/= yjiang/zookeeper-3.4.5/bin/../zookeeper-3.4.5.jar:/home/yjiang/zookeeper-= 3.4.5/bin/../src/java/lib/*.jar:/home/yjiang/zookeeper-3.4.5/bin/../conf:= /usr/lib/jvm/java-7-oracle/lib 2013-08-31 05:05:45,837 [myid:] - INFO [main:Environment@100] - Client = environment:java.library.path=3D/usr/java/packages/lib/amd64:/usr/lib64:/= lib64:/lib:/usr/lib 2013-08-31 05:05:45,837 [myid:] - INFO [main:Environment@100] - Client = environment:java.io.tmpdir=3D/tmp 2013-08-31 05:05:45,838 [myid:] - INFO [main:Environment@100] - Client = environment:java.compiler=3D 2013-08-31 05:05:45,839 [myid:] - INFO [main:Environment@100] - Client = environment:os.name=3DLinux 2013-08-31 05:05:45,839 [myid:] - INFO [main:Environment@100] - Client = environment:os.arch=3Damd64 2013-08-31 05:05:45,840 [myid:] - INFO [main:Environment@100] - Client = environment:os.version=3D3.2.0-40-virtual 2013-08-31 05:05:45,841 [myid:] - INFO [main:Environment@100] - Client = environment:user.name=3Droot 2013-08-31 05:05:45,842 [myid:] - INFO [main:Environment@100] - Client = environment:user.home=3D/root 2013-08-31 05:05:45,842 [myid:] - INFO [main:Environment@100] - Client = environment:user.dir=3D/home/yjiang/zookeeper-3.4.5/bin 2013-08-31 05:05:45,845 [myid:] - INFO [main:ZooKeeper@438] - = Initiating client connection, = connectString=3Dip-172-31-15-68.us-west-2.compute.internal:2181 = sessionTimeout=3D30000 = watcher=3Dorg.apache.zookeeper.ZooKeeperMain$MyWatcher@3b8a9e64 Welcome to ZooKeeper! 2013-08-31 05:05:45,898 [myid:] - INFO = [main-SendThread(ip-172-31-15-68.us-west-2.compute.internal:2181):ClientC= nxn$SendThread@966] - Opening socket connection to server = ip-172-31-15-68.us-west-2.compute.internal/172.31.15.68:2181. Will not = attempt to authenticate using SASL (unknown error) JLine support is enabled [zk: ip-172-31-15-68.us-west-2.compute.internal:2181(CONNECTING) 0] = 2013-08-31 05:06:15,920 [myid:] - INFO = [main-SendThread(ip-172-31-15-68.us-west-2.compute.internal:2181):ClientC= nxn$SendThread@1083] - Client session timed out, have not heard from = server in 30040ms for sessionid 0x0, closing socket connection and = attempting reconnect 2013-08-31 05:06:17,024 [myid:] - INFO = [main-SendThread(ip-172-31-15-68.us-west-2.compute.internal:2181):ClientC= nxn$SendThread@966] - Opening socket connection to server = ip-172-31-15-68.us-west-2.compute.internal/172.31.15.68:2181. Will not = attempt to authenticate using SASL (unknown error) 2013-08-31 05:06:47,052 [myid:] - INFO = [main-SendThread(ip-172-31-15-68.us-west-2.compute.internal:2181):ClientC= nxn$SendThread@1083] - Client session timed out, have not heard from = server in 31028ms for sessionid 0x0, closing socket connection and = attempting reconnect 2013-08-31 05:06:48,154 [myid:] - INFO = [main-SendThread(ip-172-31-15-68.us-west-2.compute.internal:2181):ClientC= nxn$SendThread@966] - Opening socket connection to server = ip-172-31-15-68.us-west-2.compute.internal/172.31.15.68:2181. Will not = attempt to authenticate using SASL (unknown error) It seems take forever to connect. =20 I did setup everything according to docs, I don=E2=80=99t know what I = did wrong. The following is my conf file, and the myid is in the dataDir folder =20 # The number of milliseconds of each tick tickTime=3D2000 # The number of ticks that the initial # synchronization phase can take initLimit=3D10 # The number of ticks that can pass between # sending a request and getting an acknowledgement syncLimit=3D5 # the directory where the snapshot is stored. # do not use /tmp for storage, /tmp here is just # example sakes. dataDir=3D/home/yjiang/zookeeper/data/zk2 # the port at which the clients will connect clientPort=3D2181 server.1=3Dip-172-31-15-68.us-west-2.compute.internal:2888:3888 server.2=3Dlocalhost:2888:3888 server.3=3Dip-172-31-15-67.us-west-2.compute.internal:2888:3888 #server.4=3Dip-172-31-15-66.us-west-2.compute.internal:2888:3888 #server.5=3Dip-172-31-26-18.us-west-2.compute.internal:2888:3888 # # Be sure to read the maintenance section of the # administrator guide before turning on autopurge. # # = http://zookeeper.apache.org/doc/current/zookeeperAdmin.html#sc_maintenanc= e # # The number of snapshots to retain in dataDir #autopurge.snapRetainCount=3D3 # Purge task interval in hours # Set to "0" to disable auto purge feature #autopurge.purgeInterval=3D1 =20 FYI I have added the port 2181, 2888 and 3888 to my firewalls in all = machines. I even disabled the firewall in all machines, it still = doesn=E2=80=99t work Please help me Thanks a lot. =20 Jacky =20 ------=_NextPart_000_00CD_01CEA5E6.BC5325F0--