Netgear DG834G MRTG scripts
Below are details of scripts for use with MRTG which will graph
details from the Netgear DG834(G) to provide details such as this
Theses MRTG scripts have been coded by Chris Hodder and
have been monitoring stats on his DG834G since Apr 06. No support
is given by this site or chris.
- Netgear DG834(G) router, v1 or v2.
These are some very quick-n-dirty MRTG scripts that will extract
various pieces of information
from the Netgear DG834(G), v1 or v2 routers.
Data Output and File Information:
Connects to the router's web interface to enable
the telnet daemon if it isn't already enabled.
It also removes some entries from the router's internal firewall
which sometimes appear and would otherwise prevent SNMP access
(for the bandwidth graphs).
Connects to the router's telnet interface
to output the current stats to a file, currentstats.txt
Parses the currentstats.txt file, based on the command line
parameters, to output a single figure of information. Called by
the *.cmd script files to get the data for graphing in MRTG.
This outputs the router's uptime in human readable
Provide the output for the graphs, and are called by MRTG.
Most of them call getstat.pl which
extracts relevant information from the currentstats.txt file.
These actually run the MRTG scripts in the correct order - I've
provided a perl version so that it can be
silently executed using wperl from Task Scheduler, so it doesn't
interfere with using the computer.
Quick Setup Instructions
To get this working on your own system, please do the following:
- Download NetgearMRTG.zip.
Extract the contents of the zip file to your mrtg/bin directory.
- Edit the enabletelnet.pl script to put in your own router's
IP address and admin password.
- Edit the getinfo.pl script to put in your own router's IP
- Edit the mrtg.cfg file to put in your own router's IP address
and change the output directory for the
mrtg data, if necessary.
- Go to http://routerip/setup.cgi?next_file=snmp.htm
If SNMP is turned on, turn it off, then click Apply
Turn it on, then click Apply. A quirk of the router requires that
you do this after a reboot,
as it doesn't appear to re-initialise properly in some way.
- Finally, check that MRTG runs by going to the directory a
command prompt and typing runmrtg
If you get any error messages this means something isn't right.
This is where you need the patience!
Authors "To Do" Notes
- Make it detect CRC / FEC errors when interleaving is applied.
Easy enough to do, but I would like
to make it auto-detect interleaving status.
My thanks to chris for making these available :)