[mrtg] MRTG Possible to perform metrics to one Host/Destination instead of a Router?
Steve Shipway
s.shipway at auckland.ac.nz
Tue Aug 24 00:22:53 CEST 2010
Yes, you can do this, but it is a bit more complicated. Here's a way to achieve it.
First, write a plugin for NRPE (exit status 0, output one line of text containing number) that can collect the metrics you're interested in. For example, a small script that downloads a file from a specified location and times the transfer, then returns the transfer time in seconds for each of the two sites as two separate values in the output text. NOTE: Your plugin should ALWAYS exit in less than 30 sec.
Install a small testing satellite server at the various locations you wish to test from. If you have VMWare then a VM would be perfect. On this server, install the Nagios NRPE agent, and this new plugin, and configure NRPE to accept commands from your MRTG server.
On your MRTG server, install mrtg-nrpe (comes with the Routers2 software, in C or Perl). For each remote server, configure a Target that uses mrtg-nrpe as a data collection plugin to query the remote NRPE and run the NRPE plugin you designed at the start. This returns a pair of values in seconds which you can graph. Make good use of the Forks: directive to ensure that your checks all complete within the 5min window.
And voila, you have a graph of FTP performance form each site, with the 'in' and 'out' lines being the response times of your two FTP servers! You can use a similar method to create plugins to monitor other network protocols.
We have done something similar for remote monitoring of mail queues.
Feel free to email me directly if you'd like a bit more help with this.
Steve
Steve Shipway
ITS Unix Services Design Lead
University of Auckland
Floor 2, 58 Symonds Street
09 3737599 ext 86487
From: mrtg-bounces+s.shipway=auckland.ac.nz at lists.oetiker.ch [mailto:mrtg-bounces+s.shipway=auckland.ac.nz at lists.oetiker.ch] On Behalf Of Furosh One
I've used MRTG in the past as a network administrator and I know it's good. However, I have the need to perform some network testing to collect stats/metrics on network performance, bandwidth, time, etc from our global WAN to a central server that I've setup.
Essentially management would like for me to compare versus our company's public FTP site and test against a co-located server in a cloud environment.
We would like to know if all our global WAN locations would benefit with using this cloud setup to increase speed for data transfers for things such as FTP, SFTP, SVN, Git, SCP, RSYNC, etc.
Can I use MRTG to obtain this information for a destination and not a ROUTER? If so, I'd like to collect network speed metrics and graphs, etc. to compare versus our current FTP site.
-Regards,
FuRoSh.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.oetiker.ch/pipermail/mrtg/attachments/20100823/49665ee7/attachment.htm
More information about the mrtg
mailing list