Wrong current values with CDEF

Support questions about the Threshold plugin

Moderators: Developers, Moderators

Post Reply
X-dark
Cacti User
Posts: 111
Joined: Wed Jun 18, 2008 10:21 am
Location: France

Wrong current values with CDEF

Post by X-dark »

Hi,

I'm using thold 0.4.3 with Cacti 0.8.7e and PIA 2.5.

I want to make alert when the ratio between two values of a data template is below a given value. I have created two thold templates that should have the same behavior but based on one value of the data template or the other.

The values that thold use to decide if the threshold should be triggered is wrong. It seems to be calculated with values belonging to different polling cycles.

Here is a detailed explanation of what I have setup:

My data template with two counters "received" and "forwarded":
Image

The first thold template created:
Image
The CDEF is

Code: Select all

cdef=CURRENT_DATA_SOURCE,ALL_DATA_SOURCES_NODUPS,CURRENT_DATA_SOURCE,-,/,100,*
The second thold template created:
Image
The CDEF is

Code: Select all

cdef=ALL_DATA_SOURCES_NODUPS,CURRENT_DATA_SOURCE,-,CURRENT_DATA_SOURCE,/,100,*
I've instantiated the two templates above for a given graph instance. If I go to the instance of the first template I get the good and expected value:
Image

And if I go to the instance of the second template I get, as expected, the same value as with the first template:
Image

Now, comes the "not working as expected" part. Here is what I get when I display the thold states. Not that the value are not the same as the ones seen before (the screenshots have been taken within the same polling cycle) and even differs between them. One of the value is superior to 100% which never occurs with the graph.
Image

Does anyone have a suggestion ?

NB: I know the versions I use are not the latest but as my Cacti installation involve 5 Cacti instances (with 2,000 hosts and 600,000 data sources) upgrade must be thoroughly tested. If this is a known bug with this thold version and I can upgrade only thold without changing Cacti, PIA or Boost version to solve it, it should be doable.
Cedric Girard
User avatar
TheWitness
Developer
Posts: 17047
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: Wrong current values with CDEF

Post by TheWitness »

If you want accurate data, you should migrate to the RPN expression instead of the CDEF method. The issue with the CDEF is that we have to go to the RRDfile for some of the data, which if say for example you are using boost, defeats the purpose of boost, and if both items have not been polled, results in inaccurate data.

The RPN Expression route should provide clearer answers while at the same time, not affecting scalability.
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
X-dark
Cacti User
Posts: 111
Joined: Wed Jun 18, 2008 10:21 am
Location: France

Re: Wrong current values with CDEF

Post by X-dark »

Thanks.
TheWitness wrote:If you want accurate data, you should migrate to the RPN expression instead of the CDEF method.
OK. Then I need to update to thold >= 0.4.6. Is there any constraint regarding Thold/Cacti/PIA/Boost versions? There is nothing about this in Thold README.
TheWitness wrote:The issue with the CDEF is that we have to go to the RRDfile for some of the data, which if say for example you are using boost, defeats the purpose of boost, and if both items have not been polled, results in inaccurate data.
It happens boost on demand updating is disabled on this specific Cacti instance.
TheWitness wrote:The RPN Expression route should provide clearer answers while at the same time, not affecting scalability.
Good.
Cedric Girard
User avatar
TheWitness
Developer
Posts: 17047
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: Wrong current values with CDEF

Post by TheWitness »

For your first question, I would be at PIA 2.9+, or in other words the 'G' version of Cacti. I would not goto the 'H' version due to some bugs to be cleaned in an upcoming release.
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
X-dark
Cacti User
Posts: 111
Joined: Wed Jun 18, 2008 10:21 am
Location: France

Re: Wrong current values with CDEF

Post by X-dark »

TheWitness wrote:For your first question, I would be at PIA 2.9+, or in other words the 'G' version of Cacti. I would not goto the 'H' version due to some bugs to be cleaned in an upcoming release.
Ok. This is what I was afraid of. I've begun to make some test yesterday with only a newer thold version and this does not seems to work very well.
Cedric Girard
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest