# [mrtg] Re: Log File ?

Alex van den Bogaerdt alex at slot.hollandcasino.nl
Thu Nov 11 10:42:12 MET 1999

```> Can anybody explain me why values B & C are not equal to D & E as documentation says: logfile-format.txt ?
> I collect values from a personal script, and it always return the same integer value 2 times.
>
> * The firsts lines from my log file.
> 942275407 19 19
> 942275407 19 19 19 19
> 942275400 18 18 19 19
> 942275100 17 17 18 18
> 942274800 17 17 17 17
> 942274500 17 17 17 17
> 942274200 16 16 17 17
> 942273900 14 14 15 15
> 942273600 13 13 14 14
>
MRTG interpolates the data it receives so it fits in timeslots that are
exactly five minutes apart.  You've run your script at time 942275407
and entered 19 for the value.  The previous run would have been somewhere
near time 942275107.  At that time, you've entered 18 for the value.  The
value entered before that one was 17.

The line in the log file at time stamp 942275100 describes the period from
942275100 to 942275400 and is made up from two real periods:

942274800 to 942275100, for just a little portion (about 7 seconds)
942275100 to 942275400, for a large portion (about 293 seconds)

The calculated value will be approaching 18 but it will be just a little
less.  This is rounded down to 17.  The highest value seen in that period
is 18.  This is what is in the log:  17 on average and 18 max.

The next value will be received at time stamp 942275407 + 300 seconds is
942275707.  MRTG already knows the 942275400 to 942275407 portion of the
next interval and uses the next value (20?) for the remainder of the
interval.  This means that the average will be 19.999something and the
maximum will be 20.

Try to run MRTG every minute with several values.  Column B and C will
contain the average, column D and E will contain the maximum.

HTH
--
__________________________________________________________________
/ 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 |
+----------------------------------------------------------------------+

--
* To unsubscribe from the mrtg mailing list, send a message with the
subject: unsubscribe to mrtg-request at list.ee.ethz.ch
* The mailing list archive is at http://www.ee.ethz.ch/~slist/mrtg
```