1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of COMBO.CFG</TITLE>
</HEAD><BODY>
<H1>COMBO.CFG</H1>
Section: File Formats (5)<BR>Updated: Version 4.3.17: 23 Feb 2014<BR><A HREF="#index">Index</A>
<A HREF="../index.html">Return to Main Contents</A><HR>
<A NAME="lbAB"> </A>
<H2>NAME</H2>
combo.cfg - Configuration of combostatus tool
<P>
<A NAME="lbAC"> </A>
<H2>SYNOPSIS</H2>
<B>$XYMONHOME/etc/combo.cfg</B>
<P>
<A NAME="lbAD"> </A>
<H2>DESCRIPTION</H2>
<I><A HREF="../man1/combostatus.1.html">combostatus</A>(1)</I>
uses it's own configuration file, $XYMONHOME/etc/combo.cfg
Each line in this file defines a combined test.
<P>
<A NAME="lbAE"> </A>
<H2>FILE FORMAT</H2>
Each line of the file defines a new combined test. Blank lines and lines
starting with a hash mark (#) are treated as comments and ignored.
<P>
The configuration file uses the hostnames and testnames
that are already used in your Xymon hosts.cfg file. These are
then combined using normal logical operators - "||" for "or", "&&" for
"and" etc.
<P>
A simple test - e.g. "Web1.http" - results in the value "1" if
the "http" test for server "Web1" is green, yellow or clear. It yields the
value "0" if it is red, purple or blue.
<P>
Apart from the logical operations, you can also do integer arithmetic
and comparisons. E.g. the following is valid:
<P>
WebCluster.http = (Web1.http + Web2.http + Web3.http) >= 2
<P>
This test is green if two or more of the http tests for Web1, Web2 and Web3
are green.
<P>
The full range of operators are:
<P>
<BR> + Add
<BR> - Subtract
<BR> * Multiply
<BR> / Divide
<BR> % Modulo
<BR> | Bit-wise "or"
<BR> & Bit-wise "and"
<BR> || Logical "or"
<BR> && Logical "and"
<BR> > Greater than
<BR> < Less than
<BR> >= Greater than or equal
<BR> <= Less than or equal
<BR> == Equal
<P>
There is currently no support for a "not" operator. If you need it,
use the transcription "(host.test == 0)" instead of "!host.test".
<P>
NB: All operators have EQUAL PRECEDENCE. If you need something evaluated
in a specific order, use parentheses to group the expressions together.
<P>
If the expression comes out as "0", the combined test goes red. If it comes
out as non-zero, the combined test is green.
<P>
Note: If the expression involves hostnames with a character that is also
an operator - e.g. if you have a host "t1-router-newyork.foo.com" with a
dash in the hostname - then the operator-character must be escaped with
a backslash '\' in the expression, or it will be interpreted as an operator.
E.g. like this:
<P>
<BR> nyc.conn = (t1\-router\-nyc.conn || backup\-router\-nyc.conn)
<P>
<P>
<A NAME="lbAF"> </A>
<H2>EXAMPLE</H2>
WebCluster.http = (Web1.http || Web2.http)
<BR>
AppSrvCluster.procs = (AppSrv1.conn && AppSrv1.procs) || (AppSrv2.conn && AppSrv2.procs)
<BR>
Customer.cluster = WebCluster.http && AppSrvCluster.procs
<BR>
<P>
The first line defines a new test, with hostname "WebCluster" and the
columnname "http". It will be green if the http test on either the
"Web1" or the "Web2" server is green.
<P>
The second line defines a "procs" test for the "AppSrvCluster" host.
Each of the AppSrv1 and AppSrv2 hosts is checked for "conn" (ping)
and their "procs" test. On each host, both of these must be green,
but the combined test is green if that condition is fulfilled on
just one of the hosts.
<P>
The third line uses the two first tests to build a "double combined"
test, defining a test that shows the overall health of the system.
<P>
<P>
<A NAME="lbAG"> </A>
<H2>FILES</H2>
<B>$XYMONHOME/etc/combo.cfg</B>
<P>
<A NAME="lbAH"> </A>
<H2>SEE ALSO</H2>
<A HREF="../man1/combostatus.1.html">combostatus</A>(1)
<P>
<P>
<HR>
<A NAME="index"> </A><H2>Index</H2>
<DL>
<DT><A HREF="#lbAB">NAME</A><DD>
<DT><A HREF="#lbAC">SYNOPSIS</A><DD>
<DT><A HREF="#lbAD">DESCRIPTION</A><DD>
<DT><A HREF="#lbAE">FILE FORMAT</A><DD>
<DT><A HREF="#lbAF">EXAMPLE</A><DD>
<DT><A HREF="#lbAG">FILES</A><DD>
<DT><A HREF="#lbAH">SEE ALSO</A><DD>
</DL>
<HR>
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 09:41:02 GMT, February 23, 2014
</BODY>
</HTML>
|