Summing other data than Traffic

Post general support questions here that do not specifically fall into the Linux or Windows categories.

Moderators: Developers, Moderators

Post Reply
christschn
Posts: 3
Joined: Tue Mar 13, 2007 11:56 am
Location: Austria

Summing other data than Traffic

Post by christschn »

Hi,

I have got my Cacti graphing ftp uploads. It would be nice if the graph contains a total uploads field that tells me how much uploads there have been so far (in this timeperiod). The datasource contains the number of uploads from the past five minutes.

I have only found this for traffic-summation via the |sum:auto:current:2:auto| in an COMMENT field. But if i try the same for my upload-graph, the numbers are simply wrong.

Can anyone help me out with this? I have been trying for quite some time now, but had no luck...

thanks in Advance
christschn
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

What is the type of the data source item? Counter or Gauge.

If they are gauge, then sum will not with with them.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
christschn
Posts: 3
Joined: Tue Mar 13, 2007 11:56 am
Location: Austria

Post by christschn »

It's a gauge data-source. The value stored in the rrd is the number of uploads in the past 5 minutes. It's not an increasing counter.

I thought a gauge type would make the most sense for this type of data. Am I wrong?

christschn
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

If you would like to do summation, I would suggest you do a counter. The summation uses the ever increasing value to calculate the total number over the period and is more accurate. I really haven't sat down and figured out why, but at first glance, I would say that the gauge value is being divided by the consolidation interval (5 minutes) giving you a very low number in the sum calculation.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
christschn
Posts: 3
Joined: Tue Mar 13, 2007 11:56 am
Location: Austria

Post by christschn »

I finally worked it out. Counter did not work for me, because it assumes, that the value is steadily increasing. So I tried Absolute as data type. Now summation works like a charm.

The retrieved value (uploads per 5 minutes) is being stored as uploads per seconds and can now be properly summed for each timeperiod by rrdtool.

thanks again for your help
christschn
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Post by rony »

I always forget about absolute... :-?

See, even I don't know everything! :o

Sush Larry! :P
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest