[mrtg] Re: monitoring netstat output with MRTG?

Smith, Lisa lcsmith at edirect.com
Fri Jan 19 20:07:41 MET 2001


Thanks for your question.  What I would like to graph is this output: 
 
netstat -i
Kernel Interface table
Iface   MTU Met    RX-OK     RX-ERR RX-DRP RX-OVR    TX-OK     TX-ERR TX-DRP
TX-OVR Flg
eth0   1500   0       9255614    275      0             88
874276     0      0    382 BRU
 
Specifically the RX-OK column and the TX-OK column.  I know those "grow"
over time, so I need to do some computation to get a more precise count of
how much traffic has gone through this machine over a specific period of
time (say 5 minutes).   
 
Basically, I don't have access to monitor router stats, so I'm trying to
determine another route for monitoring the incoming /outgoing traffic on a
particular box...
 
Maybe this is simply a question of scripting ability(?)  Because I *think* I
know what I need to do "conceptually"
 
I *think* I need to compare the output of two separate netstat outputs, in
other words:
 
assuming that each netstat was run 5 minutes apart:
 
[RX-OK(2) + TX-OK(2)] -  [RX-OK(1) + TX-OK(1)]  = amount of traffic going
through the machine in that 5 minute interval.
 
I don't want this to grow over time, as I know the output of netstat does.
I just need a picture or snapshot of how much traffic is going thru the
machine during any particular period.   
 
Go easy on me, I'm fairly new to scripting MRTG, and network monitoring in
general.   So maybe I'm making this more complicated than it has to be!
 
Thanks for any help or suggestions!
 
Lisa
 

-----Original Message-----
From: Calvert, Neil [mailto:ncalvert at GlobalNTS.com]
Sent: Friday, January 19, 2001 1:52 PM
To: 'Smith, Lisa'
Cc: mrtglist (E-mail)
Subject: RE: [mrtg] monitoring netstat output with MRTG?



er... MRTG graphs numbers. The netstat command outputs a route table. What
are you trying to graph here? Are you referring to graphing ping or
traceroute response times? If so mrtg-ping-probe is a good tool. See the
www.mrtg.org page for the links.

Neil 


-----Original Message----- 
From: Smith, Lisa [ mailto:lcsmith at edirect.com <mailto:lcsmith at edirect.com>
] 
Sent: Friday, January 19, 2001 1:48 PM 
To: 'MRTG Mailing list' 
Subject: [mrtg] monitoring netstat output with MRTG? 



Good day! 

I'm a bit new to the group, so my apologies if this question is redundant! 


Does anyone have any sample scripts for monitoring the output of netstat -in

with mrtg? 

Any help you can provide would be greatly appreciated! 

Lisa 

-- 
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
<mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe>  
Archive     http://www.ee.ethz.ch/~slist/mrtg
<http://www.ee.ethz.ch/~slist/mrtg>  
FAQ         http://faq.mrtg.org <http://faq.mrtg.org>     Homepage
http://www.mrtg.org <http://www.mrtg.org>  
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi
<http://www.ee.ethz.ch/~slist/lsg2.cgi>  



--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the mrtg mailing list