Shared Health Record (EN)

Looking for help?
< All Topics
Print

Installing Cassandra

SHR and MCI Servers are using cassandra database. Cassandra can be installed as a single node cluster or multi-node cluster. In Local Environment it will installed as a two node cluster with replication factor 1. Below are the steps to Install cassandra.

Ansible establishes a SSH connection to install services on other machines with a given user (vagrant for local environments). Before installing services on a fresh boxes, it is recommended to perform a SSH from provisioner box to target box with vagrant user.

  1. Starting vagrant boxes:-
    1. Make sure vagrant boxes are up with the same IPs mentioned in inventories/local for cassandra_node, which is 192.168.33.19 192.168.33.20.
    2. Make sure there is cassandra_seed_node mentioned in inventories/local and that should be one of the above boxes.
  2. Go to Freeshr-Playbooks folder. Start and ssh into provisioner box from.
  3. Run below commands

    cd /vagrant/
    cp group_vars/all_example group_vars/all #make sure this is not commited
    touch ~/.vaultpass.txt #if not done before
    ansible-playbook cassandra.yml -i inventories/local -t cassandra  --vault-password-file ~/.vaultpass.txt -k -vvvv
  4. Cassandra should be running on both the boxes. You can login to cassandra cqlsh with below command.

    cqlsh <ip-address> -ucassandra -ppassword
Table of Contents