Add a cluster to Scylla Manager

Prepare a cluster

Scylla Manager communicates with a Scylla cluster using REST API. It’s required that the REST API is accessible by Scylla Manager on all the cluster nodes. By default Scylla binds REST API to localhost, which prevents from accessing if from other hosts. To overcome this limitation Scylla Manager can work with Scylla nodes over SSH.

Communication over SSH

This is a preferred way of Scylla Manager interacting with Scylla nodes. We recommend adding a dedicated system user to every node in a cluster and enabling SSH connectivity using key based authentication.

Scylla Manager comes with scyllamgr_ssh_setup script that helps you with the user creation, key generation and distribution. It requires that you have SSH access to to all the nodes with a sudo enabled user.

Configure SSH connectivity using scyllamgr_ssh_setup


  1. Run scyllamgr_ssh_setup to configure SSH access to the cluster.
scyllamgr_ssh_setup --user ec2-user --identity-file ec2-user.pem \
--manager-user scylla-manager --manager-identity-file scylla-manager.pem \
--discover        OK        OK        OK        OK        OK        OK
  • --user is SSH user name used to connect to the cluster nodes
  • --identity-file path is path to identity file containing SSH private key
  • --manager-user is a user name that will be created and configured on cluster nodes, by default it’s scylla-manager
  • --manager-identity-file is a path to identity file containing SSH private key for manager user, if there is no such file it will be created
  • --discover enables cluster node discovery, the command would take a single host and setup every node in the cluster

In cases where different hosts require different credentials use the --config-file option to specify host to identity file mapping using SSH configuration file.

Given an SSH configuration file named config:

Host 198.100.51.*
    User ec2-user
    IdentityFile /path/to/ec2-user.pem

Host 10.2.*
    User centos
    IdentityFile /path/to/centos.pem

Replace --user and --identity-file flags with --config-file flag.

scyllamgr_ssh_setup --config-file config
--manager-user scylla-manager --manager-identity-file scylla-manager.pem \
--discover        OK        OK        OK           OK           OK           OK

The SSH configuration file parameter may always be used to specify additional SSH options. Check man ssh_config for information on file format and available options.

  1. Continue to Add a cluster.


If you encounter troubles setting up SSH connectivity to a node use scyllamgr_ssh_setup command with -v flag to show debug information.

Direct communication

If you have setup SSH communication with the cluster as described in the previous section please continue to Add a cluster. If you have not used the script to establish SSH, you will need to create a connection manually. Note that exposing Scylla REST API may have a security consequences, if in doubt go to previous section.

Scylla Manager can interact with Scylla REST API on cluster nodes directly. For that configuration of all the cluster nodes must be adjusted and the nodes must be restarted.


For every node in the cluster repeat the procedure below.

  1. SSH to a node.
  2. Edit Scylla config file /etc/scylla/scylla.yaml, set api_address to the broadcast address.
  3. Drain the node (stop accepting writes and flush all tables).
nodetool drain
  1. Restart Scylla
sudo systemctl restart scylla-server.service
  1. Verify the Scylla server is running.

Add a cluster

Before you begin, confirm you have established SSH connectivity as explained in Configure SSH connectivity using scyllamgr_ssh_setup or Direct communication.


  1. From the Scylla Manager Server, run: sctool cluster add
sctool cluster add --host= --name=prod-cluster \
--ssh-user=scylla-manager --ssh-identity-file=scylla-manager.pem
/  \     Cluster added, to set it as a default run:
@  @     export SCYLLA_MANAGER_CLUSTER=db7faf98-7cc4-4a08-b707-2bc59d65551e
|  |
|| |/    Repair will run on 01 Sep 18 00:00 UTC and will be repeated every 7 days.
|| ||    To see the currently scheduled tasks: sctool task list -c db7faf98-7cc4-4a08-b707-2bc59d65551e
  • --host is hostname or IP of one of the cluster nodes
  • --name is an alias you can give to your cluster
  • --ssh-user is SSH user name used to connect to the cluster nodes
  • --ssh-identity-file path is path to identity file containing SSH private key

If you exposed the REST API directly to establish SSH connectivity (Direct Communication), the --ssh-user and --ssh-identity-file parameters should be omitted.

Each cluster has a unique ID. You will use this ID in all commands where the cluster ID is required. Each cluster is automatically registered with a repair task which runs once a week.

  1. Verify that the cluster you added has a registered repair task.
sctool task list -c db7faf98-7cc4-4a08-b707-2bc59d65551e
│ task                                        │ next run                      │ ret. │ properties │ status │
│ repair/730a134a-4792-4139-bc6c-75d2ba7a1e62 │ 01 Sep 18 00:00 UTC (+7 days) │ 3    │            │ NEW    │