Deploy VictoriaMetrics on Kubernetes: Fast Metrics

Engineering teams requiring efficient time series metric collection often face high memory consumption with standard Prometheus setups. This architecture provisions a lightweight monitoring stack using a VictoriaMetrics time series database and a vmagent metrics collector. Setting up this VictoriaMetrics Kubernetes deployment provides a scalable destination for Prometheus-compatible remote write targets and scrapers, making it straightforward to deploy VictoriaMetrics on Kubernetes.
| Component | Type | Port | Role |
|---|---|---|---|
| monitoring | Namespace | N/A | Isolates monitoring resources within the cluster |
| victoriametrics-data | PersistentVolumeClaim | N/A | Provisions 20Gi persistent storage for time series data |
| victoriametrics-svc | Service | 8428 | Exposes VictoriaMetrics API and ingestion endpoints internally |
| vmagent-config | ConfigMap | N/A | Defines Prometheus-compatible scrape configuration for vmagent |
| vmagent | Deployment | 8429 | Collects operational metrics and pushes them to VictoriaMetrics |
| vmagent | Service | 8429 | Exposes vmagent metrics and health probes internally |
| victoriametrics | Deployment | 8428 | Runs the single-node VictoriaMetrics time series database |
The vmagent Deployment reads target endpoints from vmagent-config and continuously scrapes operational metrics. Collected data streams directly to victoriametrics-svc on port 8428 using the Prometheus remote write protocol. The victoriametrics Deployment writes time series data to the victoriametrics-data PersistentVolumeClaim mounted at /storage. Internal traffic routes across ClusterIP Services within the isolated Namespace.
vmagent-config ConfigMap to add your custom target scrape jobs.victoriametrics-data PersistentVolumeClaim size from 20Gi if your metrics retention demands more storage.victoriametrics and vmagent Deployments according to your workload size.victoriametrics-svc Service to your local machine using port 8428./health endpoint on localhost:8428 to confirm the VictoriaMetrics storage engine is responsive.http://localhost:8428/vmui in your browser and run a PromQL query such as up to verify metrics ingestion from vmagent.vmagent and forwards them to a centralized VictoriaMetrics cluster over remote write.This VictoriaMetrics Kubernetes template deploys a single-instance time series database paired with a dedicated vmagent collector in a dedicated namespace. The configuration establishes automated metrics scraping, persistent storage mounting, and remote-write data ingestion.