Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Apache Cassandra Essentials
Apache Cassandra Essentials

Apache Cassandra Essentials: Create your own massively scalable Cassandra database with highly responsive database queries

Arrow left icon
Profile Icon Nitin Padalia
Arrow right icon
zł157.99
Full star icon Full star icon Full star icon Full star icon Half star icon 4.5 (2 Ratings)
Paperback Nov 2015 172 pages 1st Edition
eBook
zł39.99 zł125.99
Paperback
zł157.99
Subscription
Free Trial
Arrow left icon
Profile Icon Nitin Padalia
Arrow right icon
zł157.99
Full star icon Full star icon Full star icon Full star icon Half star icon 4.5 (2 Ratings)
Paperback Nov 2015 172 pages 1st Edition
eBook
zł39.99 zł125.99
Paperback
zł157.99
Subscription
Free Trial
eBook
zł39.99 zł125.99
Paperback
zł157.99
Subscription
Free Trial

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Table of content icon View table of contents Preview book icon Preview Book

Apache Cassandra Essentials

Chapter 1. Getting Your Cassandra Cluster Ready

In this chapter, you'll learn how to set up and run our own Cassandra cluster. We'll look at the prerequisites that need to be considered before setting up a Cassandra cluster. We'll also see a Cassandra installation layout, so that we can easily locate different configuration files, tools, and utilities later on. We will discuss key configuration options that are required for cluster deployment. Then, we'll run our cluster and use Cassandra tools to verify our cluster status, some stats, and its version.

Installation

Apache provides source as well as binary tarballs and Debian packages. However, third-party vendors, such as Datastax, provide MSI installer, Linux RPM, Debian packages, and UNIX and Mac OS X binary in the form of community edition, which is a free packaged distribution of Apache Cassandra by Datastax. Here, we'll cover installation using binary tarball and source tarball packages.

Prerequisites

The following are the prerequisites for installing Cassandra:

  • Hardware requirements: Cassandra employs various caching techniques to enable ultra-fast read operations; hence more memory enables Cassandra to cache more data hence more memory would lead to better performance. Minimum 4GB memory is recommended for development environments and minimum 8GB memory for production environments. If our data set is bigger we should consider upgrading memory used by Cassandra. We'll discuss more about tuning Cassandra memory in later chapters. Similar to memory, more number of CPUs helps Cassandra to perform better as Cassandra performs its task concurrently. For bare-metal hardware, 8-core servers are recommended and for virtualized machines it's recommended that CPU cycles allocated to machines could grow on demand, for example some vendors like Rackspace and Amazon use CPU bursting. For development environments you could use single disk machine, however for production machines ideally there should be at least two disks. One disk is used for commitlog and other for storing data files called SSTables, so that I/O contention doesn't happen for both these operations. The commitlog file is used by Cassandra to make write requests durable. Every write request is first written to this file in append only mode and an in memory representation of column family called memtable.
  • Java: Cassandra can run on Oracle/Sun JVM, OpenJDK, and IBM JVM. The current stable version of Cassandra requires Java 7 or later version. Set your JAVA_HOME environment variable to the correct version of Java if you are using multiple Java versions on your machine.
  • Python: The current version of Cassandra requires Python 2.6 or above. Cassandra tools, such as cqlsh, are based on Python.
  • Firewall configurations: Since we are setting up a cluster, let's see which ports are used by Cassandra on various interfaces. If the firewall blocks these ports because we fail to configure them, then our cluster won't function properly. For example, if the internode communication port is being blocked, then nodes will not be able to join the cluster.

    Lets have a look at the following table

    Port/Protocol

    Configuration file

    Configuration name

    Firewall setting

    Description

    7000/tcp

    cassandra.yaml

    storage_port

    Open among nodes in the cluster

    It acts as an internode communication port in a Cassandra cluster.

    7001/tcp

    cassandra.yaml

    ssl_storage_port

    Open among nodes in the cluster

    It is a SSL port for encrypted communication among cluster nodes.

    9042/tcp

    cassandra.yaml

    native_transport_port

    Between the Cassandra client and the cluster

    Cassandra clients, for example cqlsh, or clients using the JAVA driver use this port to communicate with the Cassandra server.

    9160/tcp

    cassandra.yaml

    rpc_port

    The Thrift client and the Cassandra cluster

    Thrift uses this port for client connections.

    7199/tcp

    cassandra-env.sh

    JMX_PORT

    Between the JMX console and the Cassandra cluster

    It acts as an JMX console port for monitoring the Cassandra server.

  • Clock syncronization: Since Cassandra depends heavily on timestamps for data consistency purposes, all nodes of our cluster should be time synchronized. Ensure that we verify this. One of the methods we can use for time synchronization is configuring NTP on each node. NTP (Network Time Protocol) is widely used protocol for clock synchronization of computers over a network.

Compiling Cassandra from source and installing

The following method of installation is less used. One of the cases when we might use this method is if we're doing some optimization work on Cassandra. We'll need JDK 1.7, ANT 1.8, or later versions to compile the Cassandra code. Optionally, we can directly clone from the Cassandra Git repository or we can use the source tarball. Git client 1.7 will be required for cloning git repo.

To obtain the latest source code from Git, use the following command:

$ git clone http://git://git-wip-us.apache.org/repos/asf/cassandra.git Cassandra

For a specific branch, use the following command:

$ git clone -b cassandra-<version> http://git://git-wip-us.apache.org/repos/asf/cassandra.git

Use this command for version 1.2:

$ git clone -b cassandra-2.1.2 http://git://git-wip-us.apache.org/repos/asf/cassandra.git

Then, use the ant command to build the code:

$ ant

Alternatively, if a proxy is needed to connect to the Internet, use the autoproxy flag:

$ ant –autoproxy

or

$ export ANT_OPTS="-Dhttp.proxyHost=<your-proxy-host> -Dhttp.proxyPort=<your-proxy-port>"

Installation from a precompiled binary

Download a binary tarball from the Apache website; open it using the following command. Here, we will extract it in the /opt directory:

$ tar xzf apache-cassandra-<Version>.bin.tar.gz –C /opt

Consider the following example:

$ tar xzf apache-cassandra-2.1.2.bin.tar.gz –C /opt

Optionally, you can create a soft link as a best practice, which will help in scenarios where you need to change the installation location:

$ ln –s apache-cassandra-2.1.2 cassandra

The Cassandra installation layout may be different based on your type of installation. If you're installing using Debian or an RPM package, then the installation creates the required directories and applies the required permissions.

In older versions of Cassandra, you might need to create Cassandra log and data directories before running; by default, they are pointed to /var/lib/cassandra and /var/log/Cassandra. Running Cassandra will fail if the user running Cassandra doesn't have permissions for these paths. You can create and set permissions as shown here:

$ sudo mkdir -p /var/log/Cassandra
$ sudo chown -R `whoami` /var/log/Cassandra
$ sudo mkdir -p /var/lib/Cassandra
$ sudo chown -R `whoami` /var/lib/cassandra

The installation layout

The tarball installation layout is different from RPM or Debian packages. Let's see how they differ.

The directory layout in tarball installations

The following table shows the list of directories and their description:

Directory

Description

bin

This directory contains the startup scripts to launch the Cassandra server, the cqlsh prompt, and utility tools such as nodetool.

conf

This directory is the home of configuration files, including cassandra.yaml.

lib

This directory is Cassandra's Java dependency folder.

pylib

This directory contains Python libraries for cqlsh.

tools

Stress testing tools like cassandra-stress and other tools for example, sstable2json: which could be used to convert SSTables to JSON for debugging purposes. An SSTable or Sorted String Table is an immutable data file in disk, created for each Column Family. There could be zero or more SSTable per Column Family in every node of Cassandra cluster.

data

The Cassandra data directory will be created as soon as you start populating your Cassandra server. Its location is configured using the data_file_directories in the cassandra.yaml option.

logs

This is the default log directory. In older versions, it was /var/log/Cassandra.

The directory layout in package-based installation

The following table describes the installation layout if you use RPM or Debian packages:

Directory

Description

/var/lib/cassandra

This is the data directory.

/var/log/cassandra/

This is the log directory.

/var/run/Cassandra

This is the runtime file location, for example, the PID file.

/usr/share/Cassandra

This is the home of the include file cassandra-in.sh, which is used to set environment variables, such as CASSANDRA_HOME, CLASSPATH, and so on for Cassandra.

/usr/share/cassandra/lib

This is Cassandra's Java dependency folder; JAR files are placed here.

/usr/bin

This is the home of tools and utilities such as cqlsh, nodetool, and cassandra-stress.

/etc/cassandra

This is the home of the configuration.

/etc/init.d/

This contains the Cassandra startup scripts.

/etc/security/limits.d/

This is the file defining Cassandra user limits.

Configuration files

Now, let's look at some key configuration files and the options that we can configure in them:

cassandra.yaml

The configuration files are as follows:

  • Cluster configurations

    cluster_name: This is the identification string for a logical cluster. All nodes in a cluster must have the same value for this configuration.

    Default value: The default value is Test Cluster.

    listen_address: The Cassandra node will bind to this address. The other nodes in the cluster can communicate with this node if it is set correctly; leaving it to default will cause a failure in this node's communication with other nodes as default value is loopback address localhost hence node will not be able to communicate with other nodes running on different machines.

    Default value: The default value is localhost.

    seed_provider: The seed node helps Cassandra nodes to learn about other nodes in the cluster and ring topology using Gossip protocol. We'll learn more about Gossip protocol in later chapters. It has two suboptions, one is class_name and the other is number of seeds. The default seeding class takes a comma-delimited list of node addresses. In a multinode cluster, the seed list should have at least one node. This list should be common for all nodes.

    Default value: The default value is -class_name:org.apache.cassandra.locator.SimpleSeedProvider-seeds: "127.0.0.1".

    Tip

    The seed list should have more than one node for fault tolerance of the bootstrapping process.

    In a multi-data center cluster, at least one node from each data center should participate as a seed node.

    Note

    A node cannot be a seed node if it is a bootstrapping node. So, during the bootstrapping process, the node shouldn't be in the seeds list.

  • Data partitioning

    num_tokens: This configuration defines the number of random tokens this node will hold, hence defining the partitioning ranges that this node can hold. This is a relative configuration. For example, if a node has num_tokens as 128 while another node has 256, then it means that the second node is handling twice the data partition ranges than the first node is handling.

    Default value: The default value is 256.

    Tip

    All nodes with the same hardware capability should have the same number of tokens configured.

    partitioner: This defines the data partition algorithm used in the Cassandra cluster. The current default algorithm—Murmur3— is very fast and is considered as a good data partition algorithm as compared to its predecessors. So, while forming a new cluster, you should go with the default value, which is org.apache.cassandra.dht.Murmur3Partitioner.

    Note

    This setting shouldn't be changed once the data is loaded, as changing this will wipe all data directories, hence deleting data.

  • Storage configurations

    data_file_directories: Using this configuration option, we can set the data storage location.

    Default value: The default value is $CASSANDRA_HOME/data/data/var/lib/cassandra/data in older versions.

    commitlog_directory: This is the location in HDD where Cassandra will store commitlog.

    Default value: The default value is $CASSANDRA_HOME/data/commitlog /var/lib/cassandra/commitlog in older versions.

    Tip

    If using non-SSDs, you should have a separate disk for storing commitlog. Commit logs are append-only logs, however data files are random seeks in nature; so, using the same disk will affect the write performance of commit logs. Also, commit logs disks can be smaller in size. As the commitlog space is reusable once flushed to Disk from Memtable.

    saved_caches_directory: This is the location where cached rows, partition keys, or counters will be saved to disk after a certain duration of time.

    Default value: The default value is $CASSANDRA_HOME/data/saved_caches/var/lib/cassandra/saved_caches

    Note

    Row caching is disabled by default in cassandra.yaml due to its limited use.

  • Client configurations

    rpc_address: This is the thrift RPC service bind interface. You should set it appropriately; using the default won't allow connections from outside the node.

    Default value: The default value is localhost.

    rpc_port: This acts as a thrift service port.

    Default value: The default value is 9160

    native_transport_port: This is the port on which the CQL native transport will listen for clients; for example, cqlsh or Java Driver. This will use rpc_address as the connection interface.

    Default Value: The default value is 9042.

  • Security configurations

    authenticator: This configuration is used to specify whether you want to use a password-based authentication or none. For password-based authentication, authenticator should be set to PasswordAuthenticator. If PasswordAuthenticator is used, a username and hashed password are saved in the system_auth.credentials table.

    Default value: The default value is AllowAllAuthenticator, which means no authentication.

    authorizer: This configuration is used if you want to limit permissions to Cassandra objects, for example, tables. To enable authorization, set its value to CassandraAuthorizer. If enabled, it stores authorization information in the system_auth.pemissions table.

    Default value: The default value is AllowAllAuthorizer, which means authorization disabled.

    Tip

    If enabling authentication or authorization, increase system_auth keyspace's replication factor.

  • cassandra-env.sh

    This file can be used to fine-tune Cassandra. Here, you can set/tune a Java environement variable such as MAX_HEAP_SIZE, HEAP_NEWSIZE, and JAVA_OPTS.

  • cassandra-in.sh

    Here, you can alter the default values for environment variables such as JAVA_HOME, CASSANDRA_HOME and CLASSPATH. Its location is in $CASSANDRA_HOME/bin/ in binary tarball installations. Package-based installations put this file inside the /user/share/cassandra directory.

  • cassandra-rackdc.properties

    The rack and data center configurations for a node are defined here. The default datacenter is DC1 and the default rack is RAC1.

  • cassandra-topology.properties

    This file contains mapping of Cassandra node IPs to data center and racks.

  • logback.xml

    This file lets you configure the logging properties of Cassandra's system.log. It is not available in older versions of Cassandra.

Running a Cassandra server

Now that we know the prerequisites, let's quickly check the language dependencies:

We can check the Java version using the following code:

$ java –version
java version "1.7.0_45"

The Python version can be checked using this command:

$ python –version
Python 2.6.6

Running a Cassandra node

Since we're running only single node, we can skip configurations and directly start our node. Run the Cassandra node using the command for tarball installation:

$ bin/Cassandra

We can stop the server by using the following command:

$ pgrep -u `whoami` -f cassandra | xargs kill -9

Sometimes, we might want to run a Cassandra node in the foreground for debugging purposes, then we'll run it with –f flag:

$ bin/cassandra –f

To stop, press Ctrl + C.

For package-based installations, use the following commands to start and stop, respectively:

$ sudo service Cassandra start
$ sudo service Cassandra stop

Wohooo!! Our node is running, let's check our Cassandra server version:

$nodetool version
ReleaseVersion: 2.1.2

Note

Since we used the default Cassandra configuration, our node is running on the local interface and we'll not be able to connect to it from outside this machine using clients, for example, Java driver or other CQL clients.

Setting up the cluster

Let's set up a three-node cluster with the IPs 127.0.0.1, 127.0.0.2 and 127.0.0.3. So, our Cassandra.yaml for each node will look like this:

Setting up the cluster

Since all our nodes are the same from a hardware configuration perspective, we used num_tokens: 256 for all of them. The second node with an IP address of 127.0.0.2 acts as a seed node.

Additionally, we can set rpc_address and native_transport_ports for each node so that our Java client can connect to our nodes.

Now, we'll run the Cassandra server on each node using as discussed in the previous section, and our cluster with three nodes is ready.

Viewing the cluster status

Now that our cluster is up and running, let's check its status. We can use the Cassandra tool called nodetool to check the status:

$ nodetool status
Datacenter: datacenter1
=======================
Status=Up/Down
|/ State=Normal/Leaving/Joining/Moving
--  Address        Load       Tokens  Owns    Host ID
Rack
UN  127.0.0.1   171.88 MB     256     ?       940ba0cf-b75a-448c-a15e-40e05efbeb34  rack1
UN  127.0.0.2   141.12 MB     256     ?       4b728c3c-c545-4e4d-b1aa-2f66ef6bdce  rack1
UN  127.0.0.3   174.71 MB     256     ?       d63a18c4-0d2c-4574-8f66-c4eb1e5ca5a8  rack1
Note: Non-system keyspaces don't have the same replication settings, effective ownership information is meaningless

The first character in the status, which is U in our example, denotes the node's status whether it is Up (U) or Down (D). The second character tells us about the state of the joining cluster; it can be Normal (N), Leaving (L), Joining (J), or Moving (M). In our example, every node in the cluster is Up (U) and in the Normal (N) state. So, the first column is UN for each node. It also tells us about the data center in which our node lies. In our example, all the nodes lie in 'DataCenter 1' and rack 'rack1'.

Now, let's use the nodetool info command to check the individual node statistics such as its uptime, caching details, load details, and so on. We'll discuss Cassandra caching in detail in Chapter 4, Read and Write – Behind the Scenes:

$ nodetool info
ID               : 2f9bb0a9-db48-4146-83c6-4ce06bd22259
Gossip active    : true
Thrift active    : true
Native Transport active: true
Load             : 179.4 MB
Generation No    : 1422937400
Uptime (seconds) : 593431
Heap Memory (MB) : 474.63 / 920.00
Data Center      : datacenter1
Rack             : rack1
Exceptions       : 0
Key Cache        : entries 226, size 23.07 KB, capacity 45 MB, 4714 hits, 5006 requests, 0.942 recent hit rate, 14400 save period in seconds
Row Cache        : entries 0, size 0 bytes, capacity 600 MB, 0 hits, 0 requests, NaN recent hit rate, 3000 save period in seconds
Counter Cache    : entries 0, size 0 bytes, capacity 22 MB, 0 hits, 0 requests, NaN recent hit rate, 7200 save period in seconds
Token            : (invoke with -T/--tokens to see all 256 tokens)

Summary

Cassandra can be installed via various methods. We can install it on different platforms based on our requirements. However, platforms based on *NIX are very popular for production deployments. While deploying, we should consider various configuration options based on our deployment type. There are the configuration options that are used for performance tuning; we'll uncover more options later. The Cassandra nodetool is very handy to monitor and debug clusters and column families. We discussed some of them in this chapter.

In the next chapter, we'll see more of the nodetool options in more detail.

Left arrow icon Right arrow icon

Key benefits

  • Create a Cassandra cluster and tweak its configuration to get the best performance based on your environment
  • Analyze the key concepts and architecture of Cassandra, which are essential to create highly responsive Cassandra databases
  • A fast-paced and step-by-step guide on handling huge amount of data and getting the best out of your database applications

Description

Apache Cassandra Essentials takes you step-by-step from from the basics of installation to advanced installation options and database design techniques. It gives you all the information you need to effectively design a well distributed and high performance database. You’ll get to know about the steps that are performed by a Cassandra node when you execute a read/write query, which is essential to properly maintain of a Cassandra cluster and to debug any issues. Next, you’ll discover how to integrate a Cassandra driver in your applications and perform read/write operations. Finally, you’ll learn about the various tools provided by Cassandra for serviceability aspects such as logging, metrics, backup, and recovery.

Who is this book for?

If you are a developer who is working with Cassandra and you want to deep dive into the core concepts and understand Cassandra’s non-relational nature, then this book is for you. A basic understanding of Cassandra is expected.

What you will learn

  • Install and set up your Cassandra Cluster using various installation types
  • Use Cassandra Query Language (CQL) to design Cassandra database and tables with various configuration options
  • Design your Cassandra database to be evenly loaded with the lowest read/write latencies
  • Employ the available Cassandra tools to monitor and maintain a Cassandra cluster
  • Debug CQL queries to discover why they are performing relatively slowly
  • Choose the best-suited compaction strategy for your database based on your usage pattern
  • Tune Cassandra based on your deployment operation system environment
Estimated delivery fee Deliver to Poland

Premium delivery 7 - 10 business days

zł110.95
(Includes tracking information)

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Nov 20, 2015
Length: 172 pages
Edition : 1st
Language : English
ISBN-13 : 9781783989102
Category :
Tools :

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
OR
Modal Close icon
Payment Processing...
tick Completed

Shipping Address

Billing Address

Shipping Methods
Estimated delivery fee Deliver to Poland

Premium delivery 7 - 10 business days

zł110.95
(Includes tracking information)

Product Details

Publication date : Nov 20, 2015
Length: 172 pages
Edition : 1st
Language : English
ISBN-13 : 9781783989102
Category :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
$19.99 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
$199.99 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just zł20 each
Feature tick icon Exclusive print discounts
$279.99 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just zł20 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total 537.97
Mastering Apache Cassandra - Second Edition
zł221.99
Cassandra Design Patterns
zł157.99
Apache Cassandra Essentials
zł157.99
Total 537.97 Stars icon
Banner background image

Table of Contents

8 Chapters
1. Getting Your Cassandra Cluster Ready Chevron down icon Chevron up icon
2. An Architectural Overview Chevron down icon Chevron up icon
3. Creating Database and Schema Chevron down icon Chevron up icon
4. Read and Write – Behind the Scenes Chevron down icon Chevron up icon
5. Writing Your Cassandra Client Chevron down icon Chevron up icon
6. Monitoring and Tuning a Cassandra Cluster Chevron down icon Chevron up icon
7. Backup and Restore Chevron down icon Chevron up icon
Index Chevron down icon Chevron up icon

Customer reviews

Rating distribution
Full star icon Full star icon Full star icon Full star icon Half star icon 4.5
(2 Ratings)
5 star 50%
4 star 50%
3 star 0%
2 star 0%
1 star 0%
Aman Mar 17, 2018
Full star icon Full star icon Full star icon Full star icon Full star icon 5
Book contains sufficient information about the functionality of Cassandra and covers the technical portion with some very good real world examples
Amazon Verified review Amazon
Ian Stirk May 28, 2016
Full star icon Full star icon Full star icon Full star icon Empty star icon 4
Hi,I have written a detailed chapter-by-chapter review of this book on www DOT i-programmer DOT info, the first and last parts of this review are given here. For my review of all chapters, search i-programmer DOT info for STIRK together with the book's title.This book aims to explain the core concepts of Cassandra, how does it fare?The growth of Big Data has highlighted the scalability limits of relational databases. Several NoSQL databases have arisen to fill this niche, one of the more popular ones is Cassandra.The book is aimed at developers working with Cassandra wanting a more in-depth understanding. To get the most out of this book, a basic understanding of Cassandra is required, together with an appreciation of Java code and database systems.The book is relatively short, containing 146 working pages, spread over seven chapters.Below is a chapter-by-chapter exploration of the topics covered.Chapter 1 Getting Your Cassandra Cluster ReadyThe book opens with a comprehensive guide to installing Cassandra, covering the prerequisites (e.g. memory requirements), before downloading Cassandra source code, compiling and installing it. Instructions are also provided on installing a precompiled binary. The content of the various directories is outlined.The chapter next looks at the various configuration files, including: cluster, data partitioning, storage, client and security. The major content of each is briefly discussed.The chapter ends with details on running a Cassandra server, both on a single node and on a cluster of nodes. The Cassandra nodetool utility is used to check and monitor the cluster.This chapter provides a useful introduction to getting your Cassandra cluster up and running.The chapter is generally easy to read, with plenty of hands-on detail, useful tables and diagrams, and reusable scripts. There are occasional grammar problems, a recurring problem. Some terms are used without being defined (e.g. NoSQL). These traits apply to the whole of the book....ConclusionThis book aims to explain the core concepts of Cassandra, and generally succeeds. The book is easy to read, with plenty of hands-on detail, useful tables and diagrams, and helpful scripts.This is not a book for the complete Cassandra novice. Additionally, to get the most from the book, an understanding of Java code, and database systems is needed. Some knowledge of related terms is assumed (e.g. NoSQL, normalization), since these are not defined. Occasionally, there is bad grammar, but nothing too onerous. Sometimes the topics in a chapter are not introduced or linked together – making it difficult to make sense of.The book contains a mixture of both developer and administrator tasks, this seems to be the norm with NoSQL databases, whereas these areas are distinct in relational database environments.The book would benefit from a section on where to go next to get further information (e.g. websites, newsletters, forums etc).Overall, this is a useful overview of Cassandra, its internals and functionality.
Amazon Verified review Amazon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela