MRTG obtains this data by reading the ifInOctets and ifOutOctets values in the 
IF-MIB via SNMP at 5min intervals, calculating the difference (taking into 
account possible counter wrap)  and dividing by the time interval, then 
multiplying by 8 to get bits/sec.  This is in the standard MIB.  If the 
interface is a high-speed interface (>=100Mbps) and the device supports it, 
then the MIB-2 isused instead and the h64bit counters ifHCInOctets and 
ifHCOutOctets are used instead (to prevent counter wrap from causing problems).

Steve

From: Prakash Mariasusai [via MRTG Mailinglists] 
[mailto:[email protected]]
Sent: Thursday, 18 March 2010 3:13 a.m.
To: Steve Shipway
Subject: Method of retrieving Bits per sec (MRTG ref)
Hi,
I am writing a small program to get the "Bits per sec" value
for a network interface in Unix systems (Solaris, Linux severs)
similar to the one provided by MRTG in the below link:
http://www.switch.ch/network/operation/statistics/geant2.html
I assume that MRTG does the same through SNMP.
I am new to SNMP and if someone can point me to the appropriate MIB/OID,
for doing the same, it would be very helpful.
Thanks in advance,
Prakash

-- 
View this message in context: 
http://n2.nabble.com/Method-of-retrieving-Bits-per-sec-MRTG-ref-tp4750489p4752968.html
Sent from the MRTG Developers Mailinglist mailing list archive at Nabble.com.

_______________________________________________
mrtg-developers mailing list
[email protected]
https://lists.oetiker.ch/cgi-bin/listinfo/mrtg-developers

Reply via email to