apache/cassandra · warning

Failed to send a clean up message to

Error message

Failed to send a clean up message to {}

What it means

When finalizing a repair session, ActiveRepairService sends CLEANUP_MSG messages to participating endpoints to release repair resources. If sending to an endpoint throws (node down, IO error), it logs this warning with the exception and continues with the remaining endpoints. Stale repair sessions on the unreachable node are later cleaned up by session timeout.

Solutions

  1. Verify the endpoint's health (nodetool status) and restart it if down.
  2. Confirm the repair session on that node expires and cleans itself (repair_session timeout), no manual action usually needed.
  3. Check network/firewall between nodes if the warning recurs across repairs.
Defensive patterns

Strategy: retry

Validate before calling

// before starting repair, ensure all participants are reachable
for (InetAddress ep : participants) {
    if (!FailureDetector.instance.isAlive(ep))
        throw new IllegalStateException("Participant down: " + ep);
}

Try / catch

// tolerate cleanup send failure; rely on session expiry
try { sendCleanup(endpoint); }
catch (Exception e) { logger.warn("cleanup to {} deferred to session timeout", endpoint, e); }

Prevention

When it happens

Trigger: cleanupParentsAndSkipTrash / repair completion path iterates endpoints and RepairMessage.sendMessageWithRetries throws for a host that is down or unreachable via messaging service.

Common situations: Node crashed or was decommissioned mid-repair; network partition during repair teardown; transient messaging failures at session end.

Related errors


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

Appendix: source

Thrown at src/java/org/apache/cassandra/service/ActiveRepairService.java:861

                        public void onResponse(Message msg)
                        {
                            logger.trace("Successfully cleaned up {} parent repair session on {}.", parentRepairSession, endpoint);
                        }

                        @Override
                        public void onFailure(InetAddressAndPort from, RequestFailure failure)
                        {
                            logger.debug("Failed to clean up parent repair session {} on {}. The uncleaned sessions will " +
                                         "be removed on a node restart. This should not be a problem unless you see thousands " +
                                         "of messages like this.", parentRepairSession, endpoint);
                        }
                    };
                    RepairMessage.sendMessageWithRetries(ctx, message, Verb.CLEANUP_MSG, endpoint, loggingCallback);
                }
            }
            catch (Exception exc)
            {
                logger.warn("Failed to send a clean up message to {}", endpoint, exc);
            }
        }
        ParticipateState state = participate(parentRepairSession);
        if (state != null)
            state.phase.success("Cleanup message recieved");
    }

    private void failRepair(TimeUUID parentRepairSession, String errorMsg)
    {
        throw failRepairException(parentRepairSession, errorMsg);
    }

    private RuntimeException failRepairException(TimeUUID parentRepairSession, String errorMsg)
    {
        participateFailed(parentRepairSession, errorMsg);
        removeParentRepairSession(parentRepairSession);
        return new RuntimeException(errorMsg);
    }

View on GitHub (pinned to 88fd0f6a0e)