VictoriaMetrics Migration from Prometheus Prompt
Plan and execute a migration from vanilla Prometheus to VictoriaMetrics (vmagent, vmstorage, vmalert) for long-term storage and lower resource use — with backfill, PromQL/MetricsQL parity, and rollback.
- Target user
- Platform teams scaling Prometheus beyond single-node storage limits
- Difficulty
- Advanced
- Tools
- Claude, ChatGPT
The prompt
You are a platform engineer who has migrated production Prometheus deployments to VictoriaMetrics and knows the MetricsQL parity gaps, backfill pitfalls, and the safe rollback path. I will provide: - My current Prometheus setup (scrape volume, retention, storage size, HA pairs) - My pain points (disk, query latency, retention, cost) - Downstream consumers (Grafana, Alertmanager, recording rules) - Whether I want single-node or cluster VictoriaMetrics Your job: 1. **Decide the target topology** — single-node VM vs cluster (vminsert/vmselect/vmstorage). Recommend based on my ingestion rate and retention, and explain the tradeoffs honestly. 2. **Ingestion strategy** — choose between (a) Prometheus `remote_write` to VM (dual-write, lowest risk) or (b) replacing scraping with `vmagent`. Show the config for whichever I pick and explain the migration ordering. 3. **Dual-write cutover** — set up Prometheus remote_write to VM while keeping local storage, so I can compare queries in parallel before trusting VM. Give the remote_write block with queue tuning. 4. **Historical backfill** — explain how to import existing Prometheus TSDB data into VM (snapshot + `vmctl prometheus`); call out the gotchas (timestamps, dedup, disk during import). 5. **Query parity** — map my PromQL usage to MetricsQL; flag the differences (default rollup behavior, `WITH` templates, subquery syntax) and which dashboards/alerts need review. 6. **Alerting** — move recording + alerting rules to `vmalert`, pointing at VM for queries and Alertmanager for notifications; show the flags and confirm rule-group semantics match. 7. **Grafana** — switch data source to VM (Prometheus-compatible), and verify dashboards render identically during dual-write. 8. **Cutover & rollback** — a staged plan: dual-write → validate → shift reads → shrink Prometheus retention → decommission. Include the rollback trigger and steps at each stage. 9. **Validation** — concrete checks: ingestion rate parity, query result diffs on key dashboards, alert firing parity, disk/CPU before-after. Output as: (a) target topology recommendation, (b) remote_write / vmagent config, (c) vmctl backfill commands, (d) MetricsQL parity notes, (e) vmalert config, (f) staged cutover + rollback runbook. Bias toward dual-write validation over a hard cutover; never decommission Prometheus until read parity is proven.
Run this prompt with AI
Test it, get an AI-improved version, or compare models — live in the Prompt Workspace. No copy-paste.
Related prompts
-
VictoriaMetrics vmagent Stream Aggregation Rules Design Prompt
Design vmagent stream aggregation rules that pre-aggregate high-cardinality metrics at ingest, cutting stored series while preserving the dimensions your queries need.
-
Long-Term Metrics Storage Backend Selection Prompt
Choose between Thanos, Grafana Mimir, and VictoriaMetrics for long-term, scalable Prometheus storage based on your scale, team size, object-storage strategy, and multi-tenancy needs.
-
Prometheus Native Histograms Migration Prompt
Plan and execute the move from classic bucketed histograms to native (sparse) histograms — instrumentation changes, dual-emit rollout, query rewrites, and the storage/accuracy tradeoffs.
-
Prometheus Remote Read Query Federation Prompt
Configure and troubleshoot remote_read so a local Prometheus transparently queries a long-term backend without doubling query load, timing out, or returning duplicate series.
More Prometheus & Monitoring prompts & error guides
Browse every Prometheus & Monitoring prompt and troubleshooting guide in one place.
Reading prompts? Get all 500 in one free PDF
500 battle-tested, copy-paste AI prompts engineered by a senior systems engineer — every one with fill-in placeholders and safety/back-out notes. Drop your email and it's yours.
- 500 prompts: Linux · Kubernetes · Terraform · OpenStack · GitLab · Docker · Monitoring · Incident Response
- Instant PDF download — yours free, forever
- Plus one practical AI-workflow email a week (no spam)
Single opt-in · unsubscribe anytime · no spam.