18 May
2011
18 May
'11
1:32 a.m.
Suppose I have a five-server cluster, and on each server there's a calculated value, call it Q, and an ext test "qlength" that operates on Q and returns a color and a message containing Q.
We want to make a server-side test that does some alerting based on aggregate values of Q across all five servers in the cluster. Not a combo test, we want to do math, like Sum (Q1...Qn) >Threshold.
*One* way to get Q for each server is to write a server-side ext test that loops a wget over each host, something like:
wget /dev/null
http://xymon/xymon-cgi/svcstatus.sh\?HOST=myhost.example.com\&SERVICE=qlength
then parse each server's Q info out of the html and do my arithmetic, but is there a more direct way?
thanks for any pointers clues or code snippets Betsy