[rrd-users] [rrd] Can't I turn off data smoothing for GAUGE?
Philip Peake
philip at vogon.net
Thu Aug 19 16:07:22 CEST 2010
Then for a huge class of problems, actually, IMHO, most real world
problems not involving rate of change, its useless.
Tell me how I synchronize a data source to RDD's concept of sample times?
Actually, what is RDD's concept of sample times? How does it determine
the start?
I would assume time starts with the first entry (or is it the time it is
created?).
If its based upon the first entry, I am actually sampling data on a very
regular (well, as regular as sleep() gets), so the stored values should
be pretty darn close to the entered values ... they are not.
On 8/19/2010 12:05 AM, Simon Hobson wrote:
> At 22:49 -0700 18/8/10, Philip Peake wrote:
>> Here is what I don't understand:
>>
>> <http://oss.oetiker.ch/rrdtool/tut/rrd-beginners.en.html>http://oss.oetiker.ch/rrdtool/tut/rrd-beginners.en.html
>> GAUGE does not save the rate of change. It saves the actual value
>> itself. There are no divisions or calculations.
> That is correct, as far as it goes, in the context it is said.
> However, that section is dealing with input data handling - ie
> conversion from the numbers you put in, to numbers going to storage.
> Other data types are converted to rates - ie (x-y)/t
>
> What happens internally is a 'black box' to me, all I know is that I
> use gauge values a lot for logging temperature, and I get out what I
> put in (after normalisation and consolidation).
>
> I agree it is misleading by not pointing out that the value will
> still be normalised and consolidated just like everything else.
>
>> Looking at the source:
>>
>> case DST_GAUGE:
>> old_locale = setlocale(LC_NUMERIC, "C");
>> errno = 0;
>> pdp_new[ds_idx] =
>> strtod(updvals[ds_idx + 1], &endptr) * interval;
>> if (errno) {
>> rrd_set_error("converting '%s' to float: %s",
>> updvals[ds_idx + 1], rrd_strerror(errno));
>> return -1;
>> };
>> setlocale(LC_NUMERIC, old_locale);
>> if (endptr[0] != '\0') {
>> rrd_set_error
>> ("conversion of '%s' to float not complete:
>> tail '%s'",
>> updvals[ds_idx + 1], endptr);
>> return -1;
>> }
>> rate = pdp_new[ds_idx] / interval;
>> break;
>>
>> If this line is removed, it will behave as documented.
>> I can not really see any point in this, a gauge is a gauge, its not a rate.
> No it won't - except under special circumstances that you can use
> anyway. If you do not feed in an update **exactly** on every step
> boundary then normalisation will occur - as per the tutorial I
> previously posted a link to, you have read it I assume ? This is how
> rrd works, it would require massive changes to make it work otherwise.
>
More information about the rrd-users
mailing list