Xymon Mailing List Archive search

mapping purple to red, and wild card for COMPACT

list Ron Cohen
Tue, 22 Oct 2019 15:35:05 +0100
Message-Id: <user-11defc3dbba1@xymon.invalid>

Working fine. Thanks.

?Get BlueMail for Android ?

On 14 Oct 2019, 18:09, at 18:09, Adam Thorn <user-f6b877930936@xymon.invalid> wrote:
On 14/10/2019 14:57, Ron Cohen wrote:
Still couldn't find a way around the mapping of purple to red. Will appreciate any help.
I've no idea is this is natively possible, but you could for example periodically run a script on your xymon server along the lines of:

==== begin ====
#!/bin/bash
for LINE in $(/usr/lib/xymon/client/bin/xymon 127.0.0.1 "xymondboard test=c_.* color=purple fields=hostname,testname"); do

HOSTNAME=$(echo $LINE | cut -d '|' -f 1)
TESTNAME=$(echo $LINE | cut -d '|' -f 2)

/usr/lib/xymon/client/bin/xymon 127.0.0.1 "status+24h $HOSTNAME.$TESTNAME red some error message if you like"

done
==== end ====

to find the hostname and testname for all purple c_.* tests and send a corresponding red status message with a lifetime of 24h (or whatever length you prefer).

Adam