Differences between revisions 24 and 25
Revision 24 as of 2011-10-18 12:07:37
Size: 2685
Comment:
Revision 25 as of 2012-04-24 13:51:12
Size: 2685
Comment:
Deletions are marked like this. Additions are marked like this.
Line 6: Line 6:
deb http://www.apache.org/dist/cassandra/debian 10x main
deb-src http://www.apache.org/dist/cassandra/debian 10x main
deb http://www.apache.org/dist/cassandra/debian 11x main
deb-src http://www.apache.org/dist/cassandra/debian 11x main
Line 10: Line 10:
You will want to replace `08x` by the series you want to use: `08x for the 0.8.x series, 07x for the 0.7.x series, etc... It does mean that you will not get major version update unless you change the series, but that is ''a feature''. You will want to replace `08x` by the series you want to use: `10x for the 1.0.x series, 08x for the 0.8.x series, etc... It does mean that you will not get major version update unless you change the series, but that is ''a feature''.

Official Debian Package

To install on Debian or Debian derivatives, use the following sources:

deb http://www.apache.org/dist/cassandra/debian 11x main
deb-src http://www.apache.org/dist/cassandra/debian 11x main

You will want to replace 08x by the series you want to use: `10x for the 1.0.x series, 08x for the 0.8.x series, etc... It does mean that you will not get major version update unless you change the series, but that is a feature.

If you run apt-get update now, you will see an error similar to this:

GPG error: http://www.apache.org unstable Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY F758CE318D77295D

This simply means you need to add the PUBLIC_KEY. You do that like this:

gpg --keyserver pgp.mit.edu --recv-keys F758CE318D77295D
gpg --export --armor F758CE318D77295D | sudo apt-key add -

Starting with the 0.7.5 debian package, you will also need to add public key 2B5C1B00 using the same commands as above:

gpg --keyserver pgp.mit.edu --recv-keys 2B5C1B00
gpg --export --armor 2B5C1B00 | sudo apt-key add -

(The list of Apache contributors public keys is available at http://www.apache.org/dist/cassandra/KEYS).

Then you may install Cassandra by doing:

sudo apt-get update
sudo apt-get install cassandra

Some things to be aware of:

  • The configuration files are located in /etc/cassandra
  • Start-up options (heap size, etc) can be configured in /etc/default/cassandra

Building Packages on Debian

Once all the build dependencies are set up, all you need to do is run

dpkg-buildpackage -uc -us

Troubleshooting:

Make sure you are building with the Sun JDK, not OpenJDK, and not gcj. You want to see something like this:

# java -version
java version "1.6.0_20"
Java(TM) SE Runtime Environment (build 1.6.0_20-b02)
Java HotSpot(TM) Client VM (build 16.3-b01, mixed mode, sharing)

By default, installing the Cassandra Debian package or its build dependencies will pull in OpenJDK. For runtime purposes this will work fine, but due to an issue with the packaging of OpenJDK in Lenny (see http://bugs.debian.org/501487), building the package from source will fail. If you need to (re)build the package on Lenny, install sun-java6-jdk before-hand (sun-java6-jdk provides java6-sdk which satisfies the dependency), or use the alternatives system to change the default compiler afterward.

sudo update-alternatives --config javac

Note: See also CASSANDRA-1575.

DebianPackaging (last edited 2016-09-23 06:01:28 by MichaelShuler)