How to install Cassandra in Ubuntu Server 12.04?

Installation of Cassandra in the Ubuntu Server 12.04 can be performed in multiple ways. In this article, I will focus on utilizing the ‘apt-get’ command line utility to install ‘Cassandra’. This information is also documented at the ‘Cassanda Wiki’.

Please note that its recommended to have ‘Oracle JDK at-least version 6’ installed in the machine before installing Cassandra.

Step 1: Add the required repositories.

sudo echo "deb 11x main" >> /etc/apt/sources.list;
sudo echo "deb-src 11x main" >> /etc/apt/sources.list

Step 2: Update.

sudo apt-get update

Step 3: If you see a GPG Error indicating failure to verify signatures, add the PUBLIC_KEY by executing the below commands:

gpg --keyserver --recv-keys F758CE318D77295D;
gpg --export --armor F758CE318D77295D | sudo apt-key add -

Step 4: Issue sudo apt-get update again and verify if you hit the GPG signature verification error again. If yes, you may need to add another PUBLIC_KEY using the commands listed below:

gpg --keyserver --recv-keys 2B5C1B00;
gpg --export --armor 2B5C1B00 | sudo apt-key add -

Step 5: Issue the sudo apt-get update again and if the command is successful, install Cassandra using;

sudo apt-get install cassandra

If the last command completes successfully, Cassandra should be running in your machine.



Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

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