Reportit: function for faling below threshold

General discussion about Plugins for Cacti

Moderators: Developers, Moderators

Post Reply
torstentfk
Cacti User
Posts: 367
Joined: Tue Apr 05, 2005 9:52 am
Location: Munich, Germany

Reportit: function for faling below threshold

Post by torstentfk »

Hello,

any solution for this problem:
I have a DS which is normaly 1 and in an error case it takes the value -2.
I want to have the time/duration of all values which are below 0.

Is reportit the right tool/plugin?

Torsten
User avatar
browniebraun
Developer
Posts: 791
Joined: Tue Jun 13, 2006 1:17 am
Location: Cologne, Germany

Re: Reportit: function for faling below threshold

Post by browniebraun »

Due to the fact that the sum of all values over zero is equal to the number of measured values which are 1,
you should be able use following formula to get the number of seconds:

f_num*step*(100-f_dot(0))/100


Best regards
-Andreas-


BTW: Have you made some pictures at the last CCC?
Hat das Blümchen einen Knick, war der Schmetterling zu dick! ;)
reportit v0.7.5a
SNMPAgent v0.2.3
Download ReportIt | Download SNMPAgent | ReportIt SVN | ReportIt Templates | Wish list
NetAdmin
Cacti User
Posts: 98
Joined: Wed Aug 30, 2006 8:45 pm

Re: Reportit: function for faling below threshold

Post by NetAdmin »

I'm trying to do something very similar where I have a data source that checks the status of an interface and returns a value of 1 if the interface is up and 2 if the interface is down. So, I'm basically trying to build a report that will show how long (in minutes since that is the polling cycle) interfaces were down (or had a value of 2) during a given time period. Can't quite figure out the formula. :cry:

Regards,

John
User avatar
browniebraun
Developer
Posts: 791
Joined: Tue Jun 13, 2006 1:17 am
Location: Cologne, Germany

Re: Reportit: function for faling below threshold

Post by browniebraun »

NetAdmin wrote:I'm trying to do something very similar where I have a data source that checks the status of an interface and returns a value of 1 if the interface is up and 2 if the interface is down. So, I'm basically trying to build a report that will show how long (in minutes since that is the polling cycle) interfaces were down (or had a value of 2) during a given time period. Can't quite figure out the formula. :cry:

Regards,

John
Hey John,
in that case I would use "f_num*step*f_dot(1)/100/60".

Explanation: f_num*step will be the reporting period in seconds. f_dot(1) returns the percentage of all measured values greater than 1, so that "f_num*step*f_dot(1)/100" will return the number of seconds the interface was down.

Best regards
-Andi
Hat das Blümchen einen Knick, war der Schmetterling zu dick! ;)
reportit v0.7.5a
SNMPAgent v0.2.3
Download ReportIt | Download SNMPAgent | ReportIt SVN | ReportIt Templates | Wish list
NetAdmin
Cacti User
Posts: 98
Joined: Wed Aug 30, 2006 8:45 pm

Re: Reportit: function for faling below threshold

Post by NetAdmin »

This is excellent, Andi.. Thanks so much. :D

Would it be possible to count the number of times that the value changed from 1 to 2? In other words, in addition to seeing how many total minutes the interface was down, we would like to see how many times it went down so that we can determine if it was a single outage or multiple outages. I hope this makes sense.

John
User avatar
browniebraun
Developer
Posts: 791
Joined: Tue Jun 13, 2006 1:17 am
Location: Cologne, Germany

Re: Reportit: function for faling below threshold

Post by browniebraun »

Not yet.
Sounds to me that we need one or two new functions. ;)

Regards
-Andi
Hat das Blümchen einen Knick, war der Schmetterling zu dick! ;)
reportit v0.7.5a
SNMPAgent v0.2.3
Download ReportIt | Download SNMPAgent | ReportIt SVN | ReportIt Templates | Wish list
torstentfk
Cacti User
Posts: 367
Joined: Tue Apr 05, 2005 9:52 am
Location: Munich, Germany

Re: Reportit: function for faling below threshold

Post by torstentfk »

Hi,

first: I have no pictures from 5.eu.CCC - I am on the photos.

second: I tried this formular and it works. But be aware that you might have to change the rra to keep the granularity on the values.

For the additional formular, nice to have:
F_dbt (below threshold); or change it in:
f_tt (thold, direction): triggering threshold, direct=+1 -> over threshold; -1 = below threshold.
f_mx (thold, direction): maximum intervall of broken thold in seconds.


Torsten
NetAdmin
Cacti User
Posts: 98
Joined: Wed Aug 30, 2006 8:45 pm

Re: Reportit: function for faling below threshold

Post by NetAdmin »

browniebraun wrote:Not yet.
Sounds to me that we need one or two new functions. ;)

Regards
-Andi
That would be great, Andi! I'd be more than happy to test out new functions prior to the next release.. :D

John
alkman82
Cacti User
Posts: 50
Joined: Tue Dec 15, 2009 7:32 am
Location: Athens

Re: Reportit: function for faling below threshold

Post by alkman82 »

Let's get back to life this thread!
My purpose is to locate bottlenecks in our network. For example one Gigabit interface that has a flatted (haircuted) traffic for some time at 300Mbps. Iike the following image:

For the moment we have created a measurant with the following function "f_num*step*f_dot(f_max-100000)/100/60 "but seems wrong ... Any ideas please?
Attachments
cacti_flat.png
cacti_flat.png (34.84 KiB) Viewed 2119 times
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest