Skip to content
New issue

95% graph item has value of 0 #3589

Closed
scamp opened this issue on May 29, 2020 · 15 comments

Comments

@scamp

Describe the bug

Graph with template 'Interface - Traffic (bits/sec, 95th Percentile)' lost the values for 95% after upgrade to cacti 1.2.12

To Reproduce

Steps to reproduce the behavior:

  1. Install Cacti 1.2.10 on freebsd using ports
  2. Create some graphs with template 'Interface - Traffic (bits/sec, 95th Percentile)'
  3. Upgrade to 1.2.12 using ports

Expected behavior

Expected behavior:
Graphs with mentioned template provide information on 95 percentile

Actual behavior:
Graphs have value of 0 for 95%

graph_image

@dmayan-ss

I have 0 value on 95th percentile, on a fresh installation. Could it be related?

@scamp
Author

scamp commented on Jun 1, 2020

I have 0 value on 95th percentile, on a fresh installation. Could it be related?

I believe yes,

@frontierliu
Contributor

frontierliu commented on Jun 3, 2020

Please copy your graph's datasource definition here, it must have MAX or AVG cf for 95th function.

@scamp
Author

scamp commented on Jun 3, 2020

Data Source Debug
/usr/local/bin/rrdtool create
/var/db/cacti/rra/border_traffic_in_549.rrd
--start -900 --step 300
DS:traffic_in:COUNTER:600:0:20000000000
DS:traffic_out:COUNTER:600:0:20000000000
RRA:AVERAGE:0.5:1:600
RRA:AVERAGE:0.5:6:700
RRA:AVERAGE:0.5:24:775
RRA:AVERAGE:0.5:288:797
RRA:MIN:0.5:1:600
RRA:MIN:0.5:6:700
RRA:MIN:0.5:24:775
RRA:MIN:0.5:288:797
RRA:MAX:0.5:1:600
RRA:MAX:0.5:6:700
RRA:MAX:0.5:24:775
RRA:MAX:0.5:288:797
RRA:LAST:0.5:1:600
RRA:LAST:0.5:6:700
RRA:LAST:0.5:24:775
RRA:LAST:0.5:288:797 \

@netniV
Contributor

netniV commented on Jun 3, 2020

That's the data source itself, you should probably also include the graph debug which shows the graph creation command line.

@TheWitness
Member

TheWitness commented on Jun 3, 2020

Dude,

--start -900

That's only 15 minutes. 95th percentile requires at least 100 samples. Until you get that many, or close to it, it will report 0.

@dmayan-ss

Here is mine, I think that I have more than 100 samples? It's a full day sampled every 1 minute.

RRDtool Command:
/usr/bin/rrdtool graph - \
--imgformat=PNG \
--start='1591066800' \
--end='1591153140' \
--pango-markup  \
--title='BGP - Traffic - TASA - ARISTA ' \
--vertical-label='bits per second' \
--slope-mode \
--base=1000 \
--height=200 \
--width=700 \
--rigid \
--alt-autoscale-max \
--lower-limit='0' \
COMMENT:"From 02-06-2020 00\:00\:00 To 02-06-2020 23\:59\:00\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:11:'Arial' \
--font AXIS:8:'Arial' \
--font LEGEND:8:'Courier' \
--font UNIT:8:'Arial' \
--font WATERMARK:6:'Arial' \
--slope-mode \
--watermark 'Cacti® SSServicios' \
DEF:a='/var/www/html/rra/bgp_traffic_in_16.rrd':'traffic_in':AVERAGE \
DEF:b='/var/www/html/rra/bgp_traffic_in_16.rrd':'traffic_out':AVERAGE \
CDEF:cdefa='a,8,*' \
CDEF:cdefe='b,8,*' \
AREA:cdefa#00CF007F:'Inbound '  \
GPRINT:cdefa:LAST:'Current\:%8.2lf %s'  \
GPRINT:cdefa:AVERAGE:'Average\:%8.2lf %s'  \
GPRINT:cdefa:MAX:'Maximum\:%8.2lf %s\n'  \
AREA:cdefe#002A977F:'Outbound'  \
GPRINT:cdefe:LAST:'Current\:%8.2lf %s'  \
GPRINT:cdefe:AVERAGE:'Average\:%8.2lf %s'  \
GPRINT:cdefe:MAX:'Maximum\:%8.2lf %s\n'  \
HRULE:0#C04000FF: \
COMMENT:'95th in  0' 
RRDtool Command lengths = 1267 charaters.
RRDtool Says:
OK

Thanks

@netniV
Contributor

netniV commented on Jun 4, 2020

Do you have your data source info?

@hitalos

Same problem here.

@frontierliu
Contributor

frontierliu commented on Jun 4, 2020

I think the 95th function bug have been fixed in github branch 1.2.x ,but not applied to 1.2.12 yet. you can try to fix it manually:

  1. Download the newest lib/graph_variables.php from github/cacti branch1.2.x.
  2. Overwrite your cacti/lib/graph_variables.php
  3. Refresh the browser and check the 95th graph.
@hitalos

I think the 95th function bug have been fixed in github branch 1.2.x ,but not applied to 1.2.12 yet. you can try to fix it manually:

  1. Download the newest lib/graph_variables.php from github/cacti branch1.2.x.
  2. Overwrite your cacti/lib/graph_variables.php
  3. Refresh the browser and check the 95th graph.

This solved to me!

@dmayan-ss

Solved for me!!

THANKS!

@frontierliu
Contributor

frontierliu commented on Jun 4, 2020

I belive that this bug is related to issue #3527 , which will be resolved in cacti version 1.2.13.

@scamp
Author

scamp commented on Jun 4, 2020

Solved for me as well.
Thanks for clarifications, I expected the fix to be in 1.2.12.

@scamp scamp closed this on Jun 4, 2020
@eakkaphon

I think the 95th function bug have been fixed in github branch 1.2.x ,but not applied to 1.2.12 yet. you can try to fix it manually:

  1. Download the newest lib/graph_variables.php from github/cacti branch1.2.x.
  2. Overwrite your cacti/lib/graph_variables.php
  3. Refresh the browser and check the 95th graph.

thankU very much

@github-actions github-actions bot locked and limited conversation to collaborators on Sep 23, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
7 participants