Return-Path: X-Original-To: apmail-cassandra-user-archive@www.apache.org Delivered-To: apmail-cassandra-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 2255CD4BD for ; Wed, 12 Dec 2012 18:07:39 +0000 (UTC) Received: (qmail 41887 invoked by uid 500); 12 Dec 2012 18:07:36 -0000 Delivered-To: apmail-cassandra-user-archive@cassandra.apache.org Received: (qmail 41863 invoked by uid 500); 12 Dec 2012 18:07:36 -0000 Mailing-List: contact user-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@cassandra.apache.org Delivered-To: mailing list user@cassandra.apache.org Received: (qmail 41855 invoked by uid 99); 12 Dec 2012 18:07:36 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Dec 2012 18:07:36 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,NORMAL_HTTP_TO_IP,RCVD_IN_DNSWL_LOW,SPF_PASS,WEIRD_PORT X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of santi.kumar@gmail.com designates 209.85.212.44 as permitted sender) Received: from [209.85.212.44] (HELO mail-vb0-f44.google.com) (209.85.212.44) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 12 Dec 2012 18:07:30 +0000 Received: by mail-vb0-f44.google.com with SMTP id fc26so1083051vbb.31 for ; Wed, 12 Dec 2012 10:07:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=fiBlPcNw4ziLSQK/OIP79kQdFXOZ0otbTHwJgPoDKuM=; b=jayQqYUUR7t5ElSV3BEuX25Wk56L2L+OuVBAY/hr3b/MxvCPU93AzIABQSiHperJVr NRTcVmZGEqz64XmhmuWYOUsa3K/RqpzdQcJQT5lSknw5G1CsSJDnDzmGKVUCFQlos3Go xnl8cIEMKwT3YhKrDuQeEmfcRYUXANGtEb6A/+/K4jZZ2Usy+trMzWJLSoQdJWh6F9CK vQikxudx9UpXfTlHGANNiQkZD81IYmwpNZOiovPvCSYZwnQDan0pBYZPW8ZV4ANKK1ml x7FBPp3EwOctOP1kIGmXrYG+lKwOhZf9uJIb1W7nN5I8JnOdB8+0lny0oARx2pZ5n4aV 5n6w== MIME-Version: 1.0 Received: by 10.220.149.69 with SMTP id s5mr1005195vcv.23.1355335629023; Wed, 12 Dec 2012 10:07:09 -0800 (PST) Received: by 10.58.249.10 with HTTP; Wed, 12 Dec 2012 10:07:08 -0800 (PST) In-Reply-To: References: <54C00DCA-A1FD-48AD-B90A-2251373465D0@thelastpickle.com> Date: Wed, 12 Dec 2012 23:37:08 +0530 Message-ID: Subject: Re: Cassandra on EC2 - describe_ring() is giving private IPs From: santi kumar To: user@cassandra.apache.org Content-Type: multipart/alternative; boundary=f46d042fd898b82a6204d0abaa96 X-Virus-Checked: Checked by ClamAV on apache.org --f46d042fd898b82a6204d0abaa96 Content-Type: text/plain; charset=ISO-8859-1 Yes That worked. Thanks for the pointer. Once the broadcast_address is pointed to public IP, end points are coming with public IP. so Hectors NodeAutoDiscoveryService matches with the existing host and not treating it as new node. On Wed, Dec 12, 2012 at 11:10 PM, Andrey Ilinykh wrote: > It makes sense. rpc_address is interface to listen. Try to set up public > IP to broadcast_address. > > Andrey > > > On Wed, Dec 12, 2012 at 9:33 AM, santi kumar wrote: > >> When I configured rpc_address with public IP, cassandra is not starting >> up. It's trowing 'unable to create thrift socket on . When I >> changed it to private IP, it was good. >> >> java.lang.RuntimeException: Unable to create thrift socket to / >> 107.21.80.94:9160 >> at >> org.apache.cassandra.thrift.CassandraDaemon$ThriftServer.(CassandraDaemon.java:148) >> at >> org.apache.cassandra.thrift.CassandraDaemon.startServer(CassandraDaemon.java:76) >> at >> org.apache.cassandra.service.AbstractCassandraDaemon.startRPCServer(AbstractCassandraDaemon.java:300) >> at >> org.apache.cassandra.service.AbstractCassandraDaemon.start(AbstractCassandraDaemon.java:272) >> at >> org.apache.cassandra.service.AbstractCassandraDaemon.activate(AbstractCassandraDaemon.java:369) >> at >> org.apache.cassandra.thrift.CassandraDaemon.main(CassandraDaemon.java:107) >> Caused by: org.apache.thrift.transport.TTransportException: Could not >> create ServerSocket on address /107.21.80.94:9160. >> at >> org.apache.cassandra.thrift.TCustomServerSocket.(TCustomServerSocket.java:80) >> at >> org.apache.cassandra.thrift.CassandraDaemon$ThriftServer.(CassandraDaemon.java:141) >> >> >> >> On Wed, Dec 12, 2012 at 3:34 AM, aaron morton wrote: >> >>> Though I configured the listen_address with public dns, still I had the >>> same issue. >>> >>> Internally the public DNS resolves to the private IP. >>> >>> looks like describe_ring() is the one which provides the details. >>> >>> describe_ring() returns includes the registered RPC addresses for the >>> nodes. Trying setting the rpc_address to the public IP. >>> >>> Cheers >>> >>> ----------------- >>> Aaron Morton >>> Freelance Cassandra Developer >>> New Zealand >>> >>> @aaronmorton >>> http://www.thelastpickle.com >>> >>> On 11/12/2012, at 11:32 PM, santi kumar wrote: >>> >>> We have a 4 node cluster in us-east region in two different AZ's. >>> Clients connect to this cluster from our datacenter which is not on AWS. >>> >>> Hector clients are initialized with public DNS names, then >>> listern_address is with private ip and rpc_address is with 0.0.0.0. >>> >>> Having issues with Node Auto Discovery by Hector. When it's trying to >>> discover the ring, the end points are initialized with private IP's for all >>> Token Ranges. It checks with the existing hosts (which are initialized >>> public DNS) and thinks that there is a new node got added to the cluster. >>> >>> looks like describe_ring() is the one which provides the details. Though >>> I configured the listen_address with public dns, still I had the same >>> issue. >>> >>> Any idea, what is the best way to configure for EC2. Have gone through >>> the link >>> >>> https://docs.google.com/document/d/175duUNIx7m5mCDa2sjXVI04ekyMa5bdiWdu-AFgisaY/edit?hl=en >>> >>> But not sure whether it's fixed in 1.1.4. When I run the nodetool ring, >>> it gives the private ips. But in the above doc, it shows the public IPs as >>> part of nodetool ring. >>> >>> Some insight into this is really helpful. >>> >>> Thanks >>> Santi >>> >>> >>> >> > --f46d042fd898b82a6204d0abaa96 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Yes That worked. Thanks for the pointer. Once the broadcast_address is poin= ted to public IP, end points are coming with public IP. so Hectors NodeAuto= DiscoveryService matches with the existing host and not treating it as new = node.

On Wed, Dec 12, 2012 at 11:10 PM, Andrey Ili= nykh <ailinykh@gmail.com> wrote:
It makes sense. rpc_address is interface to listen. Try to set up public IP= to broadcast_address.
<= br>
Andrey


On Wed, Dec 1= 2, 2012 at 9:33 AM, santi kumar <santi.kumar@gmail.com> = wrote:
When I configured rpc_address with public IP= , cassandra is not starting up. It's trowing 'unable to create thri= ft socket on <public IP>. When I changed it to private IP, it was goo= d.

java.lang.RuntimeException: Unable to create thrift socket to /107.21.80.94:9160
=A0=A0=A0=A0=A0=A0=A0 at org.apache.cassandra.thrift.CassandraDaemon$Thrift= Server.<init>(CassandraDaemon.java:148)
=A0=A0=A0=A0=A0=A0=A0 at o= rg.apache.cassandra.thrift.CassandraDaemon.startServer(CassandraDaemon.java= :76)
=A0=A0=A0=A0=A0=A0=A0 at org.apache.cassandra.service.AbstractCassa= ndraDaemon.startRPCServer(AbstractCassandraDaemon.java:300)
=A0=A0=A0=A0=A0=A0=A0 at org.apache.cassandra.service.AbstractCassandraDaem= on.start(AbstractCassandraDaemon.java:272)
=A0=A0=A0=A0=A0=A0=A0 at org.= apache.cassandra.service.AbstractCassandraDaemon.activate(AbstractCassandra= Daemon.java:369)
=A0=A0=A0=A0=A0=A0=A0 at org.apache.cassandra.thrift.Ca= ssandraDaemon.main(CassandraDaemon.java:107)
Caused by: org.apache.thrift.transport.TTransportException: Could not creat= e ServerSocket on address /107.21.80.94:9160.
=A0=A0=A0=A0=A0=A0=A0 at org.apache.cassan= dra.thrift.TCustomServerSocket.<init>(TCustomServerSocket.java:80) =A0=A0=A0=A0=A0=A0=A0 at org.apache.cassandra.thrift.CassandraDaemon$Thrift= Server.<init>(CassandraDaemon.java:141)



On Wed, Dec 12, 2012 at 3:34 AM, aaron morton <a= aron@thelastpickle.com> wrote:
Though I configured the listen_address with public d= ns, still I had the same issue.=A0
Internally the public DNS resolves to the private IP.=A0

looks like describe_ring() is the one= which provides the details.=A0
describe_ring() returns i= ncludes the registered RPC addresses for the nodes. Trying setting the rpc_= address to the public IP.

Cheers

-----------------
Aaron Morton
Freelance Cassandra= Developer
New Zealand


On 11/12/2012, at 11:32 PM, santi kumar <santi.kumar@gmail.com> wro= te:

We have a 4 node cluster in us-east = region in two different AZ's.=20 Clients connect to this cluster from our datacenter which is not on AWS.

Hector clients are initialized with public DNS names, then listern_= address is with private ip and rpc_address is with 0.0.0.0.

Having issues with Node Auto Discovery by Hector. When it's=20 trying to discover the ring, the end points are initialized with private IP's for all Token Ranges. It checks with the existing hosts (which ar= e initialized public DNS) and thinks that there is a new node got added=20 to the cluster.=20

looks like describe_ring() is the one which provides the=20 details. Though I configured the listen_address with public dns, still I had the same issue.

Any idea, what is the best way to configure for EC2. Have gone thro= ugh the link
https:= //docs.google.com/document/d/175duUNIx7m5mCDa2sjXVI04ekyMa5bdiWdu-AFgisaY/e= dit?hl=3Den

But not sure whether it's fixed in 1.1.4. When I run the nodetool ring, it= =20 gives the private ips. But in the above doc, it shows the public IPs as=20 part of nodetool ring.=20

Some insight into this is really helpful.

Thanks
Santi




--f46d042fd898b82a6204d0abaa96--