3 Copyright (C) 2002 Stanislav Sinyagin
5 This program is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published by
7 the Free Software Foundation; either version 2 of the License, or
8 (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA.
19 $Id: monitors.xml,v 1.1 2010-12-27 00:04:29 ivan Exp $
20 Stanislav Sinyagin <ssinyagin@yahoo.com>
25 These examples show how monitors can be built in Torrus and used together
33 <token-set name="jumps">
34 <param name="comment" value="Traffic rate jumps" />
37 <token-set name="hw-failures">
38 <param name="comment" value="Holt-Winters prediction failures" />
41 <token-set name="devel">
43 value="Torrus development and testing" />
50 <!-- First define the actions -->
52 <!-- This action will put the graphs of alarmed datasources in
53 a single alarm report page -->
54 <action name="graph-hw-failures">
55 <param name="action-type" value="tset" />
56 <param name="tset-name" value="hw-failures" />
59 <action name="graph-jumps">
60 <param name="action-type" value="tset" />
61 <param name="tset-name" value="jumps" />
64 <action name="graph-devel">
65 <param name="action-type" value="tset" />
66 <param name="tset-name" value="devel" />
69 <action name="report-file">
70 <param name="action-type" value="exec" />
71 <param name="command">
72 echo `date '+%d-%b-%Y %H:%M:%S'` \
73 $TORRUS_MONITOR $TORRUS_EVENT $TORRUS_NODEPATH \
74 >> /tmp/torrus-events
76 <param name="launch-when" value="set, repeat, clear, forget" />
79 <action name="snmptrap">
80 <param name="action-type" value="exec" />
81 <param name="command" value="$TORRUS_HOME/bin/action_snmptrap" />
82 <param name="launch-when" value="set, clear" />
85 <action name="report-email">
86 <param name="action-type" value="exec" />
87 <param name="command">
88 $TORRUS_HOME/bin/action_printemail | mail ssinyagin@yahoo.com
90 <param name="launch-when" value="set, clear" />
93 <monitor name="hw-failures">
94 <param name="monitor-type" value="failures" />
96 value="graph-hw-failures, report-file" />
97 <param name="expires" value="21600" />
99 value="Holt-Winters prediction failures" />
102 <monitor name="strict-maximum">
103 <param name="monitor-type" value="expression" />
104 <param name="rpn-expr">
107 <param name="action" value="report-email" />
108 <param name="expires" value="3600" />
109 <param name="comment"
110 value="Value is more than specified maximum" />
113 <monitor name="strict-minimum">
114 <param name="monitor-type" value="expression" />
115 <param name="rpn-expr">
118 <param name="action" value="report-email" />
119 <param name="expires" value="3600" />
120 <param name="comment"
121 value="Value is less than specified minimum" />
124 <monitor name="high-jumps">
125 <param name="monitor-type" value="expression" />
126 <param name="rpn-expr">
127 {(LAST-300)},10,*,GT,
128 {(LAST)},{(LAST-300)},10,/,LT,
130 {T@(LAST)},3600,+,NOW,GE,
133 <param name="action" value="graph-jumps, report-file" />
134 <param name="expires" value="3600" />
135 <param name="comment"
136 value="Value jumped more than 10-fold in 5 minutes" />
139 <monitor name="mon-devel">
140 <param name="monitor-type" value="expression" />
141 <param name="rpn-expr">
142 {(LAST-600)},-,ABS,10485760,GT,
143 {T@(LAST)},3600,+,NOW,GE,
146 <param name="action">
147 graph-devel, report-file, snmptrap
149 <param name="expires" value="900" />
150 <param name="comment"
151 value="Traffic jumps more than 10mbps in 10 minutes" />