[mrtg] MRTG Help

Victor Farah victor at netmediaservices.net
Tue Oct 14 16:33:35 CEST 2008


Hello,
	I have a machine that I need to monitor traffic.
Now I've got it setup, but it doesn't seem to show my graphs past
100mb/s even though it's on a gigabit, full-duplex switch, and I can see
on my switch that it pushes around 260mb/s on average, sometimes higher.
I've been talking to some people they say use snmp v2c for querying.
This is where the problem comes in:
I setup and installed net-snmp-5.4.1.2_2 on my FreeBSD box36.domain.com
6.2-STABLE FreeBSD 6.2-STABLE #2: Wed Sep  5 23:38:25 EDT 2007, on the
server that hosts the web page and is the one running MRTG.
As well I've setup on the box I want to monitor:
FreeBSD box37.ksdmedia.com 6.3-STABLE FreeBSD 6.3-STABLE #1: Thu Feb 14
09:17:22 EST 2008, as well as net-snmp-5.4.1.2_2.
So to recap:
Box36 is my MRTG/Webpage monitoring machine
Box37 is my machine I need to monitor.

I run this command on box36:
>>snmpwalk -Os -c evil -v 2c box37.domain.com system

sysDescr.0 = STRING: FreeBSD box37.domain.com 6.3-STABLE FreeBSD
6.3-STABLE #1: Thu Feb 14 09:17:22 EST 2008
email at box37.domain.com:/usr/obj/usr/src/sys/GENERIC i386
sysObjectID.0 = OID: netSnmpAgentOIDs.8
sysUpTimeInstance = Timeticks: (510525) 1:25:05.25
sysContact.0 = STRING: tech at domain.com
sysName.0 = STRING: box37.domain.com
....more crap like this, just to tell me it's worked.

but when I do this on box36:
>>cfgmaker --global 'WorkDir: /usr/local/www/mrtg/box37' --global 
'Options[_]: bits,growright' --output /usr/local/etc/mrtg/box37.cfg
evil at box37.domain.com:::::2
>>

My box37.cfg shows this: (Please note I've use domain.com and 00 for the
ips just for my own safety)
### Interface 1 >> Descr: 'em0' | Name: '' | Ip: '00.00.00.37' | Eth:
'00-00-00-00-00-00-00-00-00-00-00-00-00-00' ###
### The following interface is commented out because:
### * has a speed of  which makes no sense
#
# Target[box37.domain.com_1]: 1:evil at box37.domain.com:::::2
# noHC[box37.domain.com_1]: yes
# SetEnv[box37.domain.com_1]: MRTG_INT_IP="0.0.0.37" MRTG_INT_DESCR="em0"
# MaxBytes[box37.domain.com_1]: 0
# Title[box37.domain.com_1]: Traffic Analysis for 1 -- box37.domain.com
# PageTop[box37.domain.com_1]: <h1>Traffic Analysis for 1 --
box37.domain.com</h1>
... bunch of more stuff.

But if I go back do this: (basically take out the :::::2 at the end)
>>cfgmaker --global 'WorkDir: /usr/local/www/mrtg/box37' --global 
'Options[_]: bits,growright' --output /usr/local/etc/mrtg/box37.cfg
evil at box37.domain.com
>>

My box37.cfg looks like this:
### Interface 1 >> Descr: 'em0' | Name: '' | Ip: '0.0.0.37' | Eth:
'00-00-00-00-00-00-00-00-00-00-00-00-00-00' ###

Target[box37.domain.com_1]: 1:evil at box37.domain.com:
SetEnv[box37.domain.com_1]: MRTG_INT_IP="0.0.0.37" MRTG_INT_DESCR="em0"
MaxBytes[box37.domain.com_1]: 125000000
Title[box37.domain.com_1]: Traffic Analysis for 1 -- box37.domain.com
PageTop[box37.domain.com_1]: <h1>Traffic Analysis for 1 --
box37.domain.com</h1>

-- 
Victor Farah - Systems Administrator
netmediaservices.net




More information about the mrtg mailing list