0

I'm doing this for the very first time and I need help about clearing some stuffs. I have Ubuntu 14.04 desktop on one machine, and on the other I have Windows 8.1. also on both machines I have installed the same version of Cassandra.

Can someone tell me, is it possible to connect 2 desktop machines and make a cluster with 2 nodes in Cassandra and how?

iMajna
  • 489
  • 4
  • 28

1 Answers1

2

You need make sure the following settings are set correctly in the cassandra.yaml on each machine:

  1. cluster_name - this needs to be the same on both nodes
  2. seed_provider.parameters.seeds - this needs to be set to the external IP address of one of the nodes and needs to be the same on both nodes.
  3. listen_address - this needs to be set to the external IP address on each machine.

Note: Make sure you can ping each machine from the other on the IP address you use for the listen_address and make sure that the storage_port 7000 isn't blocked by a firewall on either machine.

mikea
  • 6,537
  • 19
  • 36
  • "seed_provider.parameters.seeds -needs to be set to the external IP address **of one of the nodes**. But what if the both machines are on the same network (I'm just testing replication on two computers on the same network) than the external IP will be the same, am I right? Than my **-seeds: " "** will have only one IP, and that IP will be the external one? And, do I need to set listen_address to my wlan driver IPv4 address like 192.168._._ ? – iMajna Aug 02 '16 at 13:37
  • Each machine must have it's own unique IP address. The seed is used for initial gossip negotiation by the cluster so needs to be the same on both nodes but can be the IP addresses of both machines if you want. You need to be using addresses that you connect to the machine externally from. – mikea Aug 02 '16 at 15:04
  • I set on each machine cassandra.yaml for seed other machine unq IP. Also I changed for every machine **listen_address** to unq IP. Also in cassandra-env.sh also changed JVM_OPTS to the unq IP address of machine where that file it is. Am I now missing something or? Because when I type **nodetool status** I can't see other machine rack – iMajna Aug 02 '16 at 15:17
  • The seed address needs to be same on both machines. – mikea Aug 03 '16 at 08:54
  • I typed IP address of an Ubuntu and Windows in for seed attribute, is it ok? Also, as the both machines are on the same network I used IPv4 address (got with **ipconfig** for wlan driver) of each desktop as IP address, is that ok? – iMajna Aug 03 '16 at 09:08