etcdctl
$ etcdctl Foundation High Risketcdctl is the official v3 API client for etcd clusters (backing Kubernetes and distributed coordination). Supports --write-out=json (-w json) across get, member list, and endpoint health, TLS flags, and ETCDCTL_API=3 configuration.
brew install etcd etcdctl endpoint health -w json and etcdctl get --prefix --keys-only provide low-level cluster state inspection directly in shell workflows.
Agent-Readiness Checklist
Static evaluation (not yet probed on this host). Run npm run data:probe locally to capture live verification.
FCRS-1.0 6-Dimension Breakdown
Supports -w json (--write-out=json), --keys-only, and ETCDCTL_* env vars cleanly, though JSON values are base64-encoded.
- Supports
-w json,--keys-only, andETCDCTL_*env vars
Supports mTLS and RBAC auth, though del --prefix or put on Kubernetes control-plane clusters carries severe blast radius.
- mTLS auth; high blast radius on
del --prefixandmemberops
Single static Go binary available via Homebrew and GitHub Releases.
- Static Go binary across macOS, Linux, Windows
Indispensable for etcd cluster diagnostics, snapshots, and key inspection.
- Covers KV, leases, watches, snapshots, and endpoint diagnostics
CNCF graduated project (etcd-io/etcd) under Apache-2.0.
- Official CNCF
etcd-io/etcdrepository
Good official v3 guide, though mTLS flag combinations can be verbose.
- Official docs at etcd.io/docs/latest/dev-guide/interacting_v3/
Security, Auth & Guardrails
Endpoints, TLS cert paths, and user credentials via ETCDCTL_* env vars or --cacert/--cert/--key/--user flags.
100% free and Apache-2.0 open-source (CNCF graduated project).
# etcdctl Agent Rules - Always pass `-w json` (note: keys/values in JSON are base64-encoded). - Use `--keys-only` before fetching full values on large prefixes. - NEVER run `etcdctl del --prefix`, `member remove`, or `defrag` autonomously on live clusters.
Agent-Ready Command Recipes
Safe Read-Only Queries
etcdctl endpoint health --cluster -w json
Verifies quorum and health status of every member in the etcd cluster.
etcdctl get /app/ --prefix --keys-only -w json
Enumerates keys under a prefix cleanly without dumping large binary payloads.
Controlled Writes & Previews
etcdctl snapshot save ./etcd-backup.db
Takes a consistent point-in-time snapshot of the etcd keyspace locally.
Strengths for Agents
- +
-w jsonworks reliably across KV, member, and endpoint health commands. - +
--keys-onlyprevents huge payload dumps during prefix discovery. - +
ETCDCTL_*environment variables streamline TLS configuration.
Caveats & Pitfalls
- !
-w jsonencodes keys and values as base64 strings, requiringjq(@base64d) to decode. - ! Mutations on Kubernetes-backing etcd clusters can break cluster state instantly.