This is the first of the multi part series on Cassandra. In each part I will cover one aspect amount setting up, managing and monitoring Cassandra on Amazon Web Services.
In this first part I will focus on the setup of Cassandra on AWS.
#Deployment Model
Cassandra will be set up as a multi-node cluster on AWS. AWS is spread over multiple regions and each region has multiple availability zones(AZ) within them.
Each region will start with at-least 3 nodes in a cluster. The nodes will be spread across different AZ’s. Most of the AWS regions have atleast 3 different AZ.
In regions where there are less than 3 AZ’s, two nodes will share the same AZ.
#Setup
##AWS
- Choose a region which has three availability zones. For the purpose of this post, I have choosen us-west-2.
- Spin up one EC2 instance in each availability zone.
- Databased should always be on private subnets of VPC and should not be open to internet.
-
Update the firewall setting on the secutiry group associated with the EC2 instance to allow incomming traffinc on the following ports:
9042 CQL Client port 7000 Inter node communication on cluster
##Installable
-
Download Cassandra 2.2.4V from the below URL.
http://downloads.datastax.com/community/dsc-cassandra-2.2.4-bin.tar.gz
- Unzip it to a location on the EC2 machine.
- Do this on all three nodes.
##Cassandra Configuration
Make the below changes in the files present in the
folder of Cassandra.1
/conf
1
File : cassandra-rackdc.properties
1
File : cassandra.yaml