Hi,
We’re looking into deploying a large-ish set of blackbox exporters. The plan was to use the dns service discovery mechanism to find these as they come and go, but I just realized that is not how the blackbox jobs are configured... We already do config generation for the actual targets we want probed, but we’ve always just had a single blackbox instance to point to when doing the relabelling.
Is there some way to use service discovery for the actual blackbox? With the config from the docs
scrape_configs:
- job_name: 'blackbox'
metrics_path: /probe
params:
module: [http_2xx] # Look for a HTTP 200 response.
static_configs:
- targets:
- http://prometheus.io # Target to probe with http.
- https://prometheus.io # Target to probe with https.
- http://example.com:8080 # Target to probe with http on port 8080.
relabel_configs:
- source_labels: [__address__]
target_label: __param_target
- source_labels: [__param_target]
target_label: instance
- target_label: __address__
replacement: 127.0.0.1:9115 # Blackbox exporter.
Can we do something to have the __address__ replacement served by dns_sd? This gets a bit odd since there are two “dynamic” parts.
Best,
Carl
--
Best,
Carl
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-users+unsubscribe@googlegroups.com.
To post to this group, send email to prometheus-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/AM2PR05MB12336D4CC9A691F26A9873848F780%40AM2PR05MB1233.eurprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.
I think I may have been a bit unclear. The case is that I have multiple blackboxes coming and going, all registering themselves under a SRV record. I also have a dynamic list of targets, currently populated via consul-template.
That is, the configuration is dynamic in multiple dimensions. If I add a new blackbox instance, I want it to be used for all targets, and if I add a new target, I want it scraped from all instances.
But thinking about it, it probably cannot work like that. I will need to either have one job per target, or one job per blackbox, right?
Carl
Best,
Carl
--
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-use...@googlegroups.com.
To post to this group, send email to promethe...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/AM2PR05MB12336D4CC9A691F26A9873848F780%40AM2PR05MB1233.eurprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
prometheus-use...@googlegroups.com.
To post to this group, send email to
promethe...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/prometheus-users/CAHJKeLriHbcthwUJgZcA9a57oc-5BH2U1fMYgxWoC9X%2BC7SDmg%40mail.gmail.com.
I think I may have been a bit unclear. The case is that I have multiple blackboxes coming and going, all registering themselves under a SRV record. I also have a dynamic list of targets, currently populated via consul-template.
That is, the configuration is dynamic in multiple dimensions. If I add a new blackbox instance, I want it to be used for all targets, and if I add a new target, I want it scraped from all instances.
But thinking about it, it probably cannot work like that. I will need to either have one job per target, or one job per blackbox, right?
Carl
Best,
Carl
--
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-users+unsubscribe@googlegroups.com.
To post to this group, send email to prometheus-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/AM2PR05MB12336D4CC9A691F26A9873848F780%40AM2PR05MB1233.eurprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to prometheus-users+unsubscribe@googlegroups.com.
To post to this group, send email to prometheus-users@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/prometheus-users/CAHJKeLriHbcthwUJgZcA9a57oc-5BH2U1fMYgxWoC9X%2BC7SDmg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.