Hello,

thank you for clarification. I though this :raw was something specific with 
histograms/buckets/heatmaps.
In the past I tried adding the "=~" instead of "=" but did not work. tried 
again today and it was a combination of things to change I did not before.

I changed it like this and it works like I exect:

host="${target:raw}"     ---->  host=~"$target"

Brian Candler schrieb am Donnerstag, 11. Januar 2024 um 09:56:24 UTC+1:

> This is a question about Grafana and/or the smokeping_exporter Grafana 
> dashboard, not Prometheus.
>
> ${target:raw} is a Grafana variable expansion, and the :raw suffix is a 
> format specifier:
>
> https://grafana.com/docs/grafana/latest/dashboards/variables/variable-syntax/#variable-syntax
>
> https://grafana.com/docs/grafana/latest/dashboards/variables/variable-syntax/#raw
>
> If you want multiple Grafana selections to be active at once in a PromQL 
> query, then in general you need to use regex: *foo{host=~"${target}"}*
> Because Grafana understands PromQL it shouldn't be necessary to add a 
> :regex suffix here, although it's probably OK to add it. It should expand 
> to something like
>     *foo{host=~"1\.1\.1\.1|8\.8\.8\.8"}*
> The important thing is that you use =~ instead of =.
>
> All this is standard Grafana functionality, and therefore further 
> questions about this would best be asked in the Grafana Community forum.
>
> If the published smokeping_exporter dashboard allows multiple selections 
> in its target var, but uses host= instead of host=~, then that's a bug in 
> the dashboard which you'd need to raise with the author.
>
> However, if the published dashboard only allows a single target selection 
> and you *modified* it to allow multiple selections, then you broke it. At 
> this point you've become a Grafana dashboard developer, and again, the 
> Grafana Community would be the best place to ask for help. It's Grafana 
> that builds the query; Prometheus can only process whatever query it's 
> given.
>
> On Thursday 11 January 2024 at 08:01:15 UTC Alexander Wilke wrote:
>
>> Hello,
>>
>> I am using the smokeping_prober (
>> https://github.com/SuperQ/smokeping_prober) v0.7.1 and the provided 
>> dashboard.json.
>>
>> For whatever reason the queries contain ".raw" endings for the targets.
>> This leads to a problem if I want to show several targets in the same 
>> graph because targets are not added with "|" in between but with ","
>>
>> Here is the query with one selected target which is working:
>> [image: smoke_ping_one_target.JPG]
>>
>>
>> If I select two or more targets than the query looks like this but not 
>> data anymore:
>> [image: smoke_ping_more_targets_no_data.JPG]
>>
>> If I remove the ":raw" at the end of the target I do not get any data no 
>> difference if one or more clients. So this is somehow relevant.
>>
>>
>> My idea was to have any overview panel which shows the latency of several 
>> smokeping_probes and to compare them. I want to place several "sensors" in 
>> our DataCenter and they should ping each other. If someone tells me he has 
>> performance issues with an appliacation I can select the relevant 
>> zones/probers and can compare if the latency changed or not.
>>
>> If I want to compare 6 probers and have to scroll through 6 pannels it is 
>> not so elegant because depending on the latency the scale of the panels is 
>> different and may lead to wrong assumptions.
>>
>

-- 
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+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/54dc0292-2746-46fe-ab62-325661666ffen%40googlegroups.com.

Reply via email to