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 04:30:56,684 JNA not found. Native methods will be disabled.
 INFO 04:30:56,691 Loading settings from 
file:/opt/cassandra/apache-cassandra-0.7.0/conf/cassandra.yaml
 INFO 04:30:56,898 DiskAccessMode 'auto' determined to be standard, 
indexAccessMode is standard
 INFO 04:30:57,092 Creating new commitlog segment 
/var/lib/cassandra/commitlog/CommitLog-1298521857092.log
 INFO 04:30:57,265 reading saved cache 
/var/lib/cassandra/saved_caches/system-IndexInfo-KeyCache
 INFO 04:30:57,270 reading saved cache 
/var/lib/cassandra/saved_caches/system-Schema-KeyCache
 INFO 04:30:57,305 Opening /var/lib/cassandra/data/system/Schema-e-2
 INFO 04:30:57,315 Opening /var/lib/cassandra/data/system/Schema-e-1
 INFO 04:30:57,326 reading saved cache 
/var/lib/cassandra/saved_caches/system-Migrations-KeyCache
 INFO 04:30:57,327 Opening /var/lib/cassandra/data/system/Migrations-e-2
 INFO 04:30:57,331 Opening /var/lib/cassandra/data/system/Migrations-e-1
 INFO 04:30:57,412 reading saved cache 
/var/lib/cassandra/saved_caches/system-LocationInfo-KeyCache
 INFO 04:30:57,413 Opening 
/var/lib/cassandra/data/system/LocationInfo-e-65
 INFO 04:30:57,416 Opening 
/var/lib/cassandra/data/system/LocationInfo-e-67
 INFO 04:30:57,421 Opening 
/var/lib/cassandra/data/system/LocationInfo-e-66
 INFO 04:30:57,427 reading saved cache 
/var/lib/cassandra/saved_caches/system-HintsColumnFamily-KeyCache
 INFO 04:30:57,454 Loading schema version 
f13dfb89-3db9-11e0-8bbe-e700f669bcfc
 WARN 04:30:57,831 Schema definitions were defined both locally and in 
cassandra.yaml. Definitions in cassandra.yaml were ignored.
 INFO 04:30:57,841 reading saved cache 
/var/lib/cassandra/saved_caches/AddressBook-Himanshi-KeyCache
 INFO 04:30:57,842 Opening 
/var/lib/cassandra/data/AddressBook/Himanshi-e-1
 INFO 04:30:57,854 Replaying 
/var/lib/cassandra/commitlog/CommitLog-1298521699165.log
 INFO 04:30:57,854 Finished reading 
/var/lib/cassandra/commitlog/CommitLog-1298521699165.log
 INFO 04:30:57,855 Log replay complete
 INFO 04:30:57,981 Cassandra version: 0.7.0
 INFO 04:30:57,981 Thrift API version: 19.4.0
 INFO 04:30:57,989 Loading persisted ring state
 INFO 04:30:58,025 Starting up server gossip
 INFO 04:30:58,046 switching in a fresh Memtable for LocationInfo at 
CommitLogContext(file='/var/lib/cassandra/commitlog/CommitLog-1298521857092.log',
 
position=148)
 INFO 04:30:58,047 Enqueuing flush of Memtable-LocationInfo@22845412(29 
bytes, 1 operations)
 INFO 04:30:58,047 Writing Memtable-LocationInfo@22845412(29 bytes, 1 
operations)
 INFO 04:30:58,425 Completed flushing 
/var/lib/cassandra/data/system/LocationInfo-e-68-Data.db (149 bytes)
 INFO 04:30:58,426 Compacting 
[org.apache.cassandra.io.sstable.SSTableReader(path='/var/lib/cassandra/data/system/LocationInfo-e-65-Data.db'),org.apache.cassandra.io.sstable.SSTableReader(path='/var/lib/cassandra/data/system/LocationInfo-e-66-Data.db'),org.apache.cassandra.io.sstable.SSTableReader(path='/var/lib/cassandra/data/system/LocationInfo-e-67-Data.db'),org.apache.cassandra.io.sstable.SSTableReader(path='/var/lib/cassandra/data/system/LocationInfo-e-68-Data.db')]
ERROR 04:30:58,513 Exception encountered during startup.
java.net.BindException: Cannot assign requested address
        at sun.nio.ch.Net.bind(Native Method)
        at 
sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
        at 
sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
        at 
sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
        at 
org.apache.cassandra.net.MessagingService.listen(MessagingService.java:181)
        at 
org.apache.cassandra.service.StorageService.initServer(StorageService.java:334)
        at 
org.apache.cassandra.service.AbstractCassandraDaemon.setup(AbstractCassandraDaemon.java:161)
        at 
org.apache.cassandra.thrift.CassandraDaemon.setup(CassandraDaemon.java:55)
        at 
org.apache.cassandra.service.AbstractCassandraDaemon.activate(AbstractCassandraDaemon.java:217)
        at 
org.apache.cassandra.thrift.CassandraDaemon.main(CassandraDaemon.java:134)
Exception encountered during startup.
java.net.BindException: Cannot assign requested address
        at sun.nio.ch.Net.bind(Native Method)
        at 
sun.nio.ch.ServerSocketChannelImpl.bind(ServerSocketChannelImpl.java:126)
        at 
sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:59)
        at 
sun.nio.ch.ServerSocketAdaptor.bind(ServerSocketAdaptor.java:52)
        at 
org.apache.cassandra.net.MessagingService.listen(MessagingService.java:181)
        at 
org.apache.cassandra.service.StorageService.initServer(StorageService.java:334)
        at 
org.apache.cassandra.service.AbstractCassandraDaemon.setup(AbstractCassandraDaemon.java:161)
        at 
org.apache.cassandra.thrift.CassandraDaemon.setup(CassandraDaemon.java:55)
        at 
org.apache.cassandra.service.AbstractCassandraDaemon.activate(AbstractCassandraDaemon.java:217)
        at 
org.apache.cassandra.thrift.CassandraDaemon.main(CassandraDaemon.java:134)

 I am able to ping both the nodes through public ips.





From:
Dave Viner <davevi...@gmail.com>
To:
user@cassandra.apache.org
Date:
02/23/2011 11:01 PM
Subject:
Re: Cassandra nodes on EC2 in two different regions not communicating



internal EC2 ips (10.xxx.xxx.xxx) work across availability zones (e.g., 
from us-east-1a to us-east-1b) but do not work across regions (e.g., 
us-east to us-west).  To do regions, you must use the public ip address 
assigned by amazon.

Himanshi, when you log into 1 node, and telnet to port 7000 on the other 
node, which IP address did you use - the 10.x address or the public ip 
address?
And what is the seed/non-seed configuration in both cassandra.yaml files?

Dave Viner


On Wed, Feb 23, 2011 at 8:12 AM, Frank LoVecchio <fr...@isidorey.com> 
wrote:
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> wrote:
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.com> 
wrote:

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 communicating




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.com
> wrote: 

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 <davevi...@gmail.com> 
To: 
user@cassandra.apache.org 
Cc: 
Himanshi Sharma <himanshi.sha...@tcs.com> 
Date: 
02/23/2011 11:36 AM 
Subject: 
Re: Cassandra nodes on EC2 in two different regions not communicating





If you login to one of the nodes, can you telnet to port 7000 on the other 
node? 

If not, then almost certainly it's a firewall/Security Group issue. 

You can find out the security groups for any node by logging in, and then 
running: 

% curl "http://169.254.169.254/latest/meta-data/security-groups"; 

Assuming that both nodes are in the same security group, ensure that the 
SG is configured to allow other members of the SG to communicate on port 
7000 to each other. 

HTH, 
Dave Viner 


On Tue, Feb 22, 2011 at 8:59 PM, Himanshi Sharma <himanshi.sha...@tcs.com> 
wrote: 

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 
opened required ports. i.e 7000, 8080, 9160 in respective 
security groups. Plz help me with this. 

Regards, 
Himanshi Sharma 


=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain 
confidential or privileged information. If you are 

not the intended recipient, any dissemination, use, 
review, distribution, printing or copying of the 
information contained in this e-mail message 
and/or attachments to it are strictly prohibited. If 
you have received this communication in error, 

please notify us by reply e-mail or telephone and 
immediately and permanently delete the message 
and any attachments. Thank you




=====-----=====-----=====


Notice: The information contained in this e-mail
message and/or attachments to it may contain 
confidential or privileged information. If you are 
not the intended recipient, any dissemination, use, 
review, distribution, printing or copying of the 


information contained in this e-mail message 
and/or attachments to it are strictly prohibited. If 
you have received this communication in error, 
please notify us by reply e-mail or telephone and 
immediately and permanently delete the message 


and any attachments. Thank you





-- 
Sasha Dolgy
sasha.do...@gmail.com 

=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain 
confidential or privileged information. If you are 



not the intended recipient, any dissemination, use, 
review, distribution, printing or copying of the 
information contained in this e-mail message 
and/or attachments to it are strictly prohibited. If 
you have received this communication in error, 



please notify us by reply e-mail or telephone and 
immediately and permanently delete the message 
and any attachments. Thank you






-- 
Frank LoVecchio
Senior Software Engineer | Isidorey, LLC
Google Voice +1.720.295.9179
isidorey.com | facebook.com/franklovecchio | franklovecchio.com



=====-----=====-----=====
Notice: The information contained in this e-mail
message and/or attachments to it may contain 
confidential or privileged information. If you are 
not the intended recipient, any dissemination, use, 
review, distribution, printing or copying of the 
information contained in this e-mail message 
and/or attachments to it are strictly prohibited. If 
you have received this communication in error, 
please notify us by reply e-mail or telephone and 
immediately and permanently delete the message 
and any attachments. Thank you


Reply via email to