[mrtg] Re: Using my own input files

Alex van den Bogaerdt alex at slot.hollandcasino.nl
Wed Feb 9 10:43:21 MET 2000

Sven Vanleke wrote:
> Hi,
> Having not that much experience with the technical side of MRTG I was
> wondering if somebody could point me into the right direction.

MRTG uses another program to fill and process the logfiles.  Start it
without any options to see what parameters you can give it.

rateup for mrtg 2.8.9
Usage: ./rateup directory basename [sampletime] [t sampletime]
        [-(t)ransparent] [u|a|g|h|m in out abs_max]
        [i/p file maxvi maxvo max x maxy growright step bits]

Let rateup do the work, just start with the oldest entry you have.  If you
enter the values, rateup will build a logfile for you.

> Any hint how the create the log-files from scratch based on data comming
> from another source (database) and spread over time?
> The intention is also to respect the structure of the log-file in the
> day/week/month/year format.
> E.g. : Database archive with the nbr of active modems spread over the last 2
> years

The values are gauge values.
pseudo code:

   while read line from old database
      THEDATE={time sample was taken}
      VALUE1={value to enter}
      VALUE2={value to enter}
      MAXVALUE={maximum possible value}
      rateup /var/tmp  convert  t $THEDATE g $VALUE1 $VALUE2 $MAXVALUE

Perhaps you need to alter something, dunno.  It should be close to a
working solution.

 / alex at slot.hollandcasino.nl                  alex at ergens.op.het.net \
| work                                                         private |
| My employer is capable of speaking therefore I speak only for myself |

Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:mrtg-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/mrtg

More information about the mrtg mailing list