[mrtg] Logging problems with small data?
Jaime Pirnie
jaime at pirnie.org
Mon Jun 18 07:28:24 MEST 2001
Hello everyone.. First off, I want to say that I have read the
manuals and such and am still having some trouble. Maybe I just
don't understand how mrtg fully works.
I'm trying to collect data for the number of messages that go out via
SMTP on my server. I have an external perl script that parses what I
need from a log file and sends that to mrtg on the target line. The
problem that I am having is that mrtg is not logging the difference
between readings. For example, here is the same log file 5 mins
apart:
Before:
992841130 175 0
992841130 0 0 0 0
992840831 0 0 0 0
992840700 0 0 0 0
5 mins later:
992841130 178 0
992841130 0 0 0 0
992840831 0 0 0 0
992840700 0 0 0 0
As you can see, I've sent three emails in that time. Buts not
writing 3 to the history in the log file??! I've played with the
Maxbytes line and well as a bunch of options on the options line.
I've also made sure that my perl script is outputting the proper data
to mrtg. Here is what my perl script outputs to mrtg when I run it
on the command line:
178
0
0
0
I've even tried putting this number as the second variable and it did
the same thing. The value does not reset when it is read, so I
shouldn't be using the absolute option. It just increases forever.
Here is what I have in my config file for mrtg:
#---------------------------------------------------------------
# Packrat - SMTP Total Messages Sent
#---------------------------------------------------------------
Title[Packrat-SMTP-Sent-Total]:\\PACKRAT\SMTPDA\Total Messages Sent
Pagetop[Packrat-SMTP-Sent-Total]: <H1>\\PACKRAT\SMTPDA\Total Messages
Sent</H1>
MaxBytes[Packrat-SMTP-Sent-Total]: 1000
Options[Packrat-SMTP-Sent-Total]: nopercent,growright
Target[Packrat-SMTP-Sent-Total]: `perl getlog.pl
d:\prgfiles\mrtg\logs\PACKRAT.csv "\\PACKRAT\SMTPDA\Total Messages
Sent"`
YLegend[Packrat-SMTP-Sent-Total]: Messages
ShortLegend[Packrat-SMTP-Sent-Total]: Msgs
LegendO[Packrat-SMTP-Sent-Total]:
LegendI[Packrat-SMTP-Sent-Total]: Msgs Sent:
Legend2[Packrat-SMTP-Sent-Total]:
Legend1[Packrat-SMTP-Sent-Total]: SMTP Messages Sent
One thing that I have noticed is that if I use perhour on the options
line, I start to get data, but it is way out of wack because its
multiplied by 3600. If I send one mail it will log 12 or some other
number. I just want it to log the simple 1, 2, 3, or however many
mails went out in that 5 minutes. Is there anything that I am
missing here? I've spent all day trying to figure this out. Thanks
much for any help that anyone might have. If there is some data that
I have left out, please let me know so that I can reply with the
requested data. Thanks again.
-Jaime
--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive http://www.ee.ethz.ch/~slist/mrtg
FAQ http://faq.mrtg.org Homepage http://www.mrtg.org
WebAdmin http://www.ee.ethz.ch/~slist/lsg2.cgi
More information about the mrtg
mailing list