[rrd-users] Re: simple data collection script

Meer Michael michael.meer at siemens.com
Thu Sep 4 08:59:59 MEST 2003

> -----Original Message-----
> From: Dayo Adeyeye [mailto:dayo at ipnxnigeria.net]
> Hello,
> Im setting up rrdtool to monitor some devices and im studying 
> the rrdtutorial by Alex. I need some help since i have very 
> little experience with scripting.........Alex gave the pseudo 
> code in his tutorial. Can someone please help me with a 
> simple perl scrip or shell script that can collect data for 
> me. That is, I'll just insert my snmpwalk commands and 
> execute the script so that it can collect data to fill a 
> database I have created on a Linux RedHat 8 box.
> Dayo Adeyeye

just a small sample > fillrrd.sh :


set -A if1in `snmpget -c $community $ipaddr .`
set -A if1out `snmpget -c $community $ipaddr .`
rrdtool update /usr/mrtg/"$box"_interface1.rrd N:${if1in[3]}:${if1out[3]}
# end of the script

Usage of this small script:
./fillrrd.sh ipaddresse Nameofthebox community
Be sure that the rrd Database already exist when you use this script.

kind regards

Unsubscribe mailto:rrd-users-request at list.ee.ethz.ch?subject=unsubscribe
Help        mailto:rrd-users-request at list.ee.ethz.ch?subject=help
Archive     http://www.ee.ethz.ch/~slist/rrd-users
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi

More information about the rrd-users mailing list