Software Development

How to install 3 popular NoSQL databases for development in MacOSX for newbies Part 2 (Cassandra)

In this post we will install on our local MacOSX (Yosemite) environment, another famous NoSQL database, the Apache Cassandra. As a developer, I found Datastax, community packaging of Cassandra, very handy, seems they offer ready made MacOSX specific packages.

You can of course download and install the the tarballs from Apache or use their virtual box images,  offered in the site.

We will be downloading Datastax Community Cassandra edition from here. The current version is 2.1.2, after downloading the tar.gz file, I will be extracting it, to a folder similar to the previous post of MongoDB. So my cassandra installation will be  under

\home\work\dsc-cassandra-2.1.2

Eventually that is all about (I assume you already have Java/JDK installed on your MacOSX). If not please check this post.

Your Cassandra folder should like the image below:

CapturFiles-Feb-01-2015_19.07.30

In order to start your test Cassandra cluster and nodes, just type the following

> cd \home\work\dsc-cassandra-2.2.1\bin\(or whatever is your path)

> ./cassandra -f

The -f switch will start the process in the foreground, so it would be easier for starters to shutdown the process by pressing Ctrl +C .

If you omit the -f, the process will start by default in the background and in order to stop you need to use the kill command and search for the process. More info here.

Well this is it, easy enough. When your cluster starts you should see something like the image below in your command line window.

CapturFiles-Feb-01-2015_19.13.33

What about a gui client for starters?

Well, Datastax offers a very handy client called DevCenter. 

Download the MacOSX, tar.gz, and extract it to a folder similar to the one, we extracted cassandra.

\home\work\Deventer\

Double click on the DevCenter.app . It is actually a tool based on Eclipse. Create a new connection as shown in the image below.

CapturFiles-Feb-01-2015_19.30.58
You can play around and create a DEMO keyspace as shown below.

CapturFiles-Feb-01-2015_19.34.33

You can find  a very simple intro post here.

Easy!

Paris Apostolopoulos

Paris is a senior software engineer focusing on J2EE development, loves Business process modelling and is keen on software quality challenges. He is passionate about Java and Java communities. He is a co-founder and administrator of the first Java User Group in greece(JHUG.gr) and occasional speaker on meet-ups and seminars and regular blogger. For his contributions and involvement on the Java community he has been awarded the title of Java Champion in 2007 by Sun Microsystems.
Subscribe
Notify of
guest

This site uses Akismet to reduce spam. Learn how your comment data is processed.

2 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
eyzwideshut
9 years ago

Good article explaining installation details. You should mention that DataStax DevCenter is not free for commercial use.

Alonso Isidoro Roman
8 years ago

Useful, thank you, i take this to my blog, i am going to translate it into spanish

Back to top button