Create "default-cassandra" security group with following Inbound rules:
22/TCP to 0.0.0.0 or private ip
7000/TCP to {public IPs of all nodes in cluster}
7001/TCP to {public IPs of all nodes in cluster}
7199/TCP to {public IPs of all nodes in cluster}
9160/TCP to default-cassandra
9042/TCP to 0.0.0.0
Create instance with security group "default-cassandra"
Install Apache Cassandra 3.7 on Ubuntu
$ sudo apt-get dist-upgrade
$ sudo add-apt-repository ppa:webupd8team/java
$ sudo apt-get update
$ sudo apt-get install oracle-java8-set-default
$ java -version
$ echo " deb http://www.apache.org/dist/cassandra/debian 37x main" | sudo tee -a /etc/apt/sources.list.d/cassandra.sources.list
$ echo " deb-src http://www.apache.org/dist/cassandra/debian 37x main" | sudo tee -a /etc/apt/sources.list.d/cassandra.sources.list
$ gpg --keyserver pgp.mit.edu --recv-keys F758CE318D77295D
$ gpg --export --armor F758CE318D77295D | sudo apt-key add -
$ gpg --keyserver pgp.mit.edu --recv-keys 2B5C1B00
$ gpg --export --armor 2B5C1B00 | sudo apt-key add -
$ gpg --keyserver pgp.mit.edu --recv-keys 0353B12C
$ gpg --export --armor 0353B12C | sudo apt-key add -
$ sudo apt-get update
$ sudo apt-get install cassandra
$ sudo service cassandra status
$ sudo nodetool status
$ cqlsh
$ sudo service cassandra stop
$ sudo vi /etc/cassandra/cassandra.yaml
> cluster_name: {Cluster Name}
> seeds: {List of Public IP Addresses, i.e. if cluster size is 3 nodes, put 2 here}
> authenticator: PasswordAuthenticator
> listen_address:
> broadcast_address: {Public IP}
> rpc_address: 0.0.0.0
> broadcast_rpc_address: {Public IP}
$ sudo rm -rf /var/lib/cassandra/data/system/*
$ sudo service cassandra start
$ tail -f /var/log/cassandra/system.log
$ sudo nodetool status
$ cqlsh -u cassandra -p cassandra
[REMOTE MACHINE] $ cqlsh {IP Address} -u cassandra -p cassandra
[CQL] ALTER KEYSPACE system_auth WITH REPLICATION = { 'class' : 'SimpleStrategy', 'replication_factor' : 3 };
[CQL] CREATE USER {username} WITH PASSWORD {password} SUPERUSER;
[CQL] DROP USER cassandra;
nodetool repair -pr -- system_auth