Scylla and nodetool
About nodetool
The nodetool
command is a utility for administering the Scylla/Cassandra cluster. It is a standard command for Scylla/Cassandra systems.
Installing nodetool
There are a number of ways you can get nodetool installed on your local system.
It comes with the latest Cassandra release, so you can get it by installing Cassandra using an appropriate method for your platform. On a Mac, for example, you can install Cassandra with homebrew
by typing brew install cassandra
.
You can also pick up both nodetool and cqlsh from the Scylla Tools github repository. Nodetool can then be run from bin/nodetool
.
Connecting nodetool to your deployment
In order to enable nodetool administration of Scylla, the deployment comes with an SSH capsule configured as a SOCKS proxy. The first step is to provision a user with SSH access to your deployment in order to use the proxy.
Once you have a trusted user, then you will use the ssh
command under SOCKS Proxy Configuration to open a secure tunnel to your deployment. When the tunnel is open, use a new terminal window to run nodetool
commands. The commands have the following format:
nodetool -h [host] -p [port] -u [user] -pw [password] [proxy info] [command] [arguments]
The host, port, user, and password parameters are all present, followed by the SOCKS proxy information, followed by the nodetool command and any of it arguments. There are example commands for the deployment in the Nodetool Administration panel. These will provide you with the status of your Scylla cluster.
Available nodetool commands
Nodetool has a wide range of commands, but on Compose we limit which are available to avoid situations which could damage the automated maintenance of the cluster. These are the available commands:
cfhistograms | Provides statistics about a table, including number of SSTables, read/write latency, partition size and column count. |
cfstats | Provides in-depth diagnostics regard column family. |
cleanup | Triggers the immediate cleanup of keys no longer belonging to a node |
compact | Force a (major) compaction on one or more column families. |
compactionhistory | Print history of compaction. |
compactionstats | Print statistics on compactions. |
describecluster | Print the name, snitch, partitioner and schema version of a cluster. |
describering | Shows the token ranges info of a given keyspace. |
flush | Flush one or more column families. |
help | Prints |
getendpoints | Print the end points that owns the key. |
gossipinfo | Shows the gossip information for the cluster. |
info | Print node information. |
move | Move node on the token ring to a new token. |
netstats | Print network information on provided host (connecting node by default). |
proxyhistograms | Print statistic histograms for network operations. |
repair | Repair one or more column families. |
ring | The nodetool ring command display the token ring information. |
status | Print cluster information. |
statusbackup | Print status of ScyllaDB backup. |
statusbinary | Print status of native transport (binary protocol). |
statusgossip | Print status of gossip. |
version | Print the DB version. |
The full list of commands, including those which are not available, is in the Scylla nodetool docs. Nodetool is a subset of the Cassandra nodetool; you can find more on that command, as it has more detail on the subcommand use in the Cassandra Wiki for nodetool.
Blocked nodetool Commands
The following commands are blocked from use by nodetool when applied to a Compose Scylla deployment:
clearsnapshot, decommision, disablebackup, disablebinary, disablegossip, drain, enablebackup, enablebinary, enablegossip, getlogginglevels, listsnapshots, rebuild, refresh, removenode, setlogginglevel, settraceprobability, snapshot, stop.
Still Need Help?
If this article didn't solve things, summon a human and get some help!
Updated over 3 years ago