mirror of
https://github.com/ntop/ntopng.git
synced 2026-08-11 09:23:25 +00:00
258 lines
9.8 KiB
Groff
258 lines
9.8 KiB
Groff
.\" Automatically generated by Pod::Man 2.25 (Pod::Simple 3.16)
|
|
.\"
|
|
.\" Standard preamble:
|
|
.\" ========================================================================
|
|
.de Sp \" Vertical space (when we can't use .PP)
|
|
.if t .sp .5v
|
|
.if n .sp
|
|
..
|
|
.de Vb \" Begin verbatim text
|
|
.ft CW
|
|
.nf
|
|
.ne \\$1
|
|
..
|
|
.de Ve \" End verbatim text
|
|
.ft R
|
|
.fi
|
|
..
|
|
.\" Set up some character translations and predefined strings. \*(-- will
|
|
.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
|
|
.\" double quote, and \*(R" will give a right double quote. \*(C+ will
|
|
.\" give a nicer C++. Capital omega is used to do unbreakable dashes and
|
|
.\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff,
|
|
.\" nothing in troff, for use with C<>.
|
|
.tr \(*W-
|
|
.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
|
|
.ie n \{\
|
|
. ds -- \(*W-
|
|
. ds PI pi
|
|
. if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
|
|
. if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch
|
|
. ds L" ""
|
|
. ds R" ""
|
|
. ds C` ""
|
|
. ds C' ""
|
|
'br\}
|
|
.el\{\
|
|
. ds -- \|\(em\|
|
|
. ds PI \(*p
|
|
. ds L" ``
|
|
. ds R" ''
|
|
'br\}
|
|
.\"
|
|
.\" Escape single quotes in literal strings from groff's Unicode transform.
|
|
.ie \n(.g .ds Aq \(aq
|
|
.el .ds Aq '
|
|
.\"
|
|
.\" If the F register is turned on, we'll generate index entries on stderr for
|
|
.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
|
|
.\" entries marked with X<> in POD. Of course, you'll have to process the
|
|
.\" output yourself in some meaningful fashion.
|
|
.ie \nF \{\
|
|
. de IX
|
|
. tm Index:\\$1\t\\n%\t"\\$2"
|
|
..
|
|
. nr % 0
|
|
. rr F
|
|
.\}
|
|
.el \{\
|
|
. de IX
|
|
..
|
|
.\}
|
|
.\"
|
|
.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
|
|
.\" Fear. Run. Save yourself. No user-serviceable parts.
|
|
. \" fudge factors for nroff and troff
|
|
.if n \{\
|
|
. ds #H 0
|
|
. ds #V .8m
|
|
. ds #F .3m
|
|
. ds #[ \f1
|
|
. ds #] \fP
|
|
.\}
|
|
.if t \{\
|
|
. ds #H ((1u-(\\\\n(.fu%2u))*.13m)
|
|
. ds #V .6m
|
|
. ds #F 0
|
|
. ds #[ \&
|
|
. ds #] \&
|
|
.\}
|
|
. \" simple accents for nroff and troff
|
|
.if n \{\
|
|
. ds ' \&
|
|
. ds ` \&
|
|
. ds ^ \&
|
|
. ds , \&
|
|
. ds ~ ~
|
|
. ds /
|
|
.\}
|
|
.if t \{\
|
|
. ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
|
|
. ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
|
|
. ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
|
|
. ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
|
|
. ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
|
|
. ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
|
|
.\}
|
|
. \" troff and (daisy-wheel) nroff accents
|
|
.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
|
|
.ds 8 \h'\*(#H'\(*b\h'-\*(#H'
|
|
.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
|
|
.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
|
|
.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
|
|
.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
|
|
.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
|
|
.ds ae a\h'-(\w'a'u*4/10)'e
|
|
.ds Ae A\h'-(\w'A'u*4/10)'E
|
|
. \" corrections for vroff
|
|
.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
|
|
.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
|
|
. \" for low resolution devices (crt and lpr)
|
|
.if \n(.H>23 .if \n(.V>19 \
|
|
\{\
|
|
. ds : e
|
|
. ds 8 ss
|
|
. ds o a
|
|
. ds d- d\h'-1'\(ga
|
|
. ds D- D\h'-1'\(hy
|
|
. ds th \o'bp'
|
|
. ds Th \o'LP'
|
|
. ds ae ae
|
|
. ds Ae AE
|
|
.\}
|
|
.rm #[ #] #H #V #F C
|
|
.\" ========================================================================
|
|
.\"
|
|
.IX Title "RRDGRAPH_DATA 1"
|
|
.TH RRDGRAPH_DATA 1 "2013-05-23" "1.4.8" "rrdtool"
|
|
.\" For nroff, turn off justification. Always turn off hyphenation; it makes
|
|
.\" way too many mistakes in technical documents.
|
|
.if n .ad l
|
|
.nh
|
|
.SH "NAME"
|
|
rrdgraph_data \- preparing data for graphing in rrdtool graph
|
|
.SH "SYNOPSIS"
|
|
.IX Header "SYNOPSIS"
|
|
\&\fB\s-1DEF:\s0\fR\fI<vname>\fR=\fI<rrdfile>\fR:\fI<ds\-name>\fR:\fI<\s-1CF\s0>\fR[:step=\fI<step>\fR][:start=\fI<time>\fR][:end=\fI<time>\fR][:reduce=\fI<\f(BI\s-1CF\s0\fI>\fR]
|
|
.PP
|
|
\&\fB\s-1VDEF\s0\fR:\fIvname\fR=\fI\s-1RPN\s0 expression\fR
|
|
.PP
|
|
\&\fB\s-1CDEF\s0\fR:\fIvname\fR=\fI\s-1RPN\s0 expression\fR
|
|
.SH "DESCRIPTION"
|
|
.IX Header "DESCRIPTION"
|
|
These three instructions extract data values out of the \fB\s-1RRD\s0\fR files,
|
|
optionally altering them (think, for example, of a bytes to bits
|
|
conversion). If so desired, you can also define variables containing
|
|
useful information such as maximum, minimum etcetera. Two of the
|
|
instructions use a language called \fB\s-1RPN\s0\fR which is described in its
|
|
own manual page.
|
|
.PP
|
|
Variable names (\fIvname\fR) must be made up strings of the following characters
|
|
\&\f(CW\*(C`A\-Z, a\-z, 0\-9, \-,_\*(C'\fR and a maximum length of 255 characters.
|
|
.PP
|
|
When picking variable names, make sure you do not choose a name that is
|
|
already taken by an \s-1RPN\s0 operator. A safe bet it to use lowercase or
|
|
mixed case names for variables since operators will always be in uppercase.
|
|
.SH "DEF"
|
|
.IX Header "DEF"
|
|
\&\fB\s-1DEF:\s0\fR\fI<vname>\fR=\fI<rrdfile>\fR:\fI<ds\-name>\fR:\fI<\s-1CF\s0>\fR[:step=\fI<step>\fR][:start=\fI<time>\fR][:end=\fI<time>\fR][:reduce=\fI<\f(BI\s-1CF\s0\fI>\fR]
|
|
.PP
|
|
This command fetches data from an \fB\s-1RRD\s0\fR file. The virtual name
|
|
\&\fIvname\fR can then be used throughout the rest of the script. By
|
|
default, an \fB\s-1RRA\s0\fR which contains the correct consolidated data
|
|
at an appropriate resolution will be chosen. The resolution can
|
|
be overridden with the \-\-step option.
|
|
The resolution can again be overridden by specifying the \fBstep size\fR.
|
|
The time span of this data is the same as for the graph by default,
|
|
you can override this by specifying \fBstart and end\fR. Remember to
|
|
escape colons in the time specification!
|
|
.PP
|
|
If the resolution of the data is higher than the resolution of the
|
|
graph, the data will be further consolidated. This may result in
|
|
a graph that spans slightly more time than requested.
|
|
Ideally each point in the graph should correspond with one \fB\s-1CDP\s0\fR
|
|
from an \fB\s-1RRA\s0\fR. For instance, if your \fB\s-1RRD\s0\fR has an \fB\s-1RRA\s0\fR with
|
|
a resolution of 1800 seconds per \fB\s-1CDP\s0\fR, you should create an
|
|
image with width 400 and time span 400*1800 seconds (use appropriate
|
|
start and end times, such as \f(CW\*(C`\-\-start end\-8days8hours\*(C'\fR).
|
|
.PP
|
|
If consolidation needs to be done, the \fB\s-1CF\s0\fR of the \fB\s-1RRA\s0\fR specified in the
|
|
\&\fB\s-1DEF\s0\fR itself will be used to reduce the data density. This behavior can
|
|
be changed using \f(CW\*(C`:reduce=\f(CI<\f(CBCF\f(CI>\f(CW\*(C'\fR. This optional parameter
|
|
specifies the \fB\s-1CF\s0\fR to use during the data reduction phase.
|
|
.PP
|
|
Example:
|
|
.PP
|
|
.Vb 4
|
|
\& DEF:ds0=router.rrd:ds0:AVERAGE
|
|
\& DEF:ds0weekly=router.rrd:ds0:AVERAGE:step=7200
|
|
\& DEF:ds0weekly=router.rrd:ds0:AVERAGE:start=end\-1h
|
|
\& DEF:ds0weekly=router.rrd:ds0:AVERAGE:start=11\e:00:end=start+1h
|
|
.Ve
|
|
.SH "VDEF"
|
|
.IX Header "VDEF"
|
|
\&\fB\s-1VDEF\s0\fR:\fIvname\fR=\fI\s-1RPN\s0 expression\fR
|
|
.PP
|
|
This command returns a value and/or a time according to the \fB\s-1RPN\s0\fR
|
|
statements used. The resulting \fIvname\fR will, depending on the
|
|
functions used, have a value and a time component. When you use
|
|
this \fIvname\fR in another \fB\s-1RPN\s0\fR expression, you are effectively
|
|
inserting its value just as if you had put a number at that place.
|
|
The variable can also be used in the various graph and print
|
|
elements.
|
|
.PP
|
|
Example: \f(CW\*(C`VDEF:avg=mydata,AVERAGE\*(C'\fR
|
|
.PP
|
|
Note that currently only aggregation functions work in \s-1VDEF\s0 rpn expressions.
|
|
Patches to change this are welcome.
|
|
.SH "CDEF"
|
|
.IX Header "CDEF"
|
|
\&\fB\s-1CDEF\s0\fR:\fIvname\fR=\fI\s-1RPN\s0 expression\fR
|
|
.PP
|
|
This command creates a new set of data points (in memory only, not
|
|
in the \fB\s-1RRD\s0\fR file) out of one or more other data series. The \fB\s-1RPN\s0\fR
|
|
instructions are used to evaluate a mathematical function on each
|
|
data point. The resulting \fIvname\fR can then be used further on in
|
|
the script, just as if it were generated by a \fB\s-1DEF\s0\fR instruction.
|
|
.PP
|
|
Example: \f(CW\*(C`CDEF:mydatabits=mydata,8,*\*(C'\fR
|
|
.SH "About CDEF versus VDEF"
|
|
.IX Header "About CDEF versus VDEF"
|
|
At some point in processing, \fBRRDtool\fR has gathered an array of rates
|
|
ready to display.
|
|
.PP
|
|
\&\fB\s-1CDEF\s0\fR works on such an array. For example, \fICDEF:new=ds0,8,*\fR
|
|
would multiply each of the array members by eight (probably
|
|
transforming bytes into bits). The result is an array containing the
|
|
new values.
|
|
.PP
|
|
\&\fB\s-1VDEF\s0\fR also works on such an array but in a different way. For
|
|
example, \fIVDEF:max=ds0,MAXIMUM\fR would scan each of the array members
|
|
and store the maximum value.
|
|
.SS "When do you use \fB\s-1VDEF\s0\fP versus \fB\s-1CDEF\s0\fP?"
|
|
.IX Subsection "When do you use VDEF versus CDEF?"
|
|
Use \fB\s-1CDEF\s0\fR to transform your data prior to graphing. In the above
|
|
example, we'd use a \fB\s-1CDEF\s0\fR to transform bytes to bits before
|
|
graphing the bits.
|
|
.PP
|
|
You use a \fB\s-1VDEF\s0\fR if you want \fImax(1,5,3,2,4)\fR to return five which
|
|
would be displayed in the graph's legend (to answer, what was the
|
|
maximum value during the graph period).
|
|
.PP
|
|
If you want to apply 'complex' operations to the result of a \s-1VDEF\s0 you have
|
|
to use a \s-1CDEF\s0 again since VDEFs only look like \s-1RPN\s0 expressions, they aren't
|
|
really.
|
|
.SH "SEE ALSO"
|
|
.IX Header "SEE ALSO"
|
|
rrdgraph gives an overview of how \fBrrdtool graph\fR works.
|
|
rrdgraph_data describes \fB\s-1DEF\s0\fR,\fB\s-1CDEF\s0\fR and \fB\s-1VDEF\s0\fR in detail.
|
|
rrdgraph_rpn describes the \fB\s-1RPN\s0\fR language used in the \fB?DEF\fR statements.
|
|
rrdgraph_graph page describes all of the graph and print functions.
|
|
.PP
|
|
Make sure to read rrdgraph_examples for tips&tricks.
|
|
.SH "AUTHOR"
|
|
.IX Header "AUTHOR"
|
|
Program by Tobias Oetiker <tobi@oetiker.ch>
|
|
.PP
|
|
This manual page by Alex van den Bogaerdt <alex@vandenbogaerdt.nl>
|
|
with corrections and/or additions by several people
|