[rrd-users] strftime and TREND

Petteri Matilainen pmatil at gmail.com
Fri Nov 30 21:15:20 CET 2007


Alex van den Bogaerdt wrote:
> On Thu, Nov 29, 2007 at 08:16:38PM +0200, Petteri Matilainen wrote:
>
>   
>> Any ideas concerning my last post? Maybe someone should explain to me 
>> exactly how CDEF with trend works, because I can't get a TREND line at 
>> all if I define CDEF:outavg=Outside,86400,TREND. What I need is average 
>> curve over 24 hrs, 1 week and 1 month.
>>     
>
> I'm not sure if trend is what you need. Why I'm not sure: because it
> is not clear to me what you are asking for.
>   
> Trend works. Maybe it's not what you want, or maybe you've found a bug.
>   
I need to graph the average temperature like I'm graphing the 
temperature. Samples are taken every minute and fed to an rrd. I thought 
that trend worked for me, but somehow it doesn't. For example I have 
temperature graphed over 24 hrs (-s -1day). Is it possible to have TREND 
curve over that time so that the resulting curve is same as I took 
samples every 60 seconds of what this line gives and then graphed that 
(because that's what I'm doing now and it works): 
PRINT:Outside:AVERAGE:"%6.2lf"? If I've understood correctly, this line 
should give me what I want:

CDEF:outavg=Outside,86400,TREND

But it doesn't. No line. If I try a smaller number, like 1800 seconds, I get a nice TREND curve which is the 30 minute average. I need 24 h average (and 1 week, 1 month and 1 year). If this isn't possible with TREND, I'll continue to use my version, which is to fetch the average that the above print line gives and fed that to another averages.rrd, from which I graph average variations over the time spans.

>> I also need to ask how to print a vdef and time associated with it. I've 
>> been reading the manpage over and over but I can't figure out why 
>> PRINT:gav:"%5.4lf":%s gives an error:
>>
>> ERROR: Garbage ':%s' after command:
>> PRINT:gav:%5.4lf:%s
>>
>> How do I define this strftime without error? Thanks in advance.
>>     
>
>
> Where does the documentation tell you to combine rates and time?
> Print one or the other, and it should work.
>
> Keep in mind that printing vdef timestamps isn't as mature as the
> rest of rrdtool yet.
>   
Thanks, I figured that out just as I sent the post. Sorry.

cheers,

Petteri Matilainen



More information about the rrd-users mailing list