Xymon Mailing List Archive search

force specific hosts test to always green

5 messages in this thread

list Kris Springer · Thu, 7 Jun 2018 20:27:10 -0700 ·
How do I define a specific hosts test to always report green?  Is it defined in hosts.cfg?  The particular test is an external client script that I could edit to force it always green, but I'd like to control it from the server instead. 


Thank you.

------------------------------------------------

Kris Springer

list Jeremy Laidman · Fri, 8 Jun 2018 14:21:22 +1000 ·
quoted from Kris Springer
On 8 June 2018 at 13:27, Kris Springer <user-c2caa0a7a8d5@xymon.invalid> wrote:
How do I define a specific hosts test to always report green?  Is it
defined in hosts.cfg?  The particular test is an external client script
that I could edit to force it always green, but I'd like to control it from
the server instead.
I can see two ways to do this (apart from "hack the code"):

1. use "delayred=STATUSCOLUMN:DELAY" with a really big delay

2. create a "status" channel consumer that catches the status message from
the host and then sets the colour with a xymon "modify" message

The latter option might not work, because I suspect that "modify" can only
make a colour appear worse, not better. I true, the status message could be
extracted and re-injected in entirety, with the colour changed to green.

J
list Christian Hettler · Fri, 8 Jun 2018 09:26:38 +0200 ·
Hello Kris,

in analysis.cfg you can set "color=green".

regards,

christian

On Thu, Jun 07, 2018 at 08:27:10PM -0700, Kris Springer wrote:
list Kris Springer · Fri, 8 Jun 2018 07:12:31 -0700 ·
The color=green option works for a few of the built-in tests in analysis.cfg, but I have a custom test that displays a custom column name, and the color=green option doesn't seem to do anything.  Do you have a functioning sample?


Thank you.

------------------------------------------------

Kris Springer

quoted from Christian Hettler

On 06/08/2018 12:26 AM, Christian Hettler wrote:
Hello Kris,



in analysis.cfg you can set "color=green".



regards,



christian



On Thu, Jun 07, 2018 at 08:27:10PM -0700, Kris Springer wrote:




Xymon@xymon.com

list Kris Springer · Fri, 8 Jun 2018 08:50:27 -0700 ·
delayred=updates:2000000
didn't affect anything


Thank you.

------------------------------------------------

Kris Springer

quoted from Jeremy Laidman

On 06/07/2018 09:21 PM, Jeremy Laidman wrote:
On 8 June 2018 at 13:27, Kris Springer <user-c2caa0a7a8d5@xymon.invalid> wrote:
How do I define a specific hosts test to always report green?  Is it defined in hosts.cfg?  The particular test is an external client script that I could edit to force it always green, but I'd like to control it from the server instead.  

I can see two ways to do this (apart from "hack the code"):

1. use "delayred=STATUSCOLUMN:DELAY" with a really big delay

2. create a "status" channel consumer that catches the status message from the host and then sets the colour with a xymon "modify" message

The latter option might not work, because I suspect that "modify" can only make a colour appear worse, not better. I true, the status message could be extracted and re-injected in entirety, with the colour changed to green.

J