[mrtg] Re: Email counter from script

Koelstra, J. (Jan) JKoelstra at MINSZW.NL
Mon Apr 11 09:39:32 MEST 2005


Hi Corstian,

Seeing the numbers 4 and 29 on top of your logfile I think the counters you want to graph are increasing slowly.
By default MRTG calculates the rate per second.
To graph slow growing counters you can add 'perminute' or even 'perhour' to the options line.

Hth,

Jan.

-----Original Message-----
From: mrtg-bounce at list.ee.ethz.ch [mailto:mrtg-bounce at list.ee.ethz.ch] On Behalf Of Corstian
Sent: Monday, April 11, 2005 9:19 AM
To: mrtg at list.ee.ethz.ch
Subject: [mrtg] Email counter from script


Hi all,

I am working on a mrtg graph, which shows the number of GOOD mails vs the number of SPAM mails.

Therefore, I created entries in my .procmailrc which counts all incoming mail, and I created a script which has the following output:

#TOTAL number of SPAM mails
#TOTAL number of GOOD mails
Uptime
Hostname

So far, so good. The counters are working fine, and the script creates the expected output.

I started with the following mrtg config, which runs without any error.

Target[corstian.GOOD.SPAM]:     `/home/corstian/bin/mrtg/mail_count
corstian show SPAM GOOD`
Options[corstian.GOOD.SPAM]:    growright
Title[corstian.GOOD.SPAM]:      Corstians Mail
MaxBytes[corstian.GOOD.SPAM]:   10000000000
LegendI[corstian.GOOD.SPAM]:    SPAM
LegendO[corstian.GOOD.SPAM]:    GOOD
Legend1[corstian.GOOD.SPAM]:    SPAM mails received
Legend2[corstian.GOOD.SPAM]:    GOOD mails received
YLegend[corstian.GOOD.SPAM]:    Mails
ShortLegend[corstian.GOOD.SPAM]: Mails
PageTop[corstian.GOOD.SPAM]:    <H1>Corstians Mail </H1>

The top of the logfile looks as follows:
root at pinkpanther # head -n 5 corstian.good.spam.log
1113202509 4 29
1113202509 0 0 0 0
1113202211 0 0 0 0
1113202200 0 0 0 0
1113201900 0 0 0 0

After I received some emails, the counter increased, and even the counter in the logfile increased, but I just get zero's on my graphs...`

What do I want to see ??
Every time one of the counters increases, I want to see the difference with the old value in my graph.

The weekly graph shouldn't be the mean value of the daily graph, but the total value!! etc.

I hope somebody can help me!

--
groetjes,
Corstian



--
groetjes,
Corstian

--
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


_________________________________________________________

Het ministerie van Sociale Zaken en Werkgelegenheid sluit elke aansprakelijkheid uit in verband met het niet juist, onvolledig of niet tijdig overkomen van de informatie in deze e-mail.
Aan dit bericht kunnen geen rechten worden ontleend.

Dit bericht is alleen bestemd voor de geadresseerde. Indien dit bericht niet voor u bestemd is, verzoeken wij u dit onmiddellijk aan ons te melden en de inhoud van dit bericht te vernietigen.
_________________________________________________________

The ministry of Social Affairs and Employment is not liable for any incorrect or incomplete transmission of the information in this e-mail or for any delay in its receipt.
This message shall not constitute any obligations.

This message is intended solely for the addressee.
If you have received this message in error, please inform us immediately and delete its content.
_________________________________________________________

--
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