Re: [SPAM] Re: How to create a new Data Type and Consolidation Function?

"Alex van den Bogaerdt" <[email protected]>
Newsgroups gmane.comp.db.rrdtool.devel
Message-ID <351E6D4AFD7F49AD9C123FEFB7AD8B04@desk>
----- Original Message ----- 
From: "Dan Cech" <[email protected]>
To: "Long V" <[email protected]>
Cc: "rrd-developers rrdtool" <[email protected]>
Sent: Tuesday, April 12, 2011 9:25 PM
Subject: Re: [rrd-developers] [SPAM] Re: How to create a new Data Type and 
Consolidation Function?


> On 4/12/2011 3:06 PM, Long V wrote:
>> Example: assume resolution 1 we keep 4 PDP. Resolution 2 we keep 4 CDP. 
>> Then if
>> our zoom time range is time 5 to 8 then it'll trigger res_1 so we have to
>> multiply by 60. If our zoom time range is time 1 to 8 then it'll trigger 
>> res_2
>> and we have to know it's res_2 so we have to multiply by 120 instead of 
>> 60.
>
> I haven't tried it myself but I suspect you could do this using TIME:
>
> DEF:res=rrdfile.rrd:res:AVERAGE
> CDEF:ts=res,POP,TIME
> CDEF:res_mult=res,POP,ts,PREV(ts),-
> CDEF:res_delta=res,res_mult,*
>
> The "res,POP" construct above is just to get around the requirement that
> a CDEF reference at least one DEF.
>
> Would that get the job done?


Isn't this just a complicated way to re-implement TOTAL ?
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.