[mrtg] Safe to edit mrtg log files by hand?

Alex van den Bogaerdt alex at ergens.op.het.net
Sun Sep 9 13:19:59 CEST 2007


On Sat, Sep 08, 2007 at 02:03:51PM -0600, Kelly Jones wrote:
> Is it safe to edit mrtg's service.log files by hand?

Yes and no.

> I got some spurious 0's in mine (my fault this time), and want to
> delete them because they make my graph look weird.

Don't delete data.  MRTG's log files depend on proper formatting.
Some 600 rows are 5-minute rates, then 600 rows are 30-minute rates,
and so on.

If you would delete rows from that first range of 600, you would
shift data from the 30-minute part into the 5-minute part.

If MRTG doesn't detect this problem, you will be looking at false
data.

> I know I could just turn off "unknaszero", but I'm using that for
> another reason (notifications), so I want to edit the .log files directly.

Changing the numbers into "2593 0 2593 0" is probably OK.  But don't
delete lines.

HTH
-- 
Alex van den Bogaerdt
http://www.vandenbogaerdt.nl/rrdtool/



More information about the mrtg mailing list