[ale] MRTG question

Jim Popovitch jimpop at yahoo.com
Thu Aug 25 20:49:47 EDT 2005


Hi All,

I'm trying to produce a simple MTRG graph that trends the increase in
log file entries over the course of a 24 hour period.  I want to be able
to see the time periods which added the most lines.  The problem is the
the graph only shows at most 1 or 2, even though there might be 200
entries added to the the logfile every hour.  What am I missing?

--- mrtg.cfg ----
WorkDir: /var/www/html/
Title[stats]: Log Entries
PageTop[stats]: <h1>Log Entries</h1>
Target[stats]: `/home/scripts/line-count.sh`
MaxBytes[stats]: 10000
Suppress[stats]: ymw
Options[stats]:growright,nobanner,nolegend,noinfo,integer,nopercent
YLegend[stats]: entries
-----------------------

--- line-count.sh ----
#!/bin/sh
/usr/bin/wc -l /var/log/messages | awk '{ print $1 }'
echo 0
echo ""
echo ""
----------------------

Tia,

-Jim P.






More information about the Ale mailing list