Calculate total uptime/downtime

Hi,

I'm thinking about setting up Hearbeat to monitor the uptime of my hosts. Is it possible with Hearbeat to calculate the time that a host has been up or down over a month or a year? This functionality would be really useful for me.
Additionally, I'd also want to calculate the total downtime (when all hosts are down).

Would be great to know if this is possible before I have to go through the whole installation process. Thanks!

Great question. There are different ways to calculate that. There's an easy way, that's sometimes wrong, and there's a much more complex way we're hoping to deliver in https://github.com/elastic/kibana/issues/44546 .

The easy way is to count the number of pings that are up vs. down. If you have 10 down pings and run checks every minute then you were down for 10m. If this works for you you can calculate this manually. We don't show this UI because this doesn't work when:

  1. Heartbeat was not running for some reason
  2. The interval between checks was changed.
  3. There are multiple heartbeats running in multiple locations

That's why we don't calculate the naive way ourselves, but if you are running a single heartbeat it's not unreasonable to calculate that number yourself so long as you keep those limitations in-mind.

2 Likes

Thank you for your detailed answer Andrew!

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.