Discussion:
More patches: Include and cfg file changes
Steve Shipway
2010-09-22 00:15:25 UTC
Permalink
I'm on a roll this week... :)

More patches for MRTG in the pipeline -

1. Add wildcard support to the Include: directive. This is something I've wanted for years and been too lazy to submit the (small) patch required to make it work. Routers2 already supports this :P

2. In daemon mode, check for modifications to the cfg file, and if so, reload the configuration. I'm still testing this one because it is potentially difficult, as MRTG makes a few assumptions that this won't happen. I'm also using Tobi's trick of using -M rather than (time-stat()[9]) on the file age, and then $^T=time after the reload.

3. Identify RRD 1.4.999 or later, and use the new rrdcached functions I added in the RRDTool patch if running in rrdcached/TCP mode. This is the final hurdle to allow MRTG to run on a separate server from the RRDTool database, allowing a true distributed MRTG setup. Some additional code now in place to prevent re-testing of remote RRD files when in rrdcached/TCP mode (as the -M test can no longer be used, of course). Needs a bit more testing, though...

I'll be submitting these to Tobi once I'm happy they're stable. In the meantime, I'd appreciate any feedback from the community.

Steve



________________________________
Steve Shipway
ITS Unix Services Design Lead
University of Auckland, New Zealand
Floor 1, 58 Symonds Street, Auckland
Phone: +64 (0)9 3737599 ext 86487
DDI: +64 (0)9 924 6487
Mobile: +64 (0)21 753 189
Email: ***@auckland.ac.nz<mailto:***@auckland.ac.nz>
P Please consider the environment before printing this e-mail
Tobias Oetiker
2010-09-22 04:31:33 UTC
Permalink
Post by Steve Shipway
I'm on a roll this week... :)
More patches for MRTG in the pipeline -
1. Add wildcard support to the Include: directive. This
is something I've wanted for years and been too lazy to submit
the (small) patch required to make it work. Routers2 already
supports this :P
2. In daemon mode, check for modifications to the cfg file,
and if so, reload the configuration. I'm still testing this one
because it is potentially difficult, as MRTG makes a few
assumptions that this won't happen. I'm also using Tobi's trick
of using -M rather than (time-stat()[9]) on the file age, and
then $^T=time after the reload.
3. Identify RRD 1.4.999 or later, and use the new rrdcached
functions I added in the RRDTool patch if running in
rrdcached/TCP mode. This is the final hurdle to allow MRTG to
run on a separate server from the RRDTool database, allowing a
true distributed MRTG setup. Some additional code now in place
to prevent re-testing of remote RRD files when in rrdcached/TCP
mode (as the -M test can no longer be used, of course). Needs a
bit more testing, though...
I'll be submitting these to Tobi once I'm happy they're stable.
In the meantime, I'd appreciate any feedback from the community.
go steve go!
tobi
--
Tobi Oetiker, OETIKER+PARTNER AG, Aarweg 15 CH-4600 Olten, Switzerland
http://it.oetiker.ch ***@oetiker.ch ++41 62 775 9902 / sb: -9900
Loading...