Back to browse
GitHub Repository

Three-layer automated cleanup for orphan Claude Code processes (subagents, MCP servers, plugins)

14 starsShell

Cc-reaper – Three-layer cleanup for orphan Claude Code processes

by thequert·Mar 2, 2026·2 points·0 comments

AI Analysis

●●SolidSolve My ProblemDark Horse

Three-layer orphan process cleanup for Claude Code's known memory leak.

Strengths
  • Layered defense (stop hooks + proc-janitor daemon + manual CLI) catches abnormal terminations
  • Quantified problem: documented 200–400 MB per subagent, 7+ GB cumulative bloat
  • Works within Claude's native hook system (settings.json integration)
Weaknesses
  • Workaround for a Claude Code product bug, not a solution Anthropic should ship
  • Daemon setup requires Rust + Homebrew/Cargo, high friction for non-engineers
Target Audience

Claude Code users on macOS/Linux experiencing memory bloat from crashed sessions

Similar To

systemd-run memory limits · process cgroups · macOS launchd resource limits

Similar Projects