up{instance=~"$instance"} offset 7d == 0             # servers which were 
down at a single instant of time exactly 7 days ago
max_over_time(up{instance=~"$instance"}[7d]) == 0    # servers which have 
been down *for the whole* of the last 7 days
min_over_time(up{instance=~"$instance"}[7d]) == 0    # servers which have 
been down *at any time* over the last 7 days
avg_over_time(up{instance=~"$instance"}[7d]) < 0.9   # servers which have 
been down *for at least 10%* of the last 7 days

On Friday, 29 July 2022 at 04:11:22 UTC+1 [email protected] wrote:

> Hello all,
>
> I installed node exporter on 10 servers. among those servers few servers 
> are down. I want to know which servers are down from last 7 days.
>
> up{instance=~"$instance"} == 0 (this is the query to find which server was 
> down) but how can i pass the time like last 7 days which server was down 
> and so on
>
> Any leads?
>
> Thanks,
> kumari.
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/8e15c5cc-7f0a-471b-b3a9-f470ec85efacn%40googlegroups.com.

Reply via email to