The nodetool Utility
Explore Apache Cassandra's nodetool utility for cluster management and monitoring, and get acquainted with some basic nodetool commands.
In this lesson, we will cover the nodetool utility, a command line administration tool provided by Apache Cassandra which comes installed with the database management software. It has an extensive list of commands to manage and monitor a Cassandra cluster, e.g., access cluster information, set configuration variables, etc.
To access the nodetool utility, type nodetool once the cluster is up and running. It will display the usage syntax and the nodetool commands with their descriptions. Notice the syntax below.
nodetool [options] nodetool_command [args]
Options may be specified in long or short notation, as described in the following table. JMX authentication may be configured, requiring a username and password for nodetool commands.
nodetool Command Options
Option (short) | Option (long) | Description |
|
| JMX agent user name |
|
| JMX agent password |
|
| Operate in 4.0 mode with hosts disambiguated by port number |
|
| Node’s IP address or hostname |
|
| JMX Port. By default, Cassandra uses 7199 |
|
| Full path of JMX password file |
The node’s IP address and port may be provided in the nodetool command, as described in the screenshot below. We will omit these for simplicity, as our installation is on a single server.
Basic nodetool commands
We will cover a few basic nodetool commands in this lesson.
The version command
The version command displays the version of Cassandra running on this node.
nodetool version
The screenshot below demonstrates the execution of the nodetool version command.
The help command
The help command displays the general syntax of the nodetool commands, and lists all nodetool commands along with their descriptions.
nodetool help
If a nodetool command is listed after the help ...