<div>root@www:/www/collector# cat ptest.sh</div><div>rrdtool graph $GRAPHDIR/workerstats_$DATE.png --width=1000 --height=125 -l 0 \</div><div> DEF:connsused=apache.rrd:busy:LAST \</div><div> DEF:connsmax=apache.rrd:idle:LAST \</div>
<div> CDEF:zero=connsused,0,* \</div><div> CDEF:ru=connsused,1,* \</div><div> CDEF:rf=connsmax,1,* \</div><div> PRINT:ru:LAST:"Used Connections\: %10.0lf" \</div><div>
PRINT:rf:LAST:"Free Connections\: %10.0lf" \</div><div><br></div><div>root@www:/www/collector# sh ./ptest.sh</div><div>0x0</div><div>Used Connections: 249</div><div>Free Connections: 148</div>
<div><br></div><div><br></div><br><div class="gmail_quote">2011/11/28 Juvenal Carvalho <span dir="ltr"><<a href="mailto:juniorfc@terra.com.br">juniorfc@terra.com.br</a>></span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
I don't have this option. There is another way to get the information ?<br>
<br>
<br>
<br>
[root@mrtg rrd]# /usr/local/rrdtool/bin/rrdtool<br>
<div class="im">RRDtool 1.0.43 Copyright 1997-2001 by Tobias Oetiker <<a href="mailto:tobi@oetiker.ch">tobi@oetiker.ch</a>><br>
<br>
</div>Usage: rrdtool [options] command command_options<br>
<br>
Valid commands: create, update, graph, dump, restore,<br>
last, info, fetch, tune, resize, xport<br>
<br>
RRDtool is distributed under the Terms of the GNU General<br>
Public License Version 2. (<a href="http://www.gnu.org/copyleft/gpl.html" target="_blank">www.gnu.org/copyleft/gpl.html</a>)<br>
<br>
For more information read the RRD manpages<br>
<br>
<br>
<br>
--------------------------------------------------<br>
From: <<a href="mailto:j.halifax2@seznam.cz">j.halifax2@seznam.cz</a>><br>
Sent: Monday, November 28, 2011 15:48<br>
<div><div class="h5">To: "Juvenal Carvalho" <<a href="mailto:juniorfc@terra.com.br">juniorfc@terra.com.br</a>><br>
Cc: <<a href="mailto:rrd-users@lists.oetiker.ch">rrd-users@lists.oetiker.ch</a>><br>
Subject: Re: [rrd-users] Getting AVG info from RRD Files<br>
<br>
><br>
>> do I need I more recent version ?<br>
><br>
> I don't think so, it isn't a new feature.<br>
> jh<br>
><br>
>> ------------ Původní zpráva ------------<br>
>> Od: Juvenal Carvalho <<a href="mailto:juniorfc@terra.com.br">juniorfc@terra.com.br</a>><br>
>> Předmět: Re: [rrd-users] Getting AVG info from RRD Files<br>
>> Datum: 28.11.2011 18:45:03<br>
>> ----------------------------------------<br>
>> do I need I more recent version ?<br>
>><br>
>> [root@mrtg rrd]# /usr/local/rrdtool/bin/rrdtool print -s -1y target.rrd<br>
>> AVERAGE<br>
>> ERROR: unknown function 'print'<br>
>> [root@mrtg rrd]# /usr/local/rrdtool/bin/rrdtool<br>
>> RRDtool 1.0.43 Copyright 1997-2001 by Tobias Oetiker <<a href="mailto:tobi@oetiker.ch">tobi@oetiker.ch</a>><br>
>><br>
>><br>
>> --------------------------------------------------<br>
>> From: <<a href="mailto:j.halifax2@seznam.cz">j.halifax2@seznam.cz</a>><br>
>> Sent: Monday, November 28, 2011 15:41<br>
>> To: "Juvenal Carvalho" <<a href="mailto:juniorfc@terra.com.br">juniorfc@terra.com.br</a>><br>
>> Cc: <<a href="mailto:rrd-users@lists.oetiker.ch">rrd-users@lists.oetiker.ch</a>><br>
>> Subject: Re: [rrd-users] Getting AVG info from RRD Files<br>
>><br>
>> ><br>
>> >> How can I get just 1 value<br>
>> ><br>
>> > Use PRINT instead of fetch<br>
>> > jh<br>
>> ><br>
>> ><br>
>> >> ------------ Původní zpráva ------------<br>
>> >> Od: Juvenal Carvalho <<a href="mailto:juniorfc@terra.com.br">juniorfc@terra.com.br</a>><br>
>> >> Předmět: Re: [rrd-users] Getting AVG info from RRD Files<br>
>> >> Datum: 28.11.2011 18:22:28<br>
>> >> ----------------------------------------<br>
>> >> Hi Guys<br>
>> >><br>
>> >> I tried to check the documentation but got no success. I ran the<br>
>> >> command below<br>
>> >> and I got a lot of values and I don't know how to treat those values<br>
>> >> in a<br>
>> >> readable format.<br>
>> >><br>
>> >><br>
>> >><br>
>> >> /usr/local/rrdtool/bin/rrdtool fetch -s -1y target.rrd AVERAGE<br>
>> >><br>
>> >><br>
>> >><br>
>> >> In the attached file I have the result.<br>
>> >><br>
>> >><br>
>> >><br>
>> >> How can I get just 1 value (as is printed in the MRTG graph as<br>
>> >> average) ? For<br>
>> >> example, IN: 16MB/s OUT: 5MB/s<br>
>> >><br>
>> >><br>
>> >> Thanks<br>
>> >><br>
>> >><br>
>> >> Juvenal<br>
>> >><br>
>> >><br>
>> >><br>
>> >> From: Juvenal Carvalho<br>
>> >> Sent: Wednesday, November 16, 2011 15:52<br>
>> >> To: <a href="mailto:rrd-users@lists.oetiker.ch">rrd-users@lists.oetiker.ch</a><br>
>> >> Subject: Getting AVG info from RRD Files<br>
>> >><br>
>> >><br>
>> >> Hi everybody<br>
>> >><br>
>> >> I'm new working with advanced RRD resources and I'm trying to use my<br>
>> >> data to<br>
>> >> collect some relevant information.<br>
>> >><br>
>> >> I have a question about how to get the AVG information from a RRD file<br>
>> >> created<br>
>> >> by MRTG.<br>
>> >> I need to get the average from the last month (just the numbers) and<br>
>> >> send it by<br>
>> >> email to a group of users but I don't know how to do it.<br>
>> >><br>
>> >> Do you know I have a way to get this info ?<br>
>> >><br>
>> >><br>
>> >><br>
>> >> Thanks !<br>
>> >><br>
>> >><br>
>> >> Juvenal<br>
>> >><br>
>> >><br>
>> ><br>
>> > Esta mensagem foi verificada pelo E-mail Protegido Terra.<br>
>> > Atualizado em 31/12/1969<br>
>> ><br>
>> ><br>
>><br>
>><br>
>><br>
><br>
> Esta mensagem foi verificada pelo E-mail Protegido Terra.<br>
</div></div>> Atualizado em 05/09/2011<br>
<div class="HOEnZb"><div class="h5">><br>
><br>
<br>
_______________________________________________<br>
rrd-users mailing list<br>
<a href="mailto:rrd-users@lists.oetiker.ch">rrd-users@lists.oetiker.ch</a><br>
<a href="https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users" target="_blank">https://lists.oetiker.ch/cgi-bin/listinfo/rrd-users</a><br>
</div></div></blockquote></div><br>