Xymon Mailing List Archive search

Alerting based on multiple hosts - is it possible?

list Adam Thorn
Tue, 20 Apr 2021 19:57:17 +0100
Message-Id: <user-4396aedefd6c@xymon.invalid>

On 20/04/2021 14:48, Ribeiro, Glauber via Xymon wrote:
Hello,

Say I have 3 servers

Srv1

Srv2

Srv2

Is it possible to configure an alert so that it will fire only when the CPU test for all 3 servers has gone yellow or red?

In other words, I don?t want Xymon to alert when one server or two servers are having problems. Only when all three are.
You can do this via a combo test defined in combo.cfg

https://xymon.sourceforge.io/xymon/help/manpages/man5/combo.cfg.5.html

i.e. you could define something like..

servers.cpu = (srv1.cpu + srv2.cpu + srv3.cpu) > 1

or perhaps...

servers.cpu = (srv1.cpu || srv2.cpu || srv3.cpu)

which would be green if one or more of the individual cpu tests were green. You could then alert on "HOST=servers TEST=cpu" as normal.

Regards,

Adam