Return-Path: Delivered-To: apmail-hadoop-zookeeper-user-archive@minotaur.apache.org Received: (qmail 78033 invoked from network); 22 Jun 2010 16:52:46 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 22 Jun 2010 16:52:46 -0000 Received: (qmail 98967 invoked by uid 500); 22 Jun 2010 16:52:46 -0000 Delivered-To: apmail-hadoop-zookeeper-user-archive@hadoop.apache.org Received: (qmail 98886 invoked by uid 500); 22 Jun 2010 16:52:45 -0000 Mailing-List: contact zookeeper-user-help@hadoop.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: zookeeper-user@hadoop.apache.org Delivered-To: mailing list zookeeper-user@hadoop.apache.org Received: (qmail 98878 invoked by uid 99); 22 Jun 2010 16:52:45 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Jun 2010 16:52:45 +0000 X-ASF-Spam-Status: No, hits=3.9 required=10.0 tests=AWL,FREEMAIL_FROM,FS_REPLICA,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of erik.shiken@gmail.com designates 209.85.211.199 as permitted sender) Received: from [209.85.211.199] (HELO mail-yw0-f199.google.com) (209.85.211.199) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Jun 2010 16:52:40 +0000 Received: by ywh37 with SMTP id 37so1481365ywh.2 for ; Tue, 22 Jun 2010 09:52:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=GY5pmET+Qwj577ySTAGGYwgGQg5tG8To8WpAC77L1xU=; b=Kt03k+hmz1kkYdVqIdGbVuEtTIAClnyBazaJACt69qrqqaEPxcn4XjQ/C5rsAO5I10 FpPZZSj2QOva0kjdv/rSF30HjYNTGxXxNtUnmONazgLwv9YAMG63+8cCPgeMdIOALfLE MY9f6ZpiO4yNbsJb1sibf7WyF8pBKnGh3qVlA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=if45Zol4druAefeBGd7+no1pquZFSyNCQ98GJt9N24WiwNyV+txRGl1H0Vl0nl7/rc 16e6+rGPM7jOSiT2kkJ9KG/K37nNRwCK06J16X6gidHTaB6XkCgnGYOgbmJvf4OgAq5a F4xxqYbwQigdPby1Ot10ieA6KKon/mK0aSfyA= MIME-Version: 1.0 Received: by 10.100.246.25 with SMTP id t25mr5414037anh.139.1277225536094; Tue, 22 Jun 2010 09:52:16 -0700 (PDT) Received: by 10.100.96.6 with HTTP; Tue, 22 Jun 2010 09:52:14 -0700 (PDT) In-Reply-To: <4C20DE56.9030806@apache.org> References: <4B83CC1C4332D647B3CEC2FEA18518CDCC4FB73E@hzmail07.WebEx.HZ> <4C20DE56.9030806@apache.org> Date: Tue, 22 Jun 2010 12:52:14 -0400 Message-ID: Subject: =?UTF-8?Q?Re=3A_=E7=AD=94=E5=A4=8D=3A_Starting_zookeeper_in_replicated_mode?= From: Erik Test To: Patrick Hunt Cc: zookeeper-user@hadoop.apache.org Content-Type: multipart/alternative; boundary=0016e68deb356082750489a13ee7 --0016e68deb356082750489a13ee7 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Patrick, I'm still fairly new to iptables. I've made changes to the iptables the way I think it should be but the connection is still refused from 151.1 to 151.2. This is what I have tried in the iptables on 151.1. 151.2's firewall is turned off. -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -p tcp --dport 3888 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -p tcp --dport 2888 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -p tcp --dport 2181 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -d 192.168.151.2 -s 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -d 192.168.151.2 -p tcp --sport 3888 -s 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -d 192.168.151.2 -p tcp --sport 2888 -s 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -d 192.168.151.2 -p tcp --sport 2181 -s 192.168.151.1 -j ACCEPT I also tried the iptable config below because the connection is being refused on 151.2:3888 but this isn't working either. -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -p tcp --dport 3888 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -p tcp --dport 2888 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -s 192.168.151.2 -p tcp --dport 2181 -d 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -d 192.168.151.2 -s 192.168.151.1 -j ACCEPT -A RH-Firewall-1-INPUT -i eth2 -p tcp --dport 3888 -d 192.168.151.2 -s 192.168.151.1 -j ACCEPT I think I read somewhere that ZK uses tcp for communications which is why I'm specifying that protocol. But shouldn't specifying comms between two IP addresses be good enough though? Erik On 22 June 2010 12:01, Patrick Hunt wrote: > There are 3 ports that need to be opened > > 1) the client port (btw client and servers) > 2/3) the quorum and election ports - only btw servers > > You are setting these three ports in your config file (clientport default= s > to 2181 iirc, unless you override) > > Patrick > > > On 06/22/2010 06:17 AM, Erik Test wrote: > >> Thanks for your help. The missing file issue is resolved. >> >> I was confused by how to start zookeeper because a firewall is blocking >> connections between nodes. The odd thing is hadoop can run on its own wi= th >> the configured iptables but doesn't work with zookeeper for some reason. >> The >> problem here is I can't turn off the firewall and need to configure the >> firewall so that zookeeper can work correctly. >> >> I'm going to work on the iptables to open connections needed by zookeepe= r. >> If any one knows of a way to do this or even just a link to configuring = an >> iptable with zookeeper in mind, I'd appreciate it. >> >> Thanks again for the help. >> Erik >> >> >> On 21 June 2010 20:56, Joe Zou wrote: >> >> Hi=EF=BC=9A >>> You miss the file. >>> the Caused by: java.lang.IllegalArgumentException: /var/zookeeper/myid >>> file >>> is missing >>> at >>> thanks >>> Joe Zou >>> -----=E9=82=AE=E4=BB=B6=E5=8E=9F=E4=BB=B6----- >>> =E5=8F=91=E4=BB=B6=E4=BA=BA: Erik Test [mailto:erik.shiken@gmail.com] >>> =E5=8F=91=E9=80=81=E6=97=B6=E9=97=B4: Tuesday, June 22, 2010 3:05 AM >>> =E6=94=B6=E4=BB=B6=E4=BA=BA: zookeeper-user@hadoop.apache.org >>> =E4=B8=BB=E9=A2=98: Starting zookeeper in replicated mode >>> >>> Hi All, >>> >>> I'm having a problem with installing zookeeper on a cluster with 6 node= s >>> in >>> replicated mode. I was able to install and run zookeeper in standalone >>> mode >>> but I'm unable to run zookeeper in replicated mode. >>> >>> I've added a list of servers in zoo.cfg as suggested by the ZooKeeper >>> Getting Started Guide but I get these logs displayed to screen: >>> >>> *[root@master1 bin]# ./zkServer.sh start >>> JMX enabled by default >>> Using config: /root/zookeeper-3.2.2/bin/../conf/zoo.cfg >>> Starting zookeeper ... >>> STARTED >>> [root@master1 bin]# 2010-06-21 12:25:23,738 - INFO >>> [main:QuorumPeerConfig@80] - Reading configuration from: >>> /root/zookeeper-3.2.2/bin/../conf/zoo.cfg >>> 2010-06-21 12:25:23,743 - INFO [main:QuorumPeerConfig@232] - Defaultin= g >>> to >>> majority quorums >>> 2010-06-21 12:25:23,745 - FATAL [main:QuorumPeerMain@82] - Invalid >>> config, >>> exiting abnormally >>> org.apache.zookeeper.server.quorum.QuorumPeerConfig$ConfigException: >>> Error >>> processing /root/zookeeper-3.2.2/bin/../conf/zoo.cfg >>> at >>> >>> >>> org.apache.zookeeper.server.quorum.QuorumPeerConfig.parse(QuorumPeerCon= fig.java:100) >>> at >>> >>> >>> org.apache.zookeeper.server.quorum.QuorumPeerMain.initializeAndRun(Quor= umPeerMain.java:98) >>> at >>> >>> >>> org.apache.zookeeper.server.quorum.QuorumPeerMain.main(QuorumPeerMain.j= ava:75) >>> Caused by: java.lang.IllegalArgumentException: /var/zookeeper/myid file >>> is >>> missing >>> at >>> >>> >>> org.apache.zookeeper.server.quorum.QuorumPeerConfig.parseProperties(Quo= rumPeerConfig.java:238) >>> at >>> >>> >>> org.apache.zookeeper.server.quorum.QuorumPeerConfig.parse(QuorumPeerCon= fig.java:96) >>> ... 2 more >>> Invalid config, exiting abnormally* >>> >>> And here is my config file: >>> * >>> # The number of milliseconds of each tick >>> tickTime=3D2000 >>> # The number of ticks that the initial >>> # synchronization phase can take >>> initLimit=3D5 >>> # The number of ticks that can pass between >>> # sending a request and getting an acknowledgement >>> syncLimit=3D2 >>> # the directory where the snapshot is stored. >>> dataDir=3D/var/zookeeper >>> # the port at which the clients will connect >>> clientPort=3D2181 >>> server.1=3Dmaster1:2888:3888 >>> server.2=3Dslave2:2888:3888 >>> server.3=3Dslave3:2888:3888 >>> * >>> I'm a little confused as to why this doesn't work and I haven't had any >>> luck >>> finding answers to some questions I have. >>> >>> Am I supposed to have an instance of ZooKeeper on each node started >>> before >>> running in replication mode? Should I have each node that will be runni= ng >>> ZK >>> listed in the config file? Should I be using an IP address to point to = a >>> server instead of a hostname? >>> >>> Thanks for your time. >>> Erik >>> >>> >> --0016e68deb356082750489a13ee7--