90b216bf63f6d3bd33d4f86d57f2910035d21fc6
[rrdtool.git] / doc / rrdtune.pod
1 =head1 NAME
2
3 rrdtool tune - Modify some basic properties of a Round Robin Database
4
5 =for html <div align="right"><a href="rrdtune.pdf">PDF</a> version.</div>
6
7 =head1 SYNOPSIS
8
9 B<rrdtool> B<tune> I<filename> 
10 S<[B<--heartbeat>|B<-h> I<ds-name>:I<heartbeat>]> 
11 S<[B<--minimum>|B<-i> I<ds-name>:I<min>]>
12 S<[B<--maximum>|B<-a> I<ds-name>:I<max>]>
13 S<[B<--data-source-type>|B<-d> I<ds-name>:I<DST>]>
14 S<[B<--data-source-rename>|B<-r> I<old-name>:I<new-name>]>
15 S<[B<--deltapos> I<scale-value>]>
16 S<[B<--deltaneg> I<scale-value>]>
17 S<[B<--failure-threshold> I<failure-threshold>]>
18 S<[B<--window-length> I<window-length>]>
19 S<[B<--alpha> I<adaption-parameter>]>
20 S<[B<--beta> I<adaption-parameter>]>
21 S<[B<--gamma> I<adaption-parameter>]>
22 S<[B<--gamma-deviation> I<adaption-parameter>]>
23 S<[B<--aberrant-reset> I<ds-name>]>
24
25 =head1 DESCRIPTION
26
27 The tune option allows you to alter some of the basic configuration
28 values stored in the header area of a Round Robin Database (B<RRD>).
29
30 One application of the B<tune> function is to relax the 
31 validation rules on an B<RRD>. This allows to fill a new B<RRD> with
32 data available in larger intervals than what you would normally want
33 to permit. Be very careful with tune operations for COMPUTE data sources.
34 Setting the I<min>, I<max>, and  I<heartbeat> for a COMPUTE data source
35 without changing the data source type to a non-COMPUTE B<DST> WILL corrupt
36 the data source header in the B<RRD>.
37
38 A second application of the B<tune> function is to set or alter parameters
39 used by the specialized function B<RRAs> for aberrant behavior detection.
40
41 =over 8
42
43 =item I<filename>
44
45 The name of the B<RRD> you want to tune.
46
47 =item S<B<--heartbeat>|B<-h> I<ds-name>:I<heartbeat>>
48
49 modify the I<heartbeat> of a data source. By setting this to a high
50 value the rrd will accept things like one value per day ...
51
52 =item S<B<--minimum>|B<-i> I<ds-name>:I<min>>
53
54 alter the minimum value acceptable as input from the data source.
55 Setting I<min> to 'U' will disable this limit.
56
57 =item S<B<--maximum>|B<-a> I<ds-name>:I<max>>
58
59 alter the maximum value acceptable as input from the data source.
60 Setting I<max> to 'U' will disable this limit.
61
62 =item S<B<--data-source-type>|B<-d> I<ds-name>:I<DST>>
63
64 alter the type B<DST> of a data source.
65
66 =item S<B<--data-source-rename>|B<-r> I<old-name>:I<new-name>>
67
68 rename a data source
69
70 =item S<B<--deltapos> I<scale-value>>
71
72 Alter the deviation scaling factor for the upper bound of the confidence band
73 used internally to calculate violations for the FAILURES B<RRA>. The default
74 value is 2. Note that this parameter is not related to graphing confidence
75 bounds, that scale factor must be specified as a CDEF argument to generate 
76 a graph with confidence bounds. The graph scale factor need not agree with the 
77 value used internally by the FAILURES B<RRA>.
78
79 =item S<B<--deltaneg> I<scale-value>>
80
81 Alter the deviation scaling factor for the lower bound of the confidence band
82 used internally to calculate violations for the FAILURES B<RRA>. The default
83 value is 2. As with B<--deltapos>, this argument is unrelated to the scale
84 factor chosen when graphing confidence bounds.
85
86 =item S<B<--failure-threshold> I<failure-threshold>>
87
88 Alter the number of confidence bound violations that constitute a failure for
89 purposes of the FAILURES B<RRA>. This must be an integer less than or equal to
90 the window length of the FAILURES B<RRA>. This restriction is not verified by
91 the tune option, so one can reset failure-threshold and window-length 
92 simultaneously. Setting this option will reset the count of violations to 0.
93
94 =item S<B<--window-length> I<window-length>>
95
96 Alter the number of time points in the temporal window for determining failures.
97 This must be an integer greater than or equal to the window length of the
98 FAILURES B<RRA> and less than or equal to 28. Setting this option will reset the
99 count of violations to 0.
100
101 =item S<B<--alpha> I<adaption-parameter>>
102
103 Alter the intercept adaptation parameter for the Holt-Winters forecasting algorithm.
104 Must be between 0 and 1.
105
106 =item S<B<--beta> I<adaption-parameter>>
107
108 Alter the slope adaptation parameter for the Holt-Winters forecasting algorithm.
109 Must be between 0 and 1.
110
111 =item S<B<--gamma> I<adaption-parameter>>
112
113 Alter the seasonal coefficient adaptation parameter for the SEASONAL
114 B<RRA>. Must be between 0 and 1.
115
116 =item S<B<--gamma-deviation> I<adaption-parameter>>
117
118 Alter the seasonal deviation adaptation parameter for the DEVSEASONAL
119 B<RRA>. Must be between 0 and 1.
120
121 =item S<B<--aberrant-reset> I<ds-name>>
122
123 This option causes the aberrant behavior detection algorithm to reset
124 for the specified data source; that is, forget all it is has learn.
125 Specifically, for the HWPREDICT B<RRA>, it sets the intercept and slope
126 coefficients to unknown. For the SEASONAL B<RRA>, it sets all seasonal
127 coefficients to unknown. For the DEVSEASONL B<RRA>, it sets all seasonal
128 deviation coefficients to unknown. For the FAILURES B<RRA>, it erases
129 the violation history. Note that reset does not erase past predictions
130 (the values of the HWPREDICT B<RRA>), predicted deviations (the values of the
131 DEVPREDICT B<RRA>), or failure history (the values of the FAILURES B<RRA>).
132 This option will function even if not all the listed B<RRAs> are present.
133
134 Due to the implementation of this option, there is an indirect impact on
135 other data sources in the RRD. A smoothing algorithm is applied to
136 SEASONAL and DEVSEASONAL values on a periodic basis. During bootstrap
137 initialization this smoothing is deferred. For efficiency, the implementation
138 of smoothing is not data source specific. This means that utilizing
139 reset for one data source will delay running the smoothing algorithm
140 for all data sources in the file. This is unlikely to have serious
141 consequences, unless the data being collected for the non-reset data soures 
142 is unusually volatile during the reinitialization period of the reset 
143 data source.
144
145 Use of this tuning option is advised when the behavior of the data source 
146 time series changes in a drastic and permanent manner.
147
148 =back
149
150 =head1 EXAMPLE 1
151
152 C<rrdtool tune data.rrd -h in:100000 -h out:100000 -h through:100000>
153
154 Set the minimum required heartbeat for data sources 'in', 'out' 
155 and 'through' to 10000 seconds which is a little over one day in data.rrd.
156 This would allow to feed old data from mrtg-2.0 right into
157 rrdtool without generating *UNKNOWN* entries.
158
159 =head1 EXAMPLE 2
160
161 C<rrdtool tune monitor.rrd --window-length 5 --failure-threshold 3>
162
163 If the FAILURES B<RRA> is implicitly created, the default window-length is 9 and 
164 the default failure-thresold is 7. This command now defines a failure as 3 or more
165 violations in a temporal window of 5 time points.
166
167 =head1 AUTHOR
168
169 Tobias Oetiker <oetiker@ee.ethz.ch>
170