Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-24 Thread Daniel van Ham Colchete
Himanshi, you could try adding your public IP address to an internal interface and DNAT the packets to it. This shouldn't give you any problems with your normal traffic. Tell Cassandra on listen on the public IPs and it should work. Linux commands would be: # Create an internal interface using

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-24 Thread Himanshi Sharma
Thanks Daniel. But SNAT command is not working and when i try tcpdump it gives [root@ip-10-136-75-201 ~]# tcpdump -i 50.18.60.117 -n port 7000 tcpdump: Invalid adapter index Not able to figure out wats this ?? Thanks, Himanshi From: Daniel van Ham Colchete daniel.colch...@gmail.com To:

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-24 Thread Daniel van Ham Colchete
Himanshi, my bad, try this for iptables: # SNAT outgoing connections iptables -t nat -A POSTROUTING -p tcp --dport 7000 -d 175.41.143.192 -j SNAT --to-source INTERNALIP As for tcpdump the argument for the -i option is the interface name (eth0, cassth0, etc...), and not the IP. So, it should be

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-24 Thread Dave Viner
Another possibility is this: why not setup 2 nodes in 1 region in 1 az, and get that to work. Then, open a third node in the same region, but different AZ, and get that to work. Then, once you have that working, open a fourth node in a different region and get that to work. Seems like taking a

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-24 Thread Frank LoVecchio
Not sure if there is a particular reason for you using different regions, but Amazon states that each zone is a different physical location completely separate from others, e.g. us-east-1a and us-east-1b. Using the Amazon internal IPs (10.x. etc) reduces latency greatly by not going outbound

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Himanshi Sharma
Thanks Dave but I am able to telnet to other instances on port 7000 and when i run ./nodetool --host ec2-50-18-60-117.us-west-1.compute.amazonaws.com ring... I can see only one node. Do we need to configure anything else in Cassandra.yaml or Cassandra-env.sh ??? From: Dave Viner

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Sasha Dolgy
did you define the other host in the cassandra.yaml ? on both servers they need to know about each other On Wed, Feb 23, 2011 at 10:16 AM, Himanshi Sharma himanshi.sha...@tcs.comwrote: Thanks Dave but I am able to telnet to other instances on port 7000 and when i run ./nodetool --host

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Himanshi Sharma
Ya they do. Have specified Public DNS in seed field of each node in Cassandra.yaml...nt able to figure out what the problem is ??? From: Sasha Dolgy sdo...@gmail.com To: user@cassandra.apache.org Date: 02/23/2011 02:56 PM Subject: Re: Cassandra nodes on EC2 in two different regions not

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Dave Viner
Try using the IP address, not the dns name in the cassandra.yaml. If you can telnet from one to the other on port 7000, and both nodes have the other node in their config, it should work. Dave Viner On Wed, Feb 23, 2011 at 1:43 AM, Himanshi Sharma himanshi.sha...@tcs.comwrote: Ya they do.

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Frank LoVecchio
The internal Amazon IP address is what you will want to use so you don't have to go through DNS anyways; not sure if this works from US-East to US-West, but it does make things quicker in between zones, e.g. us-east-1a to us-east-1b. On Wed, Feb 23, 2011 at 9:09 AM, Dave Viner davevi...@gmail.com

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Peter Fales
I posted on this topic last September. (See http://www.mail-archive.com/user@cassandra.apache.org/msg05692.html) I was able to use Cassandra across EC2regions. However, the trick is that you have must use the external addresses in your storage-conf.xml, but since you don't have a NIC that

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Himanshi Sharma
Hi Dave, Thanks for ur reply..I tried using elastics ips. And below is the configuration of the cassandra.yaml in both the nodes. seeds: - 50.18.60.117 - 175.41.143.192 Now when i run cassandra i get following exception INFO 04:30:56,680 Heap size: 878116864/879165440 INFO

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Dave Viner
That looks like it's not an issue of communicating between nodes. It appears that the node can not bind to the address on the localhost that you're asking for. java.net.BindException: Cannot assign requested address I think the issue is that the Elastic IP address is not actually an IP address

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Himanshi Sharma
Hi Dave, I tried with the public ips. If i mention the public ip in rpc address field, Cassandra gives the same exceptionbut if leave it blank then Cassandra runs but again in the nodetool command with ring option it does'nt show the node in another region. Thanks, Himanshi-Dave Viner

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Dave Viner
Try using the private ipv4 address in the rpc_address field, and the public ipv4 (NOT the elastic ip) in the listen_address. If that fails, go back to rpc_address empty, and start up cassandra. Then from the other node, please telnet to port 7000 on the first node. And show the output of that

Re: Cassandra nodes on EC2 in two different regions not communicating

2011-02-23 Thread Himanshi Sharma
giving private ip to rpc address gives the same exception and the keeping it blank and providing public to listen also fails. I tried keeping both blank and did telnet on 7000 so i get following o/p [root@ip-10-166-223-150 bin]# telnet 122.248.193.37 7000Trying 122.248.193.37...Connected to

Cassandra nodes on EC2 in two different regions not communicating

2011-02-22 Thread Himanshi Sharma
Hi, I am new to Cassandra. I m running Cassandra on EC2. I configured Cassandra cluster on two instances in different regions. But when I am trying the nodetool command with ring option, I am getting only single node. How to make these two nodes communicate with each other. I have already