Closed DFlexy closed 12 months ago
Yea, I'm grumbling about this. The it can be included, but the logic is tricky. It only works in a few cases, specifically when you are totaling all data sources.
So, update lib/api_aggregate.php
from the 1.2.x
branch and then resave the Aggregate Template. Let me know how it goes. It should fix it.
I did one minor QA to also handle the hrules as well.
Hello, I made the adjustments to the lines and nothing, then I replaced the file and nothing. I'm putting the debugs of the aggregated graphs with the problem and the debug of a simple graph working, remembering that they both use the same template
Version 1.2.25
Debug here
RRDtool Command: /usr/bin/rrdtool graph - \ --imgformat=SVG \ --start='-86400' \ --end='-300' \ --pango-markup \ --title='OTHERS' \ --vertical-label='bits por segundo' \ --slope-mode \ --base=1000 \ --height=150 \ --width=700 \ --alt-autoscale \ COMMENT:"From 19-11-2023 08\:43\:04 To 20-11-2023 08\:38\:04\c" \ COMMENT:" \n" \ --color BACK#F3F3F3 \ --color CANVAS#FDFDFD \ --color SHADEA#CBCBCB \ --color SHADEB#999999 \ --color FONT#000000 \ --color AXIS#2C4D43 \ --color ARROW#2C4D43 \ --color FRAME#2C4D43 \ --border 1 \ --font TITLE:9: \ --font AXIS:8: \ --font LEGEND:9: \ --font UNIT:8: \ --font WATERMARK:8: \ --slope-mode \ --watermark 'Por ' \ DEF:a='/usr/share/cacti/rra/10_10_10_10_traffic_in_1148.rrd':'traffic_in':AVERAGE \ DEF:b='/usr/share/cacti/rra/10_10_10_10_traffic_in_1148.rrd':'traffic_out':AVERAGE \ DEF:c='/usr/share/cacti/rra/10_10_10_10_traffic_in_1238.rrd':'traffic_in':AVERAGE \ DEF:d='/usr/share/cacti/rra/10_10_10_10_traffic_in_1238.rrd':'traffic_out':AVERAGE \ CDEF:cdefa='a,0,*' \ CDEF:cdefb='b,0,*' \ CDEF:cdefc='c,0,*' \ CDEF:cdefd='d,0,*' \ CDEF:cdefe='TIME,1700480284,GT,a,a,UN,0,a,IF,IF,TIME,1700480284,GT,c,c,UN,0,c,IF,IF,+,8,*' \ CDEF:cdefi='TIME,1700480284,GT,b,b,UN,0,b,IF,IF,TIME,1700480284,GT,d,d,UN,0,d,IF,IF,+,8,*' \ AREA:cdefa#306EFF7F: \ AREA:cdefb#E8A3177F: \ AREA:cdefc#306EFF7F: \ AREA:cdefd#E8A3177F: \ AREA:cdefe#306EFF7F:'Total Inbound ' \ GPRINT:cdefe:LAST:'Current\:%8.2lf %s' \ GPRINT:cdefe:AVERAGE:'Average\:%8.2lf %s' \ GPRINT:cdefe:MAX:'Maximum\:%8.2lf %s\n' \ AREA:cdefi#E8A3177F:'Total Outbound' \ GPRINT:cdefi:LAST:'Current\:%8.2lf %s' \ GPRINT:cdefi:AVERAGE:'Average\:%8.2lf %s' \ GPRINT:cdefi:MAX:'Maximum\:%8.2lf %s\n' \ COMMENT:' \n' \ HRULE:62026371223.2#800080FF:'99th Percentile In ->' RRDtool Command lengths = 1760 characters. RRDtool Says: SVG/XML Output OK
Simple graph here OK
Debug here
RRDtool Command: /usr/bin/rrdtool graph - \ --imgformat=SVG \ --start='-86400' \ --end='-300' \ --pango-markup \ --title='10.10.10.10 / ae4.0 / 10000 / OTHER - 10G' \ --vertical-label='bits por segundo' \ --slope-mode \ --base=1000 \ --height=150 \ --width=700 \ --alt-autoscale \ COMMENT:"From 19-11-2023 08\:44\:44 To 20-11-2023 08\:39\:44\c" \ COMMENT:" \n" \ --color BACK#F3F3F3 \ --color CANVAS#FDFDFD \ --color SHADEA#CBCBCB \ --color SHADEB#999999 \ --color FONT#000000 \ --color AXIS#2C4D43 \ --color ARROW#2C4D43 \ --color FRAME#2C4D43 \ --border 1 \ --font TITLE:9: \ --font AXIS:8: \ --font LEGEND:9: \ --font UNIT:8: \ --font WATERMARK:8: \ --slope-mode \ --watermark 'Por ' \ DEF:a='/usr/share/cacti/rra/10_10_10_10_traffic_in_1355.rrd':'traffic_in':MAX \ DEF:b='/usr/share/cacti/rra/10_10_10_10_traffic_in_1355.rrd':'traffic_in':AVERAGE \ DEF:c='/usr/share/cacti/rra/10_10_10_10_traffic_in_1355.rrd':'traffic_out':MAX \ DEF:d='/usr/share/cacti/rra/10_10_10_10_traffic_in_1355.rrd':'traffic_out':AVERAGE \ CDEF:cdefa='a,8,*' \ CDEF:cdefb='b,8,*' \ CDEF:cdeff='c,8,*' \ CDEF:cdefg='d,8,*' \ LINE1:cdefa#306EFFFF: \ AREA:cdefb#306EFF7F:'Inbound ' \ GPRINT:cdefb:LAST:'Current\:%8.2lf %s' \ GPRINT:cdefb:AVERAGE:'Average\:%8.2lf %s' \ GPRINT:cdefb:MAX:'Maximum\:%8.2lf %s\n' \ LINE1:cdeff#E8A317FF: \ AREA:cdefg#E8A3177F:'Outbound' \ GPRINT:cdefg:LAST:'Current\:%8.2lf %s' \ GPRINT:cdefg:AVERAGE:'Average\:%8.2lf %s' \ GPRINT:cdefg:MAX:'Maximum\:%8.2lf %s\n' \ COMMENT:' \n' \ HRULE:269789501.16#000000FF:'95th Percentile In ->' \ COMMENT:'(269.79 mbit)' \ HRULE:463411527.58#800080FF:'99th Percentile In ->' \ COMMENT:'(463.41 mbit)\n' \ HRULE:269789501.16#E41B17FF:'95th Percentile Out ->' \ COMMENT:'(48.44 mbit)' \ HRULE:53565025.77#C04000FF:'99th Percentile Out ->' \ COMMENT:'(53.57 mbit)\n' RRDtool Command lengths = 1793 characters. RRDtool Says: SVG/XML Output OK
So, are you saying it's working on some aggregates and not others?
So, are you saying it's working on some aggregates and not others?
not only in simple graphs, aggregates do not work
Now I'm confused. Do you have any aggregates that after you resave either the aggregate or aggregate template that are working? Also, what happens when you create a new aggregate graph?
Now I'm confused. Do you have any aggregates that after you resave either the aggregate or aggregate template that are working? Also, what happens when you create a new aggregate graph?
I have an aggregation template that uses the same template as normal graphs, but normal graphs work and aggregates do not use the same template
Template agreggate after change bugged
template normal graph ok
To create the aggregate I use the same graph template which is
ROLLBACK api_aggregate.php and see agregate template for info
Yea, that modified aggregate was a yikes moment. I'll dig in later today.
Yea, that modified aggregate was a yikes moment. I'll dig in later today.
I am very grateful for the help, this has been bothering me a lot because I need the percentiles of the aggregates. Thank you for the support
Can you please screen capture your Aggregate Template. I need the "Aggregate Template Settings" section. Thanks. I'm still finding the Aggregates a little buggy, though I was not able to reproduce your issue.
Can you please screen capture your Aggregate Template. I need the "Aggregate Template Settings" section. Thanks. I'm still finding the Aggregates a little buggy, though I was not able to reproduce your issue.
Here
Here Graph simple too if need
Okay, tested on my side. I have a few updates to commit yet.
Okay, tested on my side. I have a few updates to commit yet.
You can place the IN and OUT separately in the aggregates like in the simple graphs because adding the in and out is wrong
Yea, you 'should' find that fixed in this latest update. Make sure you are pulling from the 1.2.x branch. 3 files this time.
I replaced the 3 files and now no percentile appears anymore
W8 create one new agregate i thing work moment
It didn't work for the old units But I created a new one and it worked, but only in the sense of IN
I think I may know what is happening. The confluence of items is coming from the member graphs, if the member graphs are not the Nth percentile graphs, then the aggregate will not be constructed properly. A bit of an oversight. I'll get to this later tonight if all goes well.
Okay, I just updated lib/api_aggregate.php
. Remember to save your Aggregate Template again.
Okay, I just updated
lib/api_aggregate.php
. Remember to save your Aggregate Template again.
I changed the file and saved the aggregate template but it didn't work. I created another aggregate template to test and when I created an aggregate chart using the template it came in the same way only the IN
Here new graph with new model template
Okay, I have it now... Committing in a few minutes. I did not see this before.
Okay, it should work now. Now that this is fixed, let's talk about what else is essentially broken... Give me more details, but do it in another ticket Okay?
Whoops, forgot to test before committing.
This looks way better now...
I can't access the aggregate option now in the template menu
Grap a fresh copy. I have committed a typo.
The options worked but did not bring the values
Inch by inch ;)
Cross you fingers...
equal to the values of IN it's almost lol
Ugh. I'm seeing a few other issues as well. Still digging in.
Squeaking almost into new feature territory now. Assessing it. Have to check the underlying library.
Grab one more updated. Make sure you save your Aggregate Template again.
I'm going to have to put this code in a vault when done. Lot's of moving parts.
Nothing now
Okay, one more update. This updates: lib/graph_variables.php
and lib/rrd.php
Sorry, there were not logged to this ticket.
Where are the files for me to get?
1.2.x branch.
Crap missed one change. You have to re-save again. Sorry, long day.
I changed the 3 files and still no data and saved the template again
My time on the company's VPN is running out, I'll only be able to test it tomorrow
Okay, yea, it's broken for me too. Moving too fast. Jump back in tomorrow. We still have a few more days till release.
Okay, yea, it's broken for me too. Moving too fast. Jump back in tomorrow. We still have a few more days till release.
Thank you for the great support have a great day tomorrow we are back
I have a graph template that is applied to all graphs and aggregates, however when I create the normal graphs I can see the 95th and 99th ones but in the aggregates I cannot see this data as shown in the screenshots below
Normal graph
Agregate graph
Here model graph for aggregate