When using the NetworkTopologyStrategy, Cassandra is informed about the cluster topology and each cluster node is assigned to a rack (or Availability Zone in AWS Cloud systems). Cassandra ensures that data written to the cluster is evenly distributed across the racks. When the replication factor is equal to the number of racks, Cassandra ensures that each rack contains a full copy of all the data. With the default replication factor of 3 and a cluster of 3 racks, this allocation can be used to optimize repairs.
- At least once a week, schedule incremental repairs by using the following nodetool command: \'nodetool repair -inc - par\'
- Optional: Check the progress of the repair operation by entering: nodetool
compactionstatsFor more information about troubleshooting repairs, see the "Troubleshooting hanging repairs" article in the DataStax documentation.
- If a node joins the cluster after more than one hour unavailability, run the
repair and cleanup activities:
- In the nodetool utility, enter: \'nodetool repair\'
- In the nodetool utility, enter: \'nodetool cleanup\'