The Cassandra top command, cass_top, is a friendly UI for monitoring clusters, similar to the top command, and shows menus to build and run nodetool commands.
cass_top is a wrapper around the Cassandra nodetool command that:
- colorizes the nodes by status and updates every few seconds
- has interactive option keys for all nodetool commands and options, documented on the help screen
- organizes nodetool commands by groups (cluster-wide, node-specific, reporting-only and updating)
- populates menus of nodes, keyspaces and column families
- builds the nodetool command and displays it for confirmation before running
- logs nodetool command start and end time, userid, stdout, stderr and the exit code.
- bash only (no dependencies except nodetool), tested on linux and Mac OS X
- no additional firewall holes needed beyond what nodetool requires
- minimal output to show multiple Cassandra rings on the same monitor.
usage: cass_top [connection_host=localhost] [keyspace=all] [one-character option=none]
To run the provided tests with Cassandra nodetool:
HOST=22.214.171.124 make test
To run the provided tests with mock nodetool (useful for testing without a network, on your notebook or for porting):
MOCK=1 HOST=126.96.36.199 make test
To run cass_top under the bashdb debugger:
- install bashdb and add it to your PATH
- do 'ps' to see your shell's pty number (NN) then:
echo "source /dev/pts/NN" > ~/.bashdbinit
MOCK=1 HOST=188.8.131.52 bashdb cass_topthen type 'c' ENTER. There are scripted breakpoints to get you started debugging.