Installing DataStax Community on any Linux-based platform

Install on all Linux-based platforms, including Mac OSX and platforms without package support, or if you do not have or want a root installation.

DataStax no longer provides the DataStax Community version of Apache Cassandra™ or the DataStax Distribution of Apache Cassandra. See DataStax support for Apache Cassandra.
To download and install the latest version of open-source Cassandra, see https://cassandra.apache.org/.

Use these steps to install Cassandra on all Linux-based platforms using a binary tarball.

For a complete list of supported platforms, see Apache Cassandra.

Prerequisites

  • The latest version of Oracle Java SE Runtime Environment (JRE) 6 or 7. See Installing the JRE.
  • Java Native Access (JNA) is required for production installations. See Installing the JNA.
  • Python 2.6+ (needed if installing OpsCenter).
  • If you are using Ubuntu 10.04 LTS, you must update to JNA 3.4, as described in Installing the JNA using the binary tarball.
  • If you are using an older RHEL-based Linux distribution, such as CentOS-5, you may see the following error: GLIBCXX_3.4.9 not found. You must replace the Snappy compression/decompression library (snappy-java-1.0.5.jar) with the snappy-java-1.0.4.1.jar.

The binary tarball runs as a stand-alone process.

Procedure

In a terminal window:

  1. Check which version of Java is installed by running the following command:
    java -version
    Use the latest version of Java 6 or 7 on all nodes.
  2. Download the latest DataStax Community tarball:
    $ curl -OL http://downloads.datastax.com/community/dsc-1.2.tar.gz
  3. Unpack the distribution:
    $ tar -xvzf dsc-cassandra-1.2.x-bin.tar.gz
    $ rm *.tar.gz
  4. Go to the install directory:
    cd dsc-cassandra-1.2.x
  5. By default, Cassandra installs files into the /var/lib/cassandra and /var/log/cassandra directories. If you do not have root access to the default directories, ensure you have write access:
    $ sudo mkdir /var/lib/cassandra
    $ sudo mkdir /var/log/cassandra
    $ sudo chown -R  $USER: $GROUP /var/lib/cassandra
    $ sudo chown -R  $USER: $GROUP /var/log/cassandra

Results

The DataStax Community distribution of Cassandra is installed and ready for configuration.

What's next