incubator-cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Shuler <mich...@pbandjelly.org>
Subject Re: 答复: How to configure linux service for Cassandra?
Date Tue, 03 Dec 2013 02:43:39 GMT
On 12/02/2013 03:43 PM, Kumar Ranjan wrote:
> Hey Folks,
> 
> I have been using ccm for some time and it's pretty awesome tool to test
> out admin stuff. Now, I really want to test modeling data by trying to
> access ccm running cassandra using Thrift based pycassaShell client from
> remote hosts (not locally). My setup is like this:

In your case, since the ccm cluster nodes are bound to localhost
aliases, you would need to set up routing and port forwarding via
iptables from your public IP (10.11.12.13) to the respective localhost
aliases/ports.  ccm is great for local testing, but gets to be a pain if
you wish to do some real testing - not because of ccm, but because now
you want to do something that involves actual multi-host networking with
remote access.  Even easier, in my opinion; if you really want to begin
testing a real cluster with remote access, which will have a lot more
horsepower than everything on localhost via ccm, then spend $15/month on
3x $5/mo. digitalocean nodes.

> How to connect to any of the instance from non-local hosts? When I do:
> 
> pycassaShell --host 10.11.12.13 --port 9160, it throws an exception,
> 
> 
> thrift.transport.TTransport.TTransportException: Could not connect to
> 10.11.12.13:9160

Yup.  The nodes are not listening to anything but their localhost alias
IP addresses.

> Is there a way to make it work?

`man iptables`  ;)

-- 
Kind regards,
Michael

Mime
View raw message