cluster_check

Using the cluster_check to compare the differences between specified or cluster-wide cassandra.yaml or dse.yaml files.

dse.yaml

The location of the dse.yaml file depends on the type of installation:
Package installations /etc/dse/dse.yaml
Tarball installations installation_location/resources/dse/conf/dse.yaml

cassandra.yaml

The location of the cassandra.yaml file depends on the type of installation:
Package installations /etc/dse/cassandra/cassandra.yaml
Tarball installations installation_location/resources/cassandra/conf/cassandra.yaml

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_location/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.

Example nodelist file:

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.yaml
listen_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.yaml
max_memory_to_lock_mb
    10.101.33.128: 10240
    10.101.33.187: None
    10.101.32.26: None
Note: If there are no differences between the dse.yaml files, cluster_check will erroneously report "listen address should be unique," which is an option in cassandra.yaml.

To check dse.yaml with minor differences for nodes listed in a nodelist text file:

./cluster_check /etc/dse/dse.yaml ~/node-list
max_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}