maintenance

maintenance is a command for Claude Code from openshift-eng/two-node-toolbox. It costs 6 tokens per session (4,009 once invoked), scanned A, original, Apache-2.0.

A guide to maintaining an etcd cluster, a distributed store commonly used to keep configuration and service state synchronized across machines.

In plain words
What is it for?
Use it to compact old keyspace history, defragment storage, manage maintenance alarms, and create snapshot backups.
Why use it?
It helps prevent the cluster’s stored history from filling disk space and provides recovery options after operational mistakes or data corruption.

Command for Claude Code

Written for Claude Code: installed under .claude/.

Good fit Use it to compact old keyspace history, defragment storage, manage maintenance alarms, and create snapshot backups.

Compare 6 commands from other repositories ↓
Install with agentmods
npx agentmods add commands/openshift-eng/two-node-toolbox/maintenance
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/openshift-eng/two-node-toolbox

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for maintenance

README.md
[![agentmods](https://agentmods.dev/badge/commands/openshift-eng/two-node-toolbox/maintenance/github.svg)](https://agentmods.dev/commands/openshift-eng/two-node-toolbox/maintenance)
Your own site
<a href="https://agentmods.dev/commands/openshift-eng/two-node-toolbox/maintenance"><img src="https://agentmods.dev/badge/commands/openshift-eng/two-node-toolbox/maintenance/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for maintenance

Your own site · 80×15
<a href="https://agentmods.dev/commands/openshift-eng/two-node-toolbox/maintenance"><img src="https://agentmods.dev/badge/commands/openshift-eng/two-node-toolbox/maintenance.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 6 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 4,009 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00006 $0.04009
Opus 5.5 $0.00002 $0.01604
Sonnet 5.5 $0.00001 $0.00802
Haiku 4.5 $0.00001 $0.00401

Measured 1mo ago against content hash 5c012628f0ff, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

maintenance scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 1mo ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/etcd/etcd-ops-guide/maintenance.md · 177 lines

How it starts

The opening of the file, as written. The whole thing — 177 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Overview

An etcd cluster needs periodic maintenance to remain reliable. Depending on an etcd application's needs, this maintenance can usually be automated and performed without downtime or significantly degraded performance.

All etcd maintenance manages storage resources consumed by the etcd keyspace. Failure to adequately control the keyspace size is guarded by storage space quotas; if an etcd member runs low on space, a quota will trigger cluster-wide alarms which will put the system into a limited-operation maintenance mode. To avoid running out of space for writes to the keyspace, the etcd keyspace history must be compacted. Storage space itself may be reclaimed by defragmenting etcd members. Finally, periodic snapshot backups of etcd member state makes it possible to recover any unintended logical data loss or corruption caused by operational error.

Raft log retention

etcd --snapshot-count configures the number of applied Raft entries to hold in-memory before compaction. When --snapshot-count reaches, server first persists snapshot data onto disk, and then truncates old entries. When a slow follower requests logs before a compacted index, leader sends the snapshot forcing the follower to overwrite its state.

Higher --snapshot-count holds more Raft entries in memory until snapshot, thus causing recurrent higher memory usage. Since leader retains latest Raft entries for longer, a slow follower has more time to catch up before leader snapshot. --snapshot-count is a tradeoff between higher memory usage and better availabilities of slow followers.

Since v3.2, the default value of --snapshot-count has changed from from 10,000 to 100,000.

In performance-wise, --snapshot-count greater than 100,000 may impact the write throughput. Higher number of in-memory objects can slow down Go GC mark phase runtime.scanobject, and infrequent memory reclamation makes allocation slow. Performance varies depending on the workloads and system environments. However, in general, too frequent compaction affects cluster availabilities and write throughputs. Too infrequent compaction is also harmful placing too much pressure on Go garbage collector. See https://www.slideshare.net/mitakeh/understanding-performance-aspects-of-etcd-and-raft for more research results.

Read the full file on GitHub · 177 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 1mo ago First seen · 177 lines · 6 tokens per session scan A 5c012628f0ff

Subscribe to this mod's changes

maintenance is a command published in the GitHub repository openshift-eng/two-node-toolbox (5 stars, last pushed 3d ago), licensed Apache-2.0. It adds 6 tokens to every session and 4,009 once invoked, about $0.0000 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.