Home / Articles / Database / datastax / 6.8.15 / cluster-setup

DataStax 3-Node Cluster Setup

Setup

  • Server Setup
  • ServerIP AddressSeed Node
    cassandra-1192.168.50.37seed node
    cassandra-2192.168.50.38
    cassandra-3192.168.50.39

  • Packages
  • PackageVersionInstall Location
    DataStax6.8.15/opt/dse-6.8.15
    Javajdk1.8.0_241/opt/jdk1.8.0_241
    Pythonpython-2.7.5-76.el7.x86_64/usr/bin/python

    Prerequisites

  • Install DSE on three servers using binary tarball.
  • Follow the steps in below document to complete DSE install on all three nodes. Do not start the DSE services yet.


    How to Install DSE Software

    Cluster Configuration

    • Update the cassandra configuration file for setting up 3-node cluster
    • # vi /opt/dse-6.8.15/resources/cassandra/conf/cassandra.yaml
      Node-1 Configuration cluster_name: 'LTS Cluster' num_tokens: 256 seeds: "192.168.50.37" listen_address: 192.168.50.37 endpoint_snitch: GossipingPropertyFileSnitch
      Node-2 Configuration cluster_name: 'LTS Cluster' num_tokens: 256 seeds: "192.168.50.37" listen_address: 192.168.50.38 endpoint_snitch: GossipingPropertyFileSnitch
      Node-3 Configuration cluster_name: 'LTS Cluster' num_tokens: 256 seeds: "192.168.50.37" listen_address: 192.168.50.39 endpoint_snitch: GossipingPropertyFileSnitch
    • Update the cassandra rack properties file to use custom datacenter name
    • Use the same parameters on all three nodes

      # vi /opt/dse-6.8.15/resources/cassandra/conf/cassandra-topology.properties 192.168.50.37=DC-Transactional:RAC1 192.168.50.38=DC-Transactional:RAC1 192.168.50.39=DC-Transactional:RAC1

    Start DSE Service

    • Login as cassandra user
    • Start DSE service on first node
    • # /opt/dse-6.8.15/bin/dse cassandra
    • Once DSE service is up then start DSE service on remaining two nodes

    DSE Service Status

    • Check status of DSE using nodetool command
    • # /opt/dse-6.8.15/bin/nodetool status # Datacenter: dc1 =============== Status=Up/Down |/ State=Normal/Leaving/Joining/Moving/Stopped -- Address Load Tokens Owns (effective) Host ID Rack UN 192.168.50.37 411.85 KiB 256 67.2% ddaf06c5-669d-4179-9863-6ec43a7323fa rack1 UN 192.168.50.38 428.47 KiB 256 65.8% df37112e-49c5-48e1-9088-00bfc639f98c rack1 UN 192.168.50.39 546.04 KiB 256 67.0% e1c6454d-ac77-42a4-b72b-07468dccdc1e rack1