MTRG

Discuss Networking
Post Reply
X11
guru
guru
Posts: 676
Joined: Sun Jan 19, 2003 11:09 pm
Location: Australia
Contact:

MTRG

Post by X11 »

I seen your MTRG thing and want to set up somthing like that at home.

How should I go about doing this...

User avatar
Void Main
Site Admin
Site Admin
Posts: 5716
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA
Contact:

Post by Void Main »

RedHat comes with MRTG and you'll also need SNMP installed, configured and answering requests to at least localhost or wherever you will be running MRTG. I've been using MRTG for many years so I can configure the thing up in a few minutes but it may be a little confusing if you've never used it or if you are unfamiliar with SNMP. I also am using rrdtool to generate the graphs as requested in place of the stock MRTG graphs that used to get generated statically every 5 minutes. Unfortunately on my old AMD k6-2 the rrdtool graphs seem to take a very long time to generate, very annoying. If you have a fast machine they will generate very quickly. If you have a slow machine you might just want to use the stock MRTG graphing and I am thinking about going back to the stock graphs as I hate things that are slow. If you have a lot of devices to monitor then rrdtool is better but if you only have a few devices (like my Void site) it doesn't make much difference.

So basically the steps are:

1) get SNMP installed/working
a) test that it is working with the SNMP tools (snmpget, snmpwalk, etc)
2) Use the "cfgmaker" script which is included with the MRTG package to get the MRTG configuration information for your mrtg.cfg (In Red Hat this is installed in the /etc/mrtg directory
3) Make sure you have a cron job set to run MRTG every 5 minutes (Red Hat should do this by default if MRTG is installed).
4) Create some sort of web page to index you MRTG graphs (or use some of the supplied/unsupplied CGI scripts).

Another great program for gathering stats using rrdtool is a web based app called "Cacti":

http://www.raxnet.net/products/cacti/

We're using it at work for graphing all sorts of stuff along with several other tools that are linked to off of the RRDtool site:

http://people.ee.ethz.ch/~oetiker/webto ... index.html

I would give you more detailed help right now but I am heading out of town for the weekend and have to go right now so it'll have to be next week before I will be able to help you any more if you need it. There is boatloads of information out there about MRTG, RRDtool and the other utilities. Everyone uses this stuff.

X11
guru
guru
Posts: 676
Joined: Sun Jan 19, 2003 11:09 pm
Location: Australia
Contact:

Post by X11 »

Cool thanks, that should help, I have snmp installed, I use it because I log all the packets on the dialup interface

User avatar
Void Main
Site Admin
Site Admin
Posts: 5716
Joined: Wed Jan 08, 2003 5:24 am
Location: Tuxville, USA
Contact:

Post by Void Main »

I just set up Cacti with some basic graphs. You can get to it on the front page or click here:

http://voidmain.is-a-geek.net/cacti/

Of course you'll only have guest access. It's pretty easy to set up.

X11
guru
guru
Posts: 676
Joined: Sun Jan 19, 2003 11:09 pm
Location: Australia
Contact:

Post by X11 »

I installed RRDTool, now im going to have a go at getting cacti to work.

Post Reply