Change pdp per row for no consolidation

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

Moderators: Developers, Moderators

Post Reply
winnie
Posts: 26
Joined: Tue Feb 20, 2007 9:33 am

Change pdp per row for no consolidation

Post by winnie »

Hi,
I want to have no consolidation for my rra. I have resized my rra files using the resize.pl script. In cacti, the rra step shows as 1 for 5 minute daily, 30 minutes weekly, 2 hours monthly and 1 day yearly. This is for no consolidation requirement. Please see the following date source debug in cacti.
Data Source Debug

/usr/local/bin/rrdtool create \
/usr/local/share/cacti/rra/hk_cw_core2_traffic_in_7239.rrd \
--step 300 \
DS:traffic_in:COUNTER:600:0:622080000 \
DS:traffic_out:COUNTER:600:0:622080000 \
RRA:AVERAGE:0.5:1:288 \
RRA:AVERAGE:0.5:1:2016 \
RRA:AVERAGE:0.5:1:8928 \
RRA:AVERAGE:0.5:1:105120 \
RRA:MIN:0.5:1:288 \
RRA:MIN:0.5:1:2016 \
RRA:MIN:0.5:1:8928 \
RRA:MIN:0.5:1:105120 \
RRA:MAX:0.5:1:288 \
RRA:MAX:0.5:1:2016 \
RRA:MAX:0.5:1:8928 \
RRA:MAX:0.5:1:105120 \
RRA:LAST:0.5:1:288 \
RRA:LAST:0.5:1:2016 \
RRA:LAST:0.5:1:8928 \
RRA:LAST:0.5:1:105120 \

However, when I did a rrdtool info on this rra file, it still shows 6 pdp per row for weekly, 24 pdp per row for monthly and 288 for yearly. Please see the following rrdtool info.
rrd_version = "0003"
step = 300
last_update = 1172813405
ds[traffic_in].type = "COUNTER"
ds[traffic_in].minimal_heartbeat = 600
ds[traffic_in].min = 0.0000000000e+00
ds[traffic_in].max = 4.2949672950e+09
ds[traffic_in].last_ds = "111544785803737"
ds[traffic_in].value = 1.7252267457e+08
ds[traffic_in].unknown_sec = 0
ds[traffic_out].type = "COUNTER"
ds[traffic_out].minimal_heartbeat = 600
ds[traffic_out].min = 0.0000000000e+00
ds[traffic_out].max = 4.2949672950e+09
ds[traffic_out].last_ds = "56629143342449"
ds[traffic_out].value = 9.0944460567e+07
ds[traffic_out].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 600
rra[0].pdp_per_row = 1
rra[0].xff = 5.0000000000e-01
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[0].cdp_prep[1].value = NaN
rra[0].cdp_prep[1].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 2016
rra[1].pdp_per_row = 6
rra[1].xff = 5.0000000000e-01
rra[1].cdp_prep[0].value = 0.0000000000e+00
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[1].cdp_prep[1].value = 0.0000000000e+00
rra[1].cdp_prep[1].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 8928
rra[2].pdp_per_row = 24
rra[2].xff = 5.0000000000e-01
rra[2].cdp_prep[0].value = 5.4142094328e+08
rra[2].cdp_prep[0].unknown_datapoints = 0
rra[2].cdp_prep[1].value = 3.0226539916e+08
rra[2].cdp_prep[1].unknown_datapoints = 0
rra[3].cf = "AVERAGE"
rra[3].rows = 105120
rra[3].pdp_per_row = 288
rra[3].xff = 5.0000000000e-01
rra[3].cdp_prep[0].value = 1.7157505673e+09
rra[3].cdp_prep[0].unknown_datapoints = 0
rra[3].cdp_prep[1].value = 9.1185322041e+08
rra[3].cdp_prep[1].unknown_datapoints = 0
rra[4].cf = "MIN"
rra[4].rows = 600
rra[4].pdp_per_row = 1
rra[4].xff = 5.0000000000e-01
rra[4].cdp_prep[0].value = NaN
rra[4].cdp_prep[0].unknown_datapoints = 0
rra[4].cdp_prep[1].value = NaN
rra[4].cdp_prep[1].unknown_datapoints = 0
rra[5].cf = "MIN"
rra[5].rows = 2016
rra[5].pdp_per_row = 6
rra[5].xff = 5.0000000000e-01
rra[5].cdp_prep[0].value = 3.4492398615e+07
rra[5].cdp_prep[0].unknown_datapoints = 0
rra[5].cdp_prep[1].value = 1.8188250660e+07
rra[5].cdp_prep[1].unknown_datapoints = 0
rra[6].cf = "MIN"
rra[6].rows = 8928
rra[6].pdp_per_row = 24
rra[6].xff = 5.0000000000e-01
rra[6].cdp_prep[0].value = 2.7099736000e+07
rra[6].cdp_prep[0].unknown_datapoints = 0
rra[6].cdp_prep[1].value = 1.4716318229e+07
rra[6].cdp_prep[1].unknown_datapoints = 0
rra[7].cf = "MIN"
rra[7].rows = 105120
rra[7].pdp_per_row = 288
rra[7].xff = 5.0000000000e-01
rra[7].cdp_prep[0].value = 1.8040379711e+07
rra[7].cdp_prep[0].unknown_datapoints = 0
rra[7].cdp_prep[1].value = 9.4913697494e+06
rra[7].cdp_prep[1].unknown_datapoints = 0
rra[8].cf = "MAX"
rra[8].rows = 600
rra[8].pdp_per_row = 1
rra[8].xff = 5.0000000000e-01
rra[8].cdp_prep[0].value = NaN
rra[8].cdp_prep[0].unknown_datapoints = 0
rra[8].cdp_prep[1].value = NaN
rra[8].cdp_prep[1].unknown_datapoints = 0
rra[9].cf = "MAX"
rra[9].rows = 2016
rra[9].pdp_per_row = 6
rra[9].xff = 5.0000000000e-01
rra[9].cdp_prep[0].value = 3.4492398615e+07
rra[9].cdp_prep[0].unknown_datapoints = 0
rra[9].cdp_prep[1].value = 1.8188250660e+07
rra[9].cdp_prep[1].unknown_datapoints = 0
rra[10].cf = "MAX"
rra[10].rows = 8928
rra[10].pdp_per_row = 24
rra[10].xff = 5.0000000000e-01
rra[10].cdp_prep[0].value = 3.4492398615e+07
rra[10].cdp_prep[0].unknown_datapoints = 0
rra[10].cdp_prep[1].value = 1.8188250660e+07
rra[10].cdp_prep[1].unknown_datapoints = 0
rra[11].cf = "MAX"
rra[11].rows = 105120
rra[11].pdp_per_row = 288
rra[11].xff = 5.0000000000e-01
rra[11].cdp_prep[0].value = 3.4492398615e+07
rra[11].cdp_prep[0].unknown_datapoints = 0
rra[11].cdp_prep[1].value = 1.8188250660e+07
rra[11].cdp_prep[1].unknown_datapoints = 0
rra[12].cf = "LAST"
rra[12].rows = 600
rra[12].pdp_per_row = 1
rra[12].xff = 5.0000000000e-01
rra[12].cdp_prep[0].value = NaN
rra[12].cdp_prep[0].unknown_datapoints = 0
rra[12].cdp_prep[1].value = NaN
rra[12].cdp_prep[1].unknown_datapoints = 0
rra[13].cf = "LAST"
rra[13].rows = 2016
rra[13].pdp_per_row = 6
rra[13].xff = 5.0000000000e-01
rra[13].cdp_prep[0].value = 3.4492398615e+07
rra[13].cdp_prep[0].unknown_datapoints = 0
rra[13].cdp_prep[1].value = 1.8188250660e+07
rra[13].cdp_prep[1].unknown_datapoints = 0
rra[14].cf = "LAST"
rra[14].rows = 8928
rra[14].pdp_per_row = 24
rra[14].xff = 5.0000000000e-01
rra[14].cdp_prep[0].value = 3.4492398615e+07
rra[14].cdp_prep[0].unknown_datapoints = 0
rra[14].cdp_prep[1].value = 1.8188250660e+07
rra[14].cdp_prep[1].unknown_datapoints = 0
rra[15].cf = "LAST"
rra[15].rows = 105120
rra[15].pdp_per_row = 288
rra[15].xff = 5.0000000000e-01
rra[15].cdp_prep[0].value = 3.4492398615e+07
rra[15].cdp_prep[0].unknown_datapoints = 0
rra[15].cdp_prep[1].value = 1.8188250660e+07
rra[15].cdp_prep[1].unknown_datapoints = 0

Is there a way to change all the pdp per row to 1 ? I do not want any consolidation. Can someone help please? :o

Thank you.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Most of your questions should be answered at the first link of my signature (see: RRDTool section).
Reinhard
winnie
Posts: 26
Joined: Tue Feb 20, 2007 9:33 am

Post by winnie »

Hi Reinhard,

I have read many replies by you in the forum regarding no consolidation issues. I had followed closely all of your instructions on resize.pl for extending the rows in the existing rrd files. I also created new templates with step size 1 for 5 minutes daily, weekly, monthly and yearly for no consolidation purpose. All new graphs created using this new no consolidation rra setting are working fine for me. However, my existing rrd files still have the old consolidation setting.
I could not change it to 1 pdp per row for weekly, monthly and yearly in the rrd files.
I understand that from one of your reply, you recommend to dump and reload the rrd files.
I do not know what do you mean by dump and reload rrd files. I don't understand how the rrdtool works on these rrd files.

Can you elaborate further on this? :oops:
Maybe you can also let me know the url which contains this answer.

Thank you.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

winnie wrote:...
I could not change it to 1 pdp per row for weekly, monthly and yearly in the rrd files.
I understand that from one of your reply, you recommend to dump and reload the rrd files.
I do not know what do you mean by dump and reload rrd files. I don't understand how the rrdtool works on these rrd files. ...
There's a fundamental misunderstanding (which is enforced by cacti's way of defining "rra related parameters"). Basically, there are no weekly, monthly etc. rra's in any rrd file.
RRDTool defines different levels of consolidation only. It does not define timespans explicitely. It only defines the AMOUNT OF DATAPOINTS for each consolidation level.
So, in fact, you are trying to keep only one level of consolidation, defined by step in the rra definition. And, as you want to omit consolidation, this equals step=1.
By default, all "old" rrd files will have 4 levels of consolidation, step=1,6,24,288, respectively. Forget about the last three ones (well, they will use some amount of space; but forget about this for the time being). So lets deal with the first rra (step=1) only.
You want to extend this rra so it spans a longer time. As I said already, there is no real timespan with rra definitions. This is dealt with by defining the number of rows, as they are called in rrdtool lingo. To increase "timespan", you will have to increase the number of rows. You may compute the timespan by multiplying rows * step.
Hope this clarifies things a bit. If not, do not hesitate to ask
Reinhard
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

I have added this text at http://docs.cacti.net/node/54
Reinhard
winnie
Posts: 26
Joined: Tue Feb 20, 2007 9:33 am

Post by winnie »

Hi Reinhard,

Thank you very much for your patience and time to answer my doubts. I still could not figure out what goes wrong with my existing graphs. The weekly graph display 5 minutes reading only for about 2 days, after which, it consolidates half hourly. It seems that the consolidation still apply to all my existing graphs. This does not happen to all my newly created graphs.
As I have mentioned in my earlier forum, the pdp per row for all my existing rrd files still display 6 rows per pdp for weekly. This also applies to my monthly and yearly rrd files, which shows 24 and 288 respectively for pdp per row. For my newly created graph, the pdp per row is 1 for daily, weekly, monthly and yearly.

As I need to keep historical data for all my existing graphs, I could not delete the existing rrd file. I also want all my graphs to display 5 minutes daily, weekly, monthly and yearly trend.
I have only step equal 1 for no consolidation in the rra setting for my daily, weekly, monthly and yearly in cacti. All my graphs in cacti are using this new rra setting.
I also have resized all my existing old rrd files. Now, each existing old rrd file has increased from 189KB to about 7MB per rrd file.

Can you advise me how to solve my problem?
:oops:
Thank you.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

I try to answer by using your example. Again, your mis-understanding is the same. THERE IS NO WEEKLY RRA! Sorry for that. Let's see:
winnie wrote:
/usr/local/bin/rrdtool create \
/usr/local/share/cacti/rra/hk_cw_core2_traffic_in_7239.rrd \
--step 300 \
DS:traffic_in:COUNTER:600:0:622080000 \
DS:traffic_out:COUNTER:600:0:622080000 \
RRA:AVERAGE:0.5:1:105120
This is, what you need. As you do not want consolidation to occur (I will show you in a second, that this is not really possible), you only need ONE rra (an rra is NOT defined by a timespan but by the number of pdp's it aggregates). If (and only if) no consolidation shall occur, you even need no MIN, MAX, LAST.
Why? MIN is the consolidation function that defines, how data sould be represented after consolidating. An example:
Let's assume, an RRA holds the data "4,6,4,6,4,6" before consolidation.
After consolidation, those 6 values will be represented by only one. But this one value is different (generally) for each of those consolidation functions:
AVERAGE: replace 6 values by their average. AVERAGE = 5 in this case
MIN: replace 6 values by their minimum. MIN = 4 in this case
MAX: replace 6 values by their maximum. MAX = 6 in this case
LAST: replace 6 values by the last one in sequence. LAST = 6 in this case
But if there is no RRA that defines a pdp value > 1, there will be no consolidation. If there is no consolidation, nothing will be "replaced". MIN, MAX, AVERAGE, LAST loose their meaning in this case. But as at least one CF is required, take AVERAGE.

Huh. I hope this is not too hard to understand. But don't give up now!
Up to now, I did not speak about timespans (daily, weekly, monthly yearly). Why? There is no such thing as a timespan with rrd!
You will ask: But cacti DEFINES timespans.
Yes, it does. And we are not proud of that, because it's simply wrong (BTB: cacti 0.9 will no longer defines timespans with rra's). Unfortunately, it mangles rra definitions with "display options". You may even view at the rrd file defined above with a weekly, monthly, yearly timespan. Timespan is the definition of start and end time. These are options that exist for "rrdtool graph" only.
But why does cacti do so?
This was an easy way to allow for 4 standard views at rrd data. And I suppose, you will want to keep those views.

So, the problem is: How am I able to define an rrd file with only ONE rra but keep all FOUR timespan views?
The answer is: This is impossible. But do not give up. There's a workaround only a few seconds away.
First, let's keep the definition from above. To implement it, use the first (denoted: daily) rra and increase the row count to your needs. This will be enough to store all data you need. To keep the other 3 timespans, it would be ok to decrease their row count to 1 (this is the lowest allowable number for rrdtool). It will not bring that much file size overhead and keeps those insane timespans.

That's all for now.
I'm sure, at least two questions will arise
1. How to change existing files using "resize.pl" to achieve that
2. You will notice sth "strange" when viewing at the weekly, monthly, yearly timespans. I will not talk about this at the time being to avoid more confusion (all of this has already been discussed, but perhaps I did not make myself plain enough)

Reinhard
winnie
Posts: 26
Joined: Tue Feb 20, 2007 9:33 am

Post by winnie »

Hi Reinhard,

I had created a no consolidation rra setting according to your recommendation. However, I could only get 1 day traffic, after which there is no more traffic subsequently. Below is my rra setting in cacti.

Daily (no con) steps:1 rows:105120 timespan: 86400
Weekly (no con) steps:1 rows:1 timespan:604800
Monthly (no con) steps:1 rows:1 timespan: 2678400
Yearly (no con) steps:1 rows:1 timespan: 33053184

I have changed one of my existing data source and graph to point to the data and graph template which has this rra setting.

Is there something wrong with my rra setting in Cacti? Also, do I need to resize my existing rrd file? Below is my existing rrd file setting.

filename = "localhost_traffic_in_6787.rrd"
rrd_version = "0003"
step = 300
last_update = 1173707101
ds[traffic_in].type = "COUNTER"
ds[traffic_in].minimal_heartbeat = 600
ds[traffic_in].min = 0.0000000000e+00
ds[traffic_in].max = 1.0000000000e+08
ds[traffic_in].last_ds = "1870059324"
ds[traffic_in].value = 1.9883510000e+04
ds[traffic_in].unknown_sec = 0
ds[traffic_out].type = "COUNTER"
ds[traffic_out].minimal_heartbeat = 600
ds[traffic_out].min = 0.0000000000e+00
ds[traffic_out].max = 1.0000000000e+08
ds[traffic_out].last_ds = "36635489"
ds[traffic_out].value = 1.9885233333e+03
ds[traffic_out].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 600
rra[0].pdp_per_row = 1
rra[0].xff = 5.0000000000e-01
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[0].cdp_prep[1].value = NaN
rra[0].cdp_prep[1].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 2016
rra[1].pdp_per_row = 6
rra[1].xff = 5.0000000000e-01
rra[1].cdp_prep[0].value = 7.0537366367e+04
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[1].cdp_prep[1].value = 8.2163414333e+03
rra[1].cdp_prep[1].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 8928
rra[2].pdp_per_row = 24
rra[2].xff = 5.0000000000e-01
rra[2].cdp_prep[0].value = 2.1621380269e+05
rra[2].cdp_prep[0].unknown_datapoints = 12
rra[2].cdp_prep[1].value = 7.5004187778e+04
rra[2].cdp_prep[1].unknown_datapoints = 12
rra[3].cf = "AVERAGE"
rra[3].rows = 105120
rra[3].pdp_per_row = 288
rra[3].xff = 5.0000000000e-01
rra[3].cdp_prep[0].value = 2.1621380269e+05
rra[3].cdp_prep[0].unknown_datapoints = 156
rra[3].cdp_prep[1].value = 7.5004187778e+04
rra[3].cdp_prep[1].unknown_datapoints = 156
rra[4].cf = "MIN"
rra[4].rows = 600
rra[4].pdp_per_row = 1
rra[4].xff = 5.0000000000e-01
rra[4].cdp_prep[0].value = NaN
rra[4].cdp_prep[0].unknown_datapoints = 0
rra[4].cdp_prep[1].value = NaN
rra[4].cdp_prep[1].unknown_datapoints = 0
rra[5].cf = "MIN"
rra[5].rows = 2016
rra[5].pdp_per_row = 6
rra[5].xff = 5.0000000000e-01
rra[5].cdp_prep[0].value = 1.9908111956e+04
rra[5].cdp_prep[0].unknown_datapoints = 0
rra[5].cdp_prep[1].value = 1.9913330444e+03
rra[5].cdp_prep[1].unknown_datapoints = 0
rra[6].cf = "MIN"
rra[6].rows = 8928
rra[6].pdp_per_row = 24
rra[6].xff = 5.0000000000e-01
rra[6].cdp_prep[0].value = 1.9908111956e+04
rra[6].cdp_prep[0].unknown_datapoints = 12
rra[6].cdp_prep[1].value = 1.9913330444e+03
rra[6].cdp_prep[1].unknown_datapoints = 12
rra[7].cf = "MIN"
rra[7].rows = 105120
rra[7].pdp_per_row = 288
rra[7].xff = 5.0000000000e-01
rra[7].cdp_prep[0].value = 1.9908111956e+04
rra[7].cdp_prep[0].unknown_datapoints = 156
rra[7].cdp_prep[1].value = 1.9913330444e+03
rra[7].cdp_prep[1].unknown_datapoints = 156
rra[8].cf = "MAX"
rra[8].rows = 600
rra[8].pdp_per_row = 1
rra[8].xff = 5.0000000000e-01
rra[8].cdp_prep[0].value = NaN
rra[8].cdp_prep[0].unknown_datapoints = 0
rra[8].cdp_prep[1].value = NaN
rra[8].cdp_prep[1].unknown_datapoints = 0
rra[9].cf = "MAX"
rra[9].rows = 2016
rra[9].pdp_per_row = 6
rra[9].xff = 5.0000000000e-01
rra[9].cdp_prep[0].value = 2.7251133267e+04
rra[9].cdp_prep[0].unknown_datapoints = 0
rra[9].cdp_prep[1].value = 1.3400663500e+04
rra[9].cdp_prep[1].unknown_datapoints = 0
rra[10].cf = "MAX"
rra[10].rows = 8928
rra[10].pdp_per_row = 24
rra[10].xff = 5.0000000000e-01
rra[10].cdp_prep[0].value = 2.7251133267e+04
rra[10].cdp_prep[0].unknown_datapoints = 12
rra[10].cdp_prep[1].value = 2.1962483344e+04
rra[10].cdp_prep[1].unknown_datapoints = 12
rra[11].cf = "MAX"
rra[11].rows = 105120
rra[11].pdp_per_row = 288
rra[11].xff = 5.0000000000e-01
rra[11].cdp_prep[0].value = 2.7251133267e+04
rra[11].cdp_prep[0].unknown_datapoints = 156
rra[11].cdp_prep[1].value = 2.1962483344e+04
rra[11].cdp_prep[1].unknown_datapoints = 156
rra[12].cf = "LAST"
rra[12].rows = 600
rra[12].pdp_per_row = 1
rra[12].xff = 5.0000000000e-01
rra[12].cdp_prep[0].value = NaN
rra[12].cdp_prep[0].unknown_datapoints = 0
rra[12].cdp_prep[1].value = NaN
rra[12].cdp_prep[1].unknown_datapoints = 0
rra[13].cf = "LAST"
rra[13].rows = 2016
rra[13].pdp_per_row = 6
rra[13].xff = 5.0000000000e-01
rra[13].cdp_prep[0].value = 1.9908111956e+04
rra[13].cdp_prep[0].unknown_datapoints = 0
rra[13].cdp_prep[1].value = 1.9913330444e+03
rra[13].cdp_prep[1].unknown_datapoints = 0
rra[14].cf = "LAST"
rra[14].rows = 8928
rra[14].pdp_per_row = 24
rra[14].xff = 5.0000000000e-01
rra[14].cdp_prep[0].value = 1.9908111956e+04
rra[14].cdp_prep[0].unknown_datapoints = 12
rra[14].cdp_prep[1].value = 1.9913330444e+03
rra[14].cdp_prep[1].unknown_datapoints = 12
rra[15].cf = "LAST"
rra[15].rows = 105120
rra[15].pdp_per_row = 288
rra[15].xff = 5.0000000000e-01
rra[15].cdp_prep[0].value = 1.9908111956e+04
rra[15].cdp_prep[0].unknown_datapoints = 156
rra[15].cdp_prep[1].value = 1.9913330444e+03
rra[15].cdp_prep[1].unknown_datapoints = 156


Please advise.
:oops:

Thank you.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

winnie wrote:Hi Reinhard,

I had created a no consolidation rra setting according to your recommendation. However, I could only get 1 day traffic, after which there is no more traffic subsequently. Below is my rra setting in cacti.

Daily (no con) steps:1 rows:105120 timespan: 86400
Weekly (no con) steps:1 rows:1 timespan:604800
Monthly (no con) steps:1 rows:1 timespan: 2678400
Yearly (no con) steps:1 rows:1 timespan: 33053184
Please post output of rrdtool info for this. And a screenshot when clicking the graph for this file would be fine.
Reinhard
winnie
Posts: 26
Joined: Tue Feb 20, 2007 9:33 am

Post by winnie »

Hi Reinhard,

The following is the rrd info setting as shown in cacti.

usr/local/bin/rrdtool create \
/usr/local/share/cacti/rra/localhost_traffic_in_6787.rrd \
--step 300 \
DS:traffic_in:COUNTER:600:0:100000000000 \
DS:traffic_out:COUNTER:600:0:100000000000 \
RRA::0.5:1:1 \
RRA:AVERAGE:0.5:1:1 \
RRA:AVERAGE:0.5:1:1 \
RRA:AVERAGE:0.5:1:105120 \

The following is the rrdtool info on this rrd file.

filename = "localhost_traffic_in_6787.rrd"
rrd_version = "0003"
step = 300
last_update = 1173826501
ds[traffic_in].type = "COUNTER"
ds[traffic_in].minimal_heartbeat = 600
ds[traffic_in].min = 0.0000000000e+00
ds[traffic_in].max = 1.0000000000e+08
ds[traffic_in].last_ds = "526132835"
ds[traffic_in].value = 1.8784366667e+04
ds[traffic_in].unknown_sec = 0
ds[traffic_out].type = "COUNTER"
ds[traffic_out].minimal_heartbeat = 600
ds[traffic_out].min = 0.0000000000e+00
ds[traffic_out].max = 1.0000000000e+08
ds[traffic_out].last_ds = "560605152"
ds[traffic_out].value = 1.8617866667e+03
ds[traffic_out].unknown_sec = 0
rra[0].cf = "AVERAGE"
rra[0].rows = 105120
rra[0].pdp_per_row = 1
rra[0].xff = 5.0000000000e-01
rra[0].cdp_prep[0].value = NaN
rra[0].cdp_prep[0].unknown_datapoints = 0
rra[0].cdp_prep[1].value = NaN
rra[0].cdp_prep[1].unknown_datapoints = 0
rra[1].cf = "AVERAGE"
rra[1].rows = 2016
rra[1].pdp_per_row = 6
rra[1].xff = 5.0000000000e-01
rra[1].cdp_prep[0].value = 1.1549834284e+05
rra[1].cdp_prep[0].unknown_datapoints = 0
rra[1].cdp_prep[1].value = 4.0836970700e+04
rra[1].cdp_prep[1].unknown_datapoints = 0
rra[2].cf = "AVERAGE"
rra[2].rows = 8928
rra[2].pdp_per_row = 24
rra[2].xff = 5.0000000000e-01
rra[2].cdp_prep[0].value = 2.5229715299e+05
rra[2].cdp_prep[0].unknown_datapoints = 0
rra[2].cdp_prep[1].value = 6.5660164189e+04
rra[2].cdp_prep[1].unknown_datapoints = 0
rra[3].cf = "AVERAGE"
rra[3].rows = 105120
rra[3].pdp_per_row = 288
rra[3].xff = 5.0000000000e-01
rra[3].cdp_prep[0].value = 6.8718999880e+06
rra[3].cdp_prep[0].unknown_datapoints = 0
rra[3].cdp_prep[1].value = 1.3375137317e+06
rra[3].cdp_prep[1].unknown_datapoints = 0
rra[4].cf = "MIN"
rra[4].rows = 105120
rra[4].pdp_per_row = 1
rra[4].xff = 5.0000000000e-01
rra[4].cdp_prep[0].value = NaN
rra[4].cdp_prep[0].unknown_datapoints = 0
rra[4].cdp_prep[1].value = NaN
rra[4].cdp_prep[1].unknown_datapoints = 0
rra[5].cf = "MIN"
rra[5].rows = 2016
rra[5].pdp_per_row = 6
rra[5].xff = 5.0000000000e-01
rra[5].cdp_prep[0].value = 1.7648354544e+04
rra[5].cdp_prep[0].unknown_datapoints = 0
rra[5].cdp_prep[1].value = 1.8647166556e+03
rra[5].cdp_prep[1].unknown_datapoints = 0
rra[6].cf = "MIN"
rra[6].rows = 8928
rra[6].pdp_per_row = 24
rra[6].xff = 5.0000000000e-01
rra[6].cdp_prep[0].value = 1.7648354544e+04
rra[6].cdp_prep[0].unknown_datapoints = 0
rra[6].cdp_prep[1].value = 1.8647166556e+03
rra[6].cdp_prep[1].unknown_datapoints = 0
rra[7].cf = "MIN"
rra[7].rows = 105120
rra[7].pdp_per_row = 288
rra[7].xff = 5.0000000000e-01
rra[7].cdp_prep[0].value = 1.7428248733e+04
rra[7].cdp_prep[0].unknown_datapoints = 0
rra[7].cdp_prep[1].value = 1.4611349000e+03
rra[7].cdp_prep[1].unknown_datapoints = 0
rra[8].cf = "MAX"
rra[8].rows = 105120
rra[8].pdp_per_row = 1
rra[8].xff = 5.0000000000e-01
rra[8].cdp_prep[0].value = NaN
rra[8].cdp_prep[0].unknown_datapoints = 0
rra[8].cdp_prep[1].value = NaN
rra[8].cdp_prep[1].unknown_datapoints = 0
rra[9].cf = "MAX"
rra[9].rows = 2016
rra[9].pdp_per_row = 6
rra[9].xff = 5.0000000000e-01
rra[9].cdp_prep[0].value = 2.5168558289e+04
rra[9].cdp_prep[0].unknown_datapoints = 0
rra[9].cdp_prep[1].value = 2.0419672867e+04
rra[9].cdp_prep[1].unknown_datapoints = 0
rra[10].cf = "MAX"
rra[10].rows = 8928
rra[10].pdp_per_row = 24
rra[10].xff = 5.0000000000e-01
rra[10].cdp_prep[0].value = 2.7148320700e+04
rra[10].cdp_prep[0].unknown_datapoints = 0
rra[10].cdp_prep[1].value = 2.0419672867e+04
rra[10].cdp_prep[1].unknown_datapoints = 0
rra[11].cf = "MAX"
rra[11].rows = 105120
rra[11].pdp_per_row = 288
rra[11].xff = 5.0000000000e-01
rra[11].cdp_prep[0].value = 1.1382866309e+05
rra[11].cdp_prep[0].unknown_datapoints = 0
rra[11].cdp_prep[1].value = 3.0947422833e+04
rra[11].cdp_prep[1].unknown_datapoints = 0
rra[12].cf = "LAST"
rra[12].rows = 105120
rra[12].pdp_per_row = 1
rra[12].xff = 5.0000000000e-01
rra[12].cdp_prep[0].value = NaN
rra[12].cdp_prep[0].unknown_datapoints = 0
rra[12].cdp_prep[1].value = NaN
rra[12].cdp_prep[1].unknown_datapoints = 0
rra[13].cf = "LAST"
rra[13].rows = 2016
rra[13].pdp_per_row = 6
rra[13].xff = 5.0000000000e-01
rra[13].cdp_prep[0].value = 1.8794448878e+04
rra[13].cdp_prep[0].unknown_datapoints = 0
rra[13].cdp_prep[1].value = 1.8647166556e+03
rra[13].cdp_prep[1].unknown_datapoints = 0
rra[14].cf = "LAST"
rra[14].rows = 8928
rra[14].pdp_per_row = 24
rra[14].xff = 5.0000000000e-01
rra[14].cdp_prep[0].value = 1.8794448878e+04
rra[14].cdp_prep[0].unknown_datapoints = 0
rra[14].cdp_prep[1].value = 1.8647166556e+03
rra[14].cdp_prep[1].unknown_datapoints = 0
rra[15].cf = "LAST"
rra[15].rows = 105120
rra[15].pdp_per_row = 288
rra[15].xff = 5.0000000000e-01
rra[15].cdp_prep[0].value = 1.8794448878e+04
rra[15].cdp_prep[0].unknown_datapoints = 0
rra[15].cdp_prep[1].value = 1.8647166556e+03
rra[15].cdp_prep[1].unknown_datapoints = 0

This rrd file is existed and has consolidation done before I decide to change it to no consolidation. As such, you can see there is consildation value for each pdp_per_row for weekly, monthly and yearly.

I do not know how to insert my graph in this reply. However, when I re-apply this rra setting again. It starts to have data from 12.3.07 20:45 but again stop at 14.3.07 at 06:55 hr.

Please advise which part has gone wrong. :oops:

Thank you.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

winnie wrote:Hi Reinhard,

The following is the rrd info setting as shown in cacti.

usr/local/bin/rrdtool create \
/usr/local/share/cacti/rra/localhost_traffic_in_6787.rrd \
--step 300 \
DS:traffic_in:COUNTER:600:0:100000000000 \
DS:traffic_out:COUNTER:600:0:100000000000 \
RRA::0.5:1:1 \
RRA:AVERAGE:0.5:1:1 \
RRA:AVERAGE:0.5:1:1 \
RRA:AVERAGE:0.5:1:105120 \
That one is broken. The first RRA is simply wrong, no CF given. 2nd and 3rd are wrong, too. Please compare to my example from above; it holds only one RRA line.
Reinhard
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

As a step-by-step advice. Please start with RRA definitions like those given in http://forums.cacti.net/viewtopic.php?p=58007#58007.
Reinhard
winnie
Posts: 26
Joined: Tue Feb 20, 2007 9:33 am

Post by winnie »

Hi Reinhard,

I managed to create the rra setting with no consolidation correctly. Now, I have my new graph created using no consolidation rra setting as given by you earlier. I also set the weekly, monthly and yearly rra setting to step 1 and row 1. I can view the weekly, monthly and yearly graph with no problem. The rrd file size is much smaller, only 1.6MB.

However, I have problem changing all my existing graphs' consolidated data and graph templates to no consolidation data and graph templates.
When I change the consolidated data and graph templates to the one with no consolidation in cacti, there is no traffic display subsequently. I need to change them back to the original consolidated data and graph templates then the traffic starts comming in.

Can you advise how to change the existing data and graph consolidated templates to the one with no consolidation in cacti? :(

Thank you.
User avatar
gandalf
Developer
Posts: 22383
Joined: Thu Dec 02, 2004 2:46 am
Location: Muenster, Germany
Contact:

Post by gandalf »

Never solved this before. Why? It's merely cosmetic (for me). If you are using the same timespans for both un-consolidated and consolidated Data Templates, there's no need to change anything (apart from cosmetics). I might have a look at how to do if you wish, but this would be towards the bottom of my wishlist.
Perhaps it would be more important to know how to grow/shrink the existing rrd files (grow the first consolidation level, shrink the other one's). Growing is handled by my script by default. Shrinking was contributed lately by some other cacti user as a patch.
I hope I did not overlook anything
Reinhard
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests