DevTech101

DevTech101

Process to install and Configure a 3 Node Cassandra Cluster

Casandra Ports and layouts

  • 7199 – JMX (was 8080 pre Cassandra 0.8.xx)
  • 7000 – Internode communication (not used if TLS enabled)
  • 7001 – TLS Internode communication (used if TLS enabled)
  • 9160 – Thrift client API
  • 9042 – CQL native transport port

Source

Installing Casandra

First install the below packages

Install x86.32 bit for linux
Install java 1.8 – test with java to make its available used
rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
yum -y install ntp libyaml sysstat

Node 1 options

Server options:
Installation Directory: /usr/share/dse
Cassandra Data Directory: /data/cassandra/data
Cassandra Logs Directory: /var/log
Cassandra Commitlog Directory: /data/cassandra/commitlog
Cassandra Saved Caches Dir: /data/cassandra/saved_caches
Server Name: Cluster1
Enable VNodes: 1
Listen Address: 10.10.10.101
RPC Address: 10.10.10.101
Seeds: 10.10.10.101,10.10.10.103
Storage Port: 7000
SSL Storage Port: 7001
RPC Port: 9160
Cassandra User: cassandra
Cassandra Group: cassandra
Do Drain: 1

DSE options:
Node Type: cassandra
Analytics Type:
Press [Enter] to continue:

Install in System Locations: services_and_utilities
General options:
Install in System Locations: services_and_utilities
Start Services After Install: 1
Install Type: advanced
Product Type: dse
sudo Command:
Is Upgrade: 0
Is Root: 1
Package Upgrade: 0
Update System: 1
Original User Running installer: dse

Press [Enter] to continue:

Node 2 options

Server options:
Installation Directory: /usr/share/dse
Cassandra Data Directory: /data/cassandra/data
Cassandra Logs Directory: /var/log
Cassandra Commitlog Directory: /data/cassandra/commitlog
Cassandra Saved Caches Dir: /data/cassandra/saved_caches
Server Name: Cluster1
Enable VNodes: 1
Listen Address: 10.10.10.102
RPC Address: 10.10.10.102
Seeds: 10.10.10.101,10.10.10.103
Storage Port: 7000
SSL Storage Port: 7001
RPC Port: 9160
Cassandra User: cassandra
Cassandra Group: cassandra
Do Drain: 1

DSE options:
Node Type: cassandra
Analytics Type:

Install in System Locations: services_and_utilities
Start Services After Install: 1
Install Type: advanced
Product Type: dse
sudo Command:
Is Upgrade: 0
Is Root: 1
Package Upgrade: 0
Update System: 1
Press [Enter] to continue:
Original User Running installer: dse

Node 3 options

Server options:
Installation Directory: /usr/share/dse
Cassandra Data Directory: /data/cassandra/data
Cassandra Logs Directory: /var/log
Cassandra Commitlog Directory: /data/cassandra/commitlog
Cassandra Saved Caches Dir: /data/cassandra/saved_caches
Server Name: Cluster1
Enable VNodes: 1
Listen Address: 10.10.10.103
RPC Address: 10.10.10.103
Seeds: 10.10.10.101,10.10.10.103
Storage Port: 7000
SSL Storage Port: 7001
RPC Port: 9160
Cassandra User: cassandra
Cassandra Group: cassandra
Do Drain: 1

DSE options:
Press [Enter] to continue:
Node Type: cassandra
Analytics Type:

Ops Cenetr install

General options:
Install in System Locations: services_only
Start Services After Install: 1
Install Type: advanced
Product Type: opscenter
sudo Command:
Is Upgrade: 1
Is Root: 1
Package Upgrade: 0
Update System: 1
Original User Running installer: dse

Press [Enter] to continue:
OpsCenter options:
OpsCenter Installation Directory: /usr/share/opscenter

To configure Ops Center to not try to connect to internet (which causes slowness)

Modify the below file

/usr/share/opscenter/conf/opscenterd.conf
[...] snip
[definitions]
auto_update=False

To test cassandra

cassandra-cli --host cassandra3 --port 9160

cassandra JVM settings

Modify the below files

/etc/datastax-agent/datastax-agent-env.sh

Ops center config file

/usr/share/opscenter/conf/opscenterd.conf

# opscenterd.conf

[jmx]
port = 7199

[webserver]
port=8888
#interface=10.10.10.101
interface=0.0.0.0
# The following settings can be used to enable ssl support for the opscenter
# web application. Change these values to point to the ssl certificate and key
# that you wish to use for your OpsCenter install, as well as the port you would like
# to serve ssl traffic from.
#ssl_keyfile = /var/lib/opscenter/ssl/opscenter.key
#ssl_certfile = /var/lib/opscenter/ssl/opscenter.pem
#ssl_port = 8443

log_path=/var/log/opscenter/opscenterd-httpd.log
[logging]
# level may be TRACE, DEBUG, INFO, WARN, or ERROR
#level = INFO
log_path=/var/log/opscenter/opscenterd.log

[cassandra]
#seed_hosts=10.10.10.101,10.10.10.103
seed_hosts=10.10.10.103
api_port=9160

[authentication]
# Set this option to True to enable OpsCenter authentication.  A default admin
# account will be created with the username "admin" and password "admin".
# Accounts and roles can then be created and modified from within the web UI.
enabled=False

# To help us better understand the needs of users and to improve OpsCenter, OpsCenter
# reports information about itself and the clusters it manages to a central DataStax
# server.  This information is reported anonymously, and potentially sensitive
# information, such as IP addresses, are hashed in a non-reversible way:
# http://www.datastax.com/documentation/opscenter/help/statsReporterProperties.html
[stat_reporter]
# The interval setting determines how often statistics are reported.  To disable
# reporting, set to 0
# interval = 86400 # 24 hours
[repair_service]
log_directory=/var/log/opscenter/repair_service/

## Add by Eli Kleinman
[definitions] 
auto_update=False

Issue with Ops Center agent

Remove old agent “datastax-agent-5.1.3-standalone.jar” from /usr/share/datastax-agent

Now restart the agent

restart the agent
service datastax-agent restart
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
%d bloggers like this: