[rrd-users] irssi script

2008-04-02 Thread R Dicaire
Hi folks, after checking the irssi script archive, and google, I've
failed to find an irssi script that utilizes rrdtools perl mod/API for
logging. I'd like to log irc channel user counts, and perhaps various
other data.
I'm reaching out to the list to see if anyone's written one, and if
so, could make it available, thanks.

-- 
aRDy Music and Rick Dicaire present:
http://www.ardynet.com
http://www.ardynet.com:9000/ardymusic.ogg.m3u

___
rrd-users mailing list
rrd-users@lists.oetiker.ch
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users


Re: [rrd-users] ERROR: not a simple integer:

2008-04-02 Thread Andreas Maus
On Wed, Apr 02, 2008 at 08:53:32PM +1100, [EMAIL PROTECTED] wrote:
> Hello,
Hi.

> I would like to ask for some assistance.  I am trying log bandwidth
> data from a cisco device with rrdtool.
> 
> I can get data from snmpget at the command line:
> 
> [EMAIL PROTECTED] ~]# snmpget -c public -v 1 -Oqv 192.168.1.1 ifInOctets.
> 12767494300
O.K.

> The database was created as follows:
> 
> [EMAIL PROTECTED] ~]# rrdtool create inside.rrd -s 300
> DS:in:COUNTER:600:U:U DS:out:COUNTER:600:U:U RRA:AVERAGE:0.5:1:576
> RRA:AVERAGE:0.5:6:672 RRA:AVERAGE:0.5:24:732 RRA:AVERAGE:0.5:144:1460
O.K.

> Updated as follows - basically 2 data source values for in and out.
> 
> [EMAIL PROTECTED] ~]# rrdupdate /var/lib/rrd/outside.rrd N:'snmpget -c
> public -v 1 -Oqv 192.168.1.1 ifInOctets.1' N:'snmpget -c public -v 1
> -Oqv 192.168.1.1 ifOutOctets.1'
> 
> RRDtool 1.2.99907080300  Copyright by Tobi Oetiker, 1997-2007
> 
> Usage: rrdupdate filename
>   [--template|-t ds-name:ds-name:...]
>   time|N:value[:value...]
> 
>   [EMAIL PROTECTED]:value...]
> 
>   [ time:value[:value...] ..]
> 
> ERROR: not a simple integer: 'snmpget -c public -v 1 -Oaqv 192.168.1.1
> ifInOctets.1'
> [EMAIL PROTECTED] ~]#
Read the error message again!
You run rrdupdate /var/lib/rrd/outside.rrd N:'snmpget -c ...

This is not what you want! You have to fix your quoting.
You want something like rrdupdate /var/lib/rrd/outside.rrd N:`snmpget -c ...

(Notice the backtic ` instead the single quote ' !)

Anyway I recommend storing the output inside a shell variable like:

in1=`snmpget -c public -v 1 -Oqv 192.168.1.1 ifInOctets.1`

and use this in your rrdtool call:

rrdtool update ... "N:${in1} ...

This would result in a more readable code ;)

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


pgpKwtC2qfhcI.pgp
Description: PGP signature
___
rrd-users mailing list
rrd-users@lists.oetiker.ch
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users


[rrd-users] ERROR: not a simple integer:

2008-04-02 Thread [EMAIL PROTECTED]
Hello,

I would like to ask for some assistance.  I am trying log bandwidth
data from a cisco device with rrdtool.

I can get data from snmpget at the command line:

[EMAIL PROTECTED] ~]# snmpget -c public -v 1 -Oqv 192.168.1.1 ifInOctets.
12767494300

The database was created as follows:

[EMAIL PROTECTED] ~]# rrdtool create inside.rrd -s 300
DS:in:COUNTER:600:U:U DS:out:COUNTER:600:U:U RRA:AVERAGE:0.5:1:576
RRA:AVERAGE:0.5:6:672 RRA:AVERAGE:0.5:24:732 RRA:AVERAGE:0.5:144:1460

Updated as follows - basically 2 data source values for in and out.

[EMAIL PROTECTED] ~]# rrdupdate /var/lib/rrd/outside.rrd N:'snmpget -c
public -v 1 -Oqv 192.168.1.1 ifInOctets.1' N:'snmpget -c public -v 1
-Oqv 192.168.1.1 ifOutOctets.1'

RRDtool 1.2.99907080300  Copyright by Tobi Oetiker, 1997-2007

Usage: rrdupdate filename
[--template|-t ds-name:ds-name:...]
time|N:value[:value...]

[EMAIL PROTECTED]:value...]

[ time:value[:value...] ..]

ERROR: not a simple integer: 'snmpget -c public -v 1 -Oaqv 192.168.1.1
ifInOctets.1'
[EMAIL PROTECTED] ~]#

[EMAIL PROTECTED] ~]# snmpget -c public -v 1 192.168.1.1 ifInOctets.1
IF-MIB::ifInOctets.1 = Counter32: 2767527822

What does 'not a simple integer' imply?  The integer I am trying to
insert into the database is 1276749430.

regards,
secrookie

___
rrd-users mailing list
rrd-users@lists.oetiker.ch
https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users