mesh-backup — Snapshot and restore mesh state (ledgers, config, identity)
mesh backup|bak
snap, list, restore, diff, prune, status
# mesh-backup
Snapshot and restore mesh state — all 49 JSONL ledgers, config, and identity files.
## Commands
- `mesh backup snap [label]` — Create named snapshot
- `mesh backup list` — List all snapshots
- `mesh backup restore <label>` — Restore (auto-creates safety snapshot first)
- `mesh backup diff <label>` — Compare current state vs snapshot
- `mesh backup prune [keep]` — Remove oldest snapshots (default: keep 5)
- `mesh backup status` — Overview of backup state
## Details
- Finds all 49 JSONL ledgers across scattered locations (mesh-state/, memory/, tools/, data/, plugins.d/)
- Pre-restore safety snapshots prevent data loss
- Diff shows line-count deltas per ledger
- Metadata stored as JSON with timestamp, host, counts
## Location
`tools/mesh-backup/backup.sh`