Blame doc/mrtg.1

Packit 667938
.\" Automatically generated by Pod::Man 2.28 (Pod::Simple 3.29)
Packit 667938
.\"
Packit 667938
.\" Standard preamble:
Packit 667938
.\" ========================================================================
Packit 667938
.de Sp \" Vertical space (when we can't use .PP)
Packit 667938
.if t .sp .5v
Packit 667938
.if n .sp
Packit 667938
..
Packit 667938
.de Vb \" Begin verbatim text
Packit 667938
.ft CW
Packit 667938
.nf
Packit 667938
.ne \\$1
Packit 667938
..
Packit 667938
.de Ve \" End verbatim text
Packit 667938
.ft R
Packit 667938
.fi
Packit 667938
..
Packit 667938
.\" Set up some character translations and predefined strings.  \*(-- will
Packit 667938
.\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left
Packit 667938
.\" double quote, and \*(R" will give a right double quote.  \*(C+ will
Packit 667938
.\" give a nicer C++.  Capital omega is used to do unbreakable dashes and
Packit 667938
.\" therefore won't be available.  \*(C` and \*(C' expand to `' in nroff,
Packit 667938
.\" nothing in troff, for use with C<>.
Packit 667938
.tr \(*W-
Packit 667938
.ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p'
Packit 667938
.ie n \{\
Packit 667938
.    ds -- \(*W-
Packit 667938
.    ds PI pi
Packit 667938
.    if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch
Packit 667938
.    if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\"  diablo 12 pitch
Packit 667938
.    ds L" ""
Packit 667938
.    ds R" ""
Packit 667938
.    ds C` ""
Packit 667938
.    ds C' ""
Packit 667938
'br\}
Packit 667938
.el\{\
Packit 667938
.    ds -- \|\(em\|
Packit 667938
.    ds PI \(*p
Packit 667938
.    ds L" ``
Packit 667938
.    ds R" ''
Packit 667938
.    ds C`
Packit 667938
.    ds C'
Packit 667938
'br\}
Packit 667938
.\"
Packit 667938
.\" Escape single quotes in literal strings from groff's Unicode transform.
Packit 667938
.ie \n(.g .ds Aq \(aq
Packit 667938
.el       .ds Aq '
Packit 667938
.\"
Packit 667938
.\" If the F register is turned on, we'll generate index entries on stderr for
Packit 667938
.\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index
Packit 667938
.\" entries marked with X<> in POD.  Of course, you'll have to process the
Packit 667938
.\" output yourself in some meaningful fashion.
Packit 667938
.\"
Packit 667938
.\" Avoid warning from groff about undefined register 'F'.
Packit 667938
.de IX
Packit 667938
..
Packit 667938
.nr rF 0
Packit 667938
.if \n(.g .if rF .nr rF 1
Packit 667938
.if (\n(rF:(\n(.g==0)) \{
Packit 667938
.    if \nF \{
Packit 667938
.        de IX
Packit 667938
.        tm Index:\\$1\t\\n%\t"\\$2"
Packit 667938
..
Packit 667938
.        if !\nF==2 \{
Packit 667938
.            nr % 0
Packit 667938
.            nr F 2
Packit 667938
.        \}
Packit 667938
.    \}
Packit 667938
.\}
Packit 667938
.rr rF
Packit 667938
.\"
Packit 667938
.\" Accent mark definitions (@(#)ms.acc 1.5 88/02/08 SMI; from UCB 4.2).
Packit 667938
.\" Fear.  Run.  Save yourself.  No user-serviceable parts.
Packit 667938
.    \" fudge factors for nroff and troff
Packit 667938
.if n \{\
Packit 667938
.    ds #H 0
Packit 667938
.    ds #V .8m
Packit 667938
.    ds #F .3m
Packit 667938
.    ds #[ \f1
Packit 667938
.    ds #] \fP
Packit 667938
.\}
Packit 667938
.if t \{\
Packit 667938
.    ds #H ((1u-(\\\\n(.fu%2u))*.13m)
Packit 667938
.    ds #V .6m
Packit 667938
.    ds #F 0
Packit 667938
.    ds #[ \&
Packit 667938
.    ds #] \&
Packit 667938
.\}
Packit 667938
.    \" simple accents for nroff and troff
Packit 667938
.if n \{\
Packit 667938
.    ds ' \&
Packit 667938
.    ds ` \&
Packit 667938
.    ds ^ \&
Packit 667938
.    ds , \&
Packit 667938
.    ds ~ ~
Packit 667938
.    ds /
Packit 667938
.\}
Packit 667938
.if t \{\
Packit 667938
.    ds ' \\k:\h'-(\\n(.wu*8/10-\*(#H)'\'\h"|\\n:u"
Packit 667938
.    ds ` \\k:\h'-(\\n(.wu*8/10-\*(#H)'\`\h'|\\n:u'
Packit 667938
.    ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'^\h'|\\n:u'
Packit 667938
.    ds , \\k:\h'-(\\n(.wu*8/10)',\h'|\\n:u'
Packit 667938
.    ds ~ \\k:\h'-(\\n(.wu-\*(#H-.1m)'~\h'|\\n:u'
Packit 667938
.    ds / \\k:\h'-(\\n(.wu*8/10-\*(#H)'\z\(sl\h'|\\n:u'
Packit 667938
.\}
Packit 667938
.    \" troff and (daisy-wheel) nroff accents
Packit 667938
.ds : \\k:\h'-(\\n(.wu*8/10-\*(#H+.1m+\*(#F)'\v'-\*(#V'\z.\h'.2m+\*(#F'.\h'|\\n:u'\v'\*(#V'
Packit 667938
.ds 8 \h'\*(#H'\(*b\h'-\*(#H'
Packit 667938
.ds o \\k:\h'-(\\n(.wu+\w'\(de'u-\*(#H)/2u'\v'-.3n'\*(#[\z\(de\v'.3n'\h'|\\n:u'\*(#]
Packit 667938
.ds d- \h'\*(#H'\(pd\h'-\w'~'u'\v'-.25m'\f2\(hy\fP\v'.25m'\h'-\*(#H'
Packit 667938
.ds D- D\\k:\h'-\w'D'u'\v'-.11m'\z\(hy\v'.11m'\h'|\\n:u'
Packit 667938
.ds th \*(#[\v'.3m'\s+1I\s-1\v'-.3m'\h'-(\w'I'u*2/3)'\s-1o\s+1\*(#]
Packit 667938
.ds Th \*(#[\s+2I\s-2\h'-\w'I'u*3/5'\v'-.3m'o\v'.3m'\*(#]
Packit 667938
.ds ae a\h'-(\w'a'u*4/10)'e
Packit 667938
.ds Ae A\h'-(\w'A'u*4/10)'E
Packit 667938
.    \" corrections for vroff
Packit 667938
.if v .ds ~ \\k:\h'-(\\n(.wu*9/10-\*(#H)'\s-2\u~\d\s+2\h'|\\n:u'
Packit 667938
.if v .ds ^ \\k:\h'-(\\n(.wu*10/11-\*(#H)'\v'-.4m'^\v'.4m'\h'|\\n:u'
Packit 667938
.    \" for low resolution devices (crt and lpr)
Packit 667938
.if \n(.H>23 .if \n(.V>19 \
Packit 667938
\{\
Packit 667938
.    ds : e
Packit 667938
.    ds 8 ss
Packit 667938
.    ds o a
Packit 667938
.    ds d- d\h'-1'\(ga
Packit 667938
.    ds D- D\h'-1'\(hy
Packit 667938
.    ds th \o'bp'
Packit 667938
.    ds Th \o'LP'
Packit 667938
.    ds ae ae
Packit 667938
.    ds Ae AE
Packit 667938
.\}
Packit 667938
.rm #[ #] #H #V #F C
Packit 667938
.\" ========================================================================
Packit 667938
.\"
Packit 667938
.IX Title "MRTG 1"
Packit 667938
.TH MRTG 1 "2018-07-13" "2.17.7" "mrtg"
Packit 667938
.\" For nroff, turn off justification.  Always turn off hyphenation; it makes
Packit 667938
.\" way too many mistakes in technical documents.
Packit 667938
.if n .ad l
Packit 667938
.nh
Packit 667938
.SH "NAME"
Packit 667938
mrtg \- What is MRTG ?
Packit 667938
.SH "DESCRIPTION"
Packit 667938
.IX Header "DESCRIPTION"
Packit 667938
The Multi Router Traffic Grapher (\s-1MRTG\s0) is a tool to monitor
Packit 667938
the traffic load on network links.  \s-1MRTG\s0 generates \s-1HTML\s0 pages
Packit 667938
containing \s-1PNG\s0 images which provide a \s-1LIVE\s0 visual representation of
Packit 667938
this traffic.
Packit 667938
.PP
Packit 667938
Go to http://oss.oetiker.ch/mrtg for all the details about mrtg.
Packit 667938
.SH "HIGHLIGHTS"
Packit 667938
.IX Header "HIGHLIGHTS"
Packit 667938
.IP "Portable" 4
Packit 667938
.IX Item "Portable"
Packit 667938
\&\s-1MRTG\s0 works on most \s-1UNIX\s0 platforms and Windows \s-1NT.\s0
Packit 667938
.IP "Perl" 4
Packit 667938
.IX Item "Perl"
Packit 667938
\&\s-1MRTG\s0 is written in Perl and comes with full source.
Packit 667938
.IP "Portable \s-1SNMP\s0" 4
Packit 667938
.IX Item "Portable SNMP"
Packit 667938
\&\s-1MRTG\s0 Uses a highly portable \s-1SNMP\s0 implementation written entirely in
Packit 667938
Perl (thanks to Simon Leinen). There is no need to install any
Packit 667938
external \s-1SNMP\s0 package.
Packit 667938
.IP "SNMPv2c support" 4
Packit 667938
.IX Item "SNMPv2c support"
Packit 667938
\&\s-1MRTG\s0 can read the new SNMPv2c 64bit counters. No more counter wrapping.
Packit 667938
.IP "Reliable Interface Identification" 4
Packit 667938
.IX Item "Reliable Interface Identification"
Packit 667938
Router interfaces can be identified by \s-1IP\s0 address, description and
Packit 667938
ethernet address in addition to the normal interface number.
Packit 667938
.IP "Constant size Logfiles" 4
Packit 667938
.IX Item "Constant size Logfiles"
Packit 667938
\&\s-1MRTG\s0's logfiles do \s-1NOT\s0 grow thanks to the use of a unique data
Packit 667938
consolidation algorithm.
Packit 667938
.IP "Automatic Configuration" 4
Packit 667938
.IX Item "Automatic Configuration"
Packit 667938
\&\s-1MRTG\s0 comes with a set of configuration tools which make configuration and
Packit 667938
setup very simple.
Packit 667938
.IP "Performance" 4
Packit 667938
.IX Item "Performance"
Packit 667938
Time critical routines are written in C (thanks to the initiative
Packit 667938
of Dave Rand my Co-Author).
Packit 667938
.IP "\s-1GIF\s0 free Graphics" 4
Packit 667938
.IX Item "GIF free Graphics"
Packit 667938
Graphics are generated directly in \s-1PNG\s0 format using the
Packit 667938
\&\s-1GD\s0 library by Thomas Boutell.
Packit 667938
.IP "Customizability" 4
Packit 667938
.IX Item "Customizability"
Packit 667938
The look of the webpages produced by \s-1MRTG\s0 is highly configurable.
Packit 667938
.IP "RRDtool" 4
Packit 667938
.IX Item "RRDtool"
Packit 667938
\&\s-1MRTG\s0 has built-in hooks for using RRDtool. If you are strapped for
Packit 667938
performance this may help.
Packit 667938
.SH "DETAILS"
Packit 667938
.IX Header "DETAILS"
Packit 667938
\&\s-1MRTG\s0 consists of a Perl script which uses \s-1SNMP\s0 to read the traffic
Packit 667938
counters of your routers and a fast C program which logs the traffic
Packit 667938
data and creates beautiful graphs representing the traffic on the
Packit 667938
monitored network connection. These graphs are embedded into webpages
Packit 667938
which can be viewed from any modern Web-browser.
Packit 667938
.PP
Packit 667938
In addition to a detailed daily view, \s-1MRTG\s0 also creates visual
Packit 667938
representations of the traffic seen during the last seven days, the
Packit 667938
last five weeks and the last twelve months. This is possible because
Packit 667938
\&\s-1MRTG\s0 keeps a log of all the data it has pulled from the router. This
Packit 667938
log is automatically consolidated so that it does not grow over time,
Packit 667938
but still contains all the relevant data for all the traffic seen over
Packit 667938
the last two years.  This is all performed in an efficient manner.
Packit 667938
Therefore you can monitor 200 or more network links from any halfway
Packit 667938
decent \s-1UNIX\s0 box.
Packit 667938
.PP
Packit 667938
\&\s-1MRTG\s0 is not limited to monitoring traffic, though.  It is possible to
Packit 667938
monitor any \s-1SNMP\s0 variable you choose. You can even use an
Packit 667938
external program to gather the data which should be monitored via
Packit 667938
\&\s-1MRTG.\s0 People are using \s-1MRTG,\s0 to monitor things such as System Load,
Packit 667938
Login Sessions, Modem availability and more. \s-1MRTG\s0 even allows you to
Packit 667938
accumulate two or more data sources into a single graph.
Packit 667938
.SH "HISTORY"
Packit 667938
.IX Header "HISTORY"
Packit 667938
In 1994 I was working at a site where we had one
Packit 667938
64kbit line to the outside world. Obviously, everybody was interested
Packit 667938
in knowing how the link was performing. So I wrote a quick hack which
Packit 667938
created a constantly updated graph on the web that showed the traffic
Packit 667938
load on our Internet link. This eventually evolved into a rather
Packit 667938
configurable Perl script called \s-1MRTG\-1.0\s0 which I released in spring
Packit 667938
1995. After a few updates, I left my job at \s-1DMU\s0 to start work at the
Packit 667938
Swiss Federal Institute of Technology. Due to lack of time I had to
Packit 667938
put \s-1MRTG\s0 aside. One day in January of 1996, I received email from
Packit 667938
Dave Rand asking if I had any ideas why \s-1MRTG\s0 was so slow. Actually, I
Packit 667938
did. \s-1MRTG\s0's programming was not very efficient and it was written
Packit 667938
entirely in Perl. After a week or so, Dave wrote back to me and said
Packit 667938
he had tried what I had suggested for improving \s-1MRTG\s0's speed. Since
Packit 667938
the changes did not help much, he had decided to rewrite the
Packit 667938
time-critical sections of \s-1MRTG\s0 in C. The code was attached to his
Packit 667938
email. His tool increased the speed of \s-1MRTG\s0 by a factor of 40! This
Packit 667938
got me out of my '\s-1MRTG\s0 ignorance' and I started to spend my spare time
Packit 667938
developing of \s-1MRTG\-2.\s0
Packit 667938
.PP
Packit 667938
Soon after \s-1MRTG\-2\s0 development had begun I started to give beta
Packit 667938
copies to interested parties. In return I got many feature patches, a
Packit 667938
lot of user feedback and bug fixes. The product you are getting now
Packit 667938
wouldn't be in this state if it hadn't been for the great contributions
Packit 667938
and support I received from of many people. I would like
Packit 667938
to take this opportunity to thank them all. (See the files \s-1CHANGES\s0 for a
Packit 667938
long list of folk people who helped to make \s-1MRTG\s0 what it is today.)
Packit 667938
.SH "Command-line"
Packit 667938
.IX Header "Command-line"
Packit 667938
Mrtg is also the name of the script you have to run to poll data and
Packit 667938
generate the graphs. Most configuration is set through the configuration
Packit 667938
file; some command-line options exist all the same.
Packit 667938
.IP "\fB\-\-user\fR \fIusername\fR  and \fB\-\-group\fR \fIgroupname\fR" 4
Packit 667938
.IX Item "--user username and --group groupname"
Packit 667938
Run as the given user and/or group. (Unix Only)
Packit 667938
.IP "\fB\-\-lock\-file\fR \fIfilename\fR" 4
Packit 667938
.IX Item "--lock-file filename"
Packit 667938
Use an alternate lock-file (the default is to use the configuration-file
Packit 667938
appended with \f(CW\*(C`_l\*(C'\fR).
Packit 667938
.IP "\fB\-\-confcache\-file\fR \fIfilename\fR" 4
Packit 667938
.IX Item "--confcache-file filename"
Packit 667938
Use an alternate confcache-file (the default is to use the configuration-file appended with \f(CW\*(C`.ok\*(C'\fR)
Packit 667938
.IP "\fB\-\-logging\fR \fIfilename\fR|\fBeventlog\fR" 4
Packit 667938
.IX Item "--logging filename|eventlog"
Packit 667938
If this is set to writable filename, all output from mrtg (warnings, debug messages, errors)
Packit 667938
will go to \fIfilename\fR. If you are running on Win32 you can specify \fBeventlog\fR instead of a filename
Packit 667938
which will send all error to the windows event log.
Packit 667938
.Sp
Packit 667938
\&\fB\s-1NOTE:\s0\fRNote, there is no Message \s-1DLL\s0 for mrtg. This has the side effect
Packit 667938
that the windows event logger will display a nice message with every entry
Packit 667938
in the event log, complaing about the fact that mrtg has no message dll. If
Packit 667938
any of the Windows folks want to contribute one, they are welcome.
Packit 667938
.IP "\fB\-\-daemon\fR" 4
Packit 667938
.IX Item "--daemon"
Packit 667938
Put \s-1MRTG\s0 into the background, running as a daemon. This works the same way as
Packit 667938
the config file option, but the switch is required for proper \s-1FHS\s0 operation  
Packit 667938
(because /var/run is writable only by root)
Packit 667938
.IP "\fB\-\-fhs\fR" 4
Packit 667938
.IX Item "--fhs"
Packit 667938
Configure all mrtg paths to conform to the \s-1FHS\s0 specification
Packit 667938
<http://www.pathname.com/fhs/>. The following default values are assumed:
Packit 667938
.Sp
Packit 667938
.Vb 4
Packit 667938
\& confcachefile \- /var/cache/mrtg/mrtg.ok
Packit 667938
\& pid\-file      \- /var/run/mrtg.pid
Packit 667938
\& lock\-file     \- /var/cache/mrtg/mrtg.lck
Packit 667938
\& log\-file      \- /var/log/mrtg.log
Packit 667938
.Ve
Packit 667938
.IP "\fB\-\-check\fR" 4
Packit 667938
.IX Item "--check"
Packit 667938
Only check the cfg file for errors. Do not do anything.
Packit 667938
.IP "\fB\-\-pid\-file=s\fR" 4
Packit 667938
.IX Item "--pid-file=s"
Packit 667938
Define the name and path of the pid file for mrtg running as a daemon
Packit 667938
.IP "\fB\-\-log\-only\fR" 4
Packit 667938
.IX Item "--log-only"
Packit 667938
Only update the logfile, do not produce graphics or html pages
Packit 667938
.IP "\fB\-\-debug=s\fR" 4
Packit 667938
.IX Item "--debug=s"
Packit 667938
Enable debug options. The argument of the debug option is a comma separated list of debug values:
Packit 667938
.Sp
Packit 667938
.Vb 8
Packit 667938
\& cfg  \- watch the config file reading
Packit 667938
\& dir  \- directory mangeling
Packit 667938
\& base \- basic program flow 
Packit 667938
\& tarp \- target parser
Packit 667938
\& snpo \- snmp polling 
Packit 667938
\& fork \- forking view 
Packit 667938
\& time \- some timing info
Packit 667938
\& log  \- logging of data via rateup or rrdtool
Packit 667938
.Ve
Packit 667938
.Sp
Packit 667938
Example:
Packit 667938
.Sp
Packit 667938
.Vb 1
Packit 667938
\& \-\-debug="cfg,snpo"
Packit 667938
.Ve
Packit 667938
.SH "READ ON"
Packit 667938
.IX Header "READ ON"
Packit 667938
Learn more about \s-1MRTG\s0 by going to the mrtg home page on:
Packit 667938
http://oss.oetiker.ch/mrtg
Packit 667938
.SH "AUTHOR"
Packit 667938
.IX Header "AUTHOR"
Packit 667938
Tobias Oetiker <tobi@oetiker.ch> and many contributors