By submitting this form, you are confirming you have read and agree to
our privacy policy.

This blog post is a short introduction on how to use the ScyllaDB Docker image to start up a Scylla node, access nodetool and cqlsh utilities, start a cluster of Scylla nodes, configure data volume for storage, and configure resource limits of the Docker container. For full documentation, see the image description on Docker Hub.

Please note that the instructions in this blog post assume that you have configured Docker so that you can run it as a regular user. Usually, this is done by adding the user to a Docker group. See your platform specific Docker installation documentation on how to do that (see, for example, instructions for Fedora and Ubuntu). If you have not configured a Docker group, you need to prefix the docker commands with sudo to have sufficient permissions to run them.

Getting Started

To start a single Scylla node instance in a Docker container, run:

$ docker run --name some-scylla -d scylladb/scylla

The docker run command starts a new Docker instance in the background named some-scylla that runs the Scylla server:

The Docker image also has Scylla’s utilities installed. Nodetool is a command line tool for querying and managing a ScyllaDB cluster. The simplest nodetool command is nodetool status, which displays information about the cluster state:

Configuring Data Volume for Storage

The default filesystem in Docker is inadequate for anything else than just testing out Scylla but you can use Docker volumes for improving storage performance.

To use data volumes, first create a Scylla data directory /var/lib/scylla on the host, which is used by Scylla container to store all data (and make sure it’s on a proper filesystem like XFS):

$ sudo mkdir -p /var/lib/scylla/data /var/lib/scylla/commitlog

Then launch Scylla instances using Docker’s --volume command line option to mount the created host directory as a data volume in the container and disable Scylla’s developer mode to run I/O tuning before starting up the Scylla node.

Configuring Resource Limits

Scylla utilizes all CPUs and all memory by default.

To configure resource limits for your Docker container, you can use the --smp, --memory, and --cpuset command line options documented in the section “Command-line options” of the Docker image documentation.

If you run multiple Scylla instances on the same machine, it is highly recommended that you enable the --overprovisioned command line option, which enables certain optimizations for Scylla to run efficiently in an overprovisioned environment.

Related Posts

About Pekka Enberg

Pekka Enberg is a software engineer currently working on ScyllaDB. He has been a Linux kernel contributor for the past 10 years and has worked on various other open source projects. He has extensive background in UNIX kernels and the JVM.

ScyllaDB

Keep in Touch

Apache®, Apache Cassandra®, are either registered trademarks or trademarks of the Apache Software Foundation in the United States and/or other countries. No endorsement by The Apache Software Foundation is implied by the use of these marks.