[rrd-users] I need help with my rrd file

Andreas Maus a.maus at science-computing.de
Fri Sep 26 13:58:20 CEST 2008


On Fri, Sep 26, 2008 at 01:45:35PM +0200, Rene Fritzsche wrote:
> Hi,
> 
> > >Show us the output of your snmpget command. I guess it looks like this:
> > 
> > >maus at kanga:~$  snmpwalk -v2c -c public 192.168.1.222 1.3.6.1.2.1.2.2.1.16.4
> > >IF-MIB::ifOutOctets.4 = Counter32: 262658353
> > 
> > Yes, the output is : IF-MIB::ifOutOctets.4 = Counter32: 461597000
> 
> as Alexander wrote; this whole output-line can not be used to be filled
Hi.

I'm not Alexander but thats o.k. :P

> to
>   snmpwalk ... 1.3.6.1.2.1.2.2.1.16.4 | sed 's/^.*: \([0-9]*]\)$/\1/' > $out
Or just use the man snmpget to get the options for snmpget to get a more
"parsable" result. Obviously this depends on your snmp programs.

E.g. my net-snmp uses the switch -Oq to get a result that is easier to
parse:

maus at kanga:~$ snmpget -Oq -v2c -c public 192.168.1.222 1.3.6.1.2.1.2.2.1.16.4
IF-MIB::ifOutOctets.4 269735286
maus at kanga:~$ snmpget -Oq -v2c -c public 192.168.1.222 1.3.6.1.2.1.2.2.1.16.4 | cut -d ' ' -f 2 
269736768

HTH,

Andreas.

-- 
Dipl.-Ing. Andreas Maus             science+computing ag
System Administration               Hagellocher Weg 73
tel.: +49 7071 9457 671             72070 Tuebingen, Germany
fax: +49 7071 9457 411              www.science-computing.de
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
Url : http://lists.oetiker.ch/pipermail/rrd-users/attachments/20080926/86b18518/attachment.bin 


More information about the rrd-users mailing list