apache/cassandra · error · RepairException

Nothing to repair for

Error message

Nothing to repair for %s in %s - aborting

What it means

Thrown during repair setup when computing neighbors and ranges: a common range requested for repair has no neighbors to repair with (beyond CMS-only replication in accord mode), so there is literally nothing to repair and the coordinator aborts with a RepairException.

Solutions

  1. Verify the keyspace replication settings (ALTER KEYSPACE ... RF) and run a full repair after RF changes.
  2. Check that the requested range is actually owned by this node (nodetool describering / ring).
  3. If the keyspace was dropped or re-created, refresh the repair request to the current range map.
  4. Run repair with the correct keyspace and ranges via nodetool repair or the storage service API.
  5. Rebootstrap/decommission correctly: rebuild nodes whose token ranges changed.
Defensive patterns

Strategy: validation

Validate before calling

// Confirm the keyspace still has replicas covering the requested range:
// nodetool describering -- keyspace <ks>
// SELECT replication FROM system_schema.keyspaces WHERE keyspace_name='<ks>';

Try / catch

try {
    repair(keyspace, ranges);
} catch (RepairException e) {
    if (e.getMessage().startsWith("Nothing to repair")) {
        // refresh ring/ranges or fix RF before retrying
    }
}

Prevention

When it happens

Trigger: getNeighborsAndRanges finds a common range whose includeForRange endpoints set is empty (or replicated only by CMS members) while the user explicitly requested repair of that range/keyspace.

Common situations: Repairing a keyspace right after changing replication strategy (replication factor reduced to 1 for the range), repairing a range that no longer belongs to this node, or running repair on a keyspace whose replication was changed without running a full repair/rebuild.

Related errors


AI-assisted analysis of apache/cassandra@88fd0f6a0e (2026-09-10). Data as JSON: /api/errors/864818cf5ed129f1. Report an issue: GitHub.

Appendix: source

Thrown at src/java/org/apache/cassandra/repair/RepairCoordinator.java:428

            EndpointsForRange includeForRange = ctx.repair().filterNeighbors(allForRange, range,
                                                                             state.options.getDataCenters(),
                                                                             state.options.getHosts());

            if (includeForRange.isEmpty())
            {
                if (state.options.ignoreUnreplicatedKeyspaces())
                {
                    logger.info("{} Found no neighbors for range {} for {} - ignoring since repairing with --ignore-unreplicated-keyspaces", state.id, range, state.keyspace);
                    continue;
                }
                else if (isMeta && !isCMS)
                {
                    logger.info("{} Repair requested for keyspace {}, which is only replicated by CMS members - ignoring", state.id, state.keyspace);
                    continue;
                }
                else
                {
                    throw RepairException.warn(String.format("Nothing to repair for %s in %s - aborting", range, state.keyspace));
                }
            }
            addRangeToNeighbors(commonRanges, range, includeForRange);
            includeNeighbors.addAll(includeForRange.endpoints());
        }

        if (includeNeighbors.isEmpty())
        {
            if (state.options.ignoreUnreplicatedKeyspaces())
            {
                throw new SkipRepairException(String.format("Nothing to repair for %s in %s - unreplicated keyspace is ignored since repair was called with --ignore-unreplicated-keyspaces",
                                                            state.options.getRanges(),
                                                            state.keyspace));
            }
            else if (isMeta && !isCMS)
            {
                throw new SkipRepairException(String.format("Nothing to repair for %s in %s - keypaces with MetaStrategy replication are not replicated to this node",
                                                            state.options.getRanges(),

View on GitHub (pinned to 88fd0f6a0e)