cluster_check
The cluster_check compares the differences between specified or cluster-wide cassandra.yaml or dse.yaml files.
For ease of use, configure password-less SSH access from the current node to all other nodes.
The default location of the YAML comparison tool depends on the type of installation:
-
Package installations:
/usr/share/dse/tools/yamls -
Tarball installations:
INSTALL_DIRECTORY/tools/yamls
Before comparing the YAML files, install PyYAML:
sudo pip install pyyaml
Synopsis
./cluster_check /path/to/cassandra.yaml [ /path/to/nodelist ]
The nodelist parameter is optional because the script checks for the list of IP addresses contained in nodetool status.
The nodelist is a plain text file listing of IP address with one address per line.
For example:
10.101.33.128
10.101.33.187
10.101.32.26
Example
- To check cassandra.yaml with a minor difference for all nodes in the cluster
-
./cluster_check /etc/dse/cassandra/cassandra.yamllisten_address 10.101.33.128: 10.101.33.128 10.101.33.187: 10.101.33.187 10.101.32.26: 10.101.32.26 native_transport_broadcast_address 10.101.33.128: 10.101.33.128 10.101.33.187: 10.101.33.187 10.101.32.26: 10.101.32.26 - To check dse.yaml with a minor difference for all nodes in the cluster
-
./cluster_check /etc/dse/dse.yamlmax_memory_to_lock_mb 10.101.33.128: 10240 10.101.33.187: None 10.101.32.26: NoneIf there are no differences between the
dse.yamlfiles,cluster_checkwill erroneously report "listen address should be unique," which is an option incassandra.yaml. - To check dse.yaml with minor differences for nodes listed in a nodelist text file
-
./cluster_check /etc/dse/dse.yaml ~/node-listmax_memory_to_lock_mb 10.101.33.128: 10240 10.101.33.187: None ttl_index_rebuild_options 10.101.33.128: {'initial_delay': 52, 'max_docs_per_batch': 4096, 'fixed_rate_period': 350, 'thread_pool_size': 1} 10.101.33.187: {'initial_delay': 20, 'max_docs_per_batch': 4096, 'fixed_rate_period': 300, 'thread_pool_size': 1}