On 21/02/2023 09:56, sri L wrote:
Thanks for your reply Julius Volz.
Yes, we are monitoring servers with Node Exporter. We are looking for Uptime average based on calendar Month instead of last 30 days. For example, February Month it should give the uptime average for 28days i.e., 1st Feb to 28th feb

On Saturday, February 18, 2023 at 2:11:33 AM UTC+5:30 Julius Volz wrote:

    Assuming you are monitoring your servers via something like the
    Node Exporter, and you want the trailing 30-day upness percentage,
    you could use the Node Exporters "up" metric like this:

        avg_over_time(up{job="node"}[30d]) * 100

You would need to adjust the query to be

avg_over_time(up{job="node"}[28d]) * 100

--
Stuart Clark

--
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/4af97a2d-03c6-3cc5-c173-ec5cd01b6d44%40Jahingo.com.

Reply via email to