Victoriametrics: Add metrics deduplication functionality in `vmselect`

Created on 24 Dec 2019  路  4Comments  路  Source: VictoriaMetrics/VictoriaMetrics

Is your feature request related to a problem? Please describe.
I understand that the current recommended solution to deal with duplicated metrics from HA prometheus pairs is to setup Promxy. However, it would be ideal if VictoriaMetrics can also provide data deduplication out of the box rather than relying on another external tool.

I personally encountered frustrations while trying to get Promxy to work, and I have ultimately not found any solution because the folks maintaining Promxy are not as responsive.

It is a pity because as much as I like the performance and simplicity of VictoriaMetrics, I'm unable to employ this as the monitoring solution for my project because I couldn't get Promxy to work.

Describe the solution you'd like
Data deduplication can be done in the vmselect components at query-time, similar to how the Thanos Query component does. It can also be configured by setting replica_label values. I understand that someone has already requested this feature here: #86

Thank you!

enhancement

Most helpful comment

Hi @valyala, yes this setup sounds good

All 4 comments

@Janesee3 , does the following setup look correct?

  • To run multiple Prometheus instances scraping the same set of targets (aka Prometheus HA pair).
  • To configure all the Prometheus HA replicas to write data to centralized VictoriaMetrics. Each Prometheus would have distinct replica_label value in external_labels section.
  • To pass -replicaLabel config value to VictoriaMetrics, so it could merge and de-duplicate incoming queries using this label.

Hi @valyala, yes this setup sounds good

FYI, the -dedup.minScrapeInterval flag has been added in VictoriaMetrics v1.33.0. See https://github.com/VictoriaMetrics/VictoriaMetrics/blob/master/README.md#deduplication for more details.

Was this page helpful?
0 / 5 - 0 ratings