Re: [prometheus-users] Re: Group time series by day

2025-01-06 Thread Jseb Tarot
Energie is a counter it is not possible to calculate! from power! Instant value!. See solution from you exporter value. It is problaly existe natively this metric on your device! Le mar. 7 janv. 2025, 01:02, Elliott Balsley a écrit : > Wow! Both of these methods work perfectly, with Grafana ste

[prometheus-users] Re: Group time series by day

2025-01-06 Thread Elliott Balsley
Wow! Both of these methods work perfectly, with Grafana step set to 24h. It was initially hard for me to wrap my head around this but after thinking about your examples it makes sense now. Thanks Bryan! One more piece that's not working: Even with the time ranges set as you described (from:

[prometheus-users] Re: Alert manager receiver config.

2025-01-06 Thread 'Chrysale Tchako' via Prometheus Users
This is the exact configuration of my alermanager.yml file (some values were substituted for privacy/security) do you notice any discrepancies? global: smtp_hello: 'example.com' route: group_wait: 1m group_interval: 5m repeat_interval: 12h group_by: ["alertname", "severity"] # Defau

[prometheus-users] Re: Alert manager receiver config.

2025-01-06 Thread 'Brian Candler' via Prometheus Users
Then something strange is going on. Are you 100% sure that you pasted *exactly* the configuration file you're using, with *exactly* the correct contents and indentation? You can add labels in your service discovery, e.g. if you are using file_sd_configs then inside the targets file you can put

[prometheus-users] Re: Alert manager receiver config.

2025-01-06 Thread 'Chrysale Tchako' via Prometheus Users
I believe this is the correct config file because when I mute an email from one of the receivers that email is no longer included in any notification that gets sent out. As far as the labels you mentioned earlier, could you share an example of how to implement or format those in my alertmanager

[prometheus-users] Re: Group time series by day

2025-01-06 Thread Bryan Boreham
Off the top of my head it seems this should be: avg_over_time(watts[24h]) * 24 If you tried this please say what went wrong. An alternative would be: sum_over_time(watts[24h:1m]) / 60. This uses a subquery to produce a value every 1 minute, adds them all up to give a total in Watt-minutes, then

[prometheus-users] Group time series by day

2025-01-06 Thread Elliott Balsley
Is there a way to do something like GROUP BY in PromQL? My use case is to convert Watts to Watt-Hours. I have a gauge metric measuring instantaneous power consumption every minute. I want to calculate the daily consumption to display in Grafana as a time series with one bar per day over a 30