Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

support more than one prometheus server #2556

Open
glommer opened this issue Jul 7, 2017 · 4 comments
Open

support more than one prometheus server #2556

glommer opened this issue Jul 7, 2017 · 4 comments

Comments

@glommer
Copy link
Contributor

glommer commented Jul 7, 2017

We have right now in master some metrics that are potentially very expensive to be exported, as they are O(#CFs) in size.

The idea is to export them through a secondary prometheus server, running alongside the main prometheus server. Customer interested in those metrics could enable the collection of the secondary server.

@glommer
Copy link
Contributor Author

glommer commented Oct 30, 2018

I just came across a use case that could greatly benefit from this.

One of our users, on slack, complains that we export too many metrics, which impacts their existing prometheus servers both in terms of network traffic and storage costs.

He very rightfully asks:

Can you configure the scrape period per metric? Like disk space is something that doesn't need to be scraped every 5s or even 30s.

We had buried the two servers discussions in the past because we would still want to see metrics for everything , and having some metrics disabled could be dangerous since when you need it they won't be there.

However, we could configure different metrics to scrape in different intervals and two prometheus servers could be an easy way to do that.
(another way would be to have a separate configuration file per metric, having different scrape periods, but that sounds like too much trouble to me)

@amnonh
Copy link
Contributor

amnonh commented Oct 31, 2018

That was the exact idea behind multiple prometheus servers.

The solution was composed of two functionality (that strangely enough, only one got merged).

  1. to allow programmer, when creating a metric register a metric on a specific Prometheus server (as opposed to the default Prometheus server).
  2. All query subset of metrics based on their name (this part was merged).

If the two were merged, it would have allowed us to set a minimal set of metrics that will be included by default and set the configuration for more static values (like diskspace) or data hungry (like table specific) to have a lower scrap interval.

@glommer
Copy link
Contributor Author

glommer commented Oct 31, 2018 via email

@tzach
Copy link
Contributor

tzach commented May 26, 2020

We can use collectors to select which metrics we will scrape - in the same
server.

Was this ever enabled?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants