[rrd-users] [GRAYMAIL] RE: Question about trend line

rseiwert rob at vcaglobal.com
Wed Aug 12 18:46:09 CEST 2015


I'm sure you have other limits on rrdgraph probably set on the command line options that limits the graph range.
Just looking at your graph I can see that the trend would be less than zero at the beginning of the graph just by following the line shown.
You can verify this by printing out the SLOPE and INT. I would wager you will find INT (the starting y position on the graph) will be negative.
PRINT:slope:'%lf'
PRINT:int:'%lf'

And now another completely different point. You seem to be trying to predict disk usage. I have worked out a few tricks in this regard

You need to realize when you open your graph up you change your step size which will effect the trend data. The step size will be set to the time that fits into one pixel. I have found thru trial and error that changing your step size will change the trend result.You can see your actual step size using the following

CDEF:c=dt_month,COUNT,EXC,POP
CDEF:t= dt_month,TIME,EXC,POP
VDEF:tmin=t,MINIMUM
VDEF:tmax=t,MAXIMUM
VDEF:cmax=c,MAXIMUM
CDEF:s=used2,POP,tmax,tmin,-,cmax,1,-,/
PRINT:s:MAX

S will be a range, there might be a better way to solve this but this is what I worked out, and value of S will be the step size in seconds. I actually use this technique to produce trend values and step size to solve to trend when we will run out of disk space. This solves the problem of opening up the graph see the point where you run out of disk space. It also solves the problem if having to look at a graph to see what I call the danger zone and gives you something that can actually trigger a warning. Example of Predict Disk script output is:
Reach 100% on Mon Oct 26 06:17:00 EDT 2015 Slope 110.40M per 60 seconds Correlation Coefficient 0.68
Data Analyzed Starting Mon Aug 10 12:24:00 EDT 2015 - Ending Wed Aug 12 12:24:00 EDT 2015

[http://nagios.vcaglobal.com/nagiosxi/includes/components/perfdata/graphApi.php?host=iSCSIgroup&service=Disk_Usage&source=2&view=2&start=&end=&rand=1439396239]<http://nagios.vcaglobal.com/nagiosxi/perfgraphs/?&host=iSCSIgroup&service=Disk%20Usage&source=2&view=2&start=&end=&startdate=&enddate=&mode=2&service_id=1351>
[http://nagios.vcaglobal.com/nagiosxi/includes/components/perfdata/graphApi.php?host=iSCSIgroup&service=Predict_Disk&source=1&view=2&start=&end=&rand=1439396950]<http://nagios.vcaglobal.com/nagiosxi/perfgraphs/?&host=iSCSIgroup&service=Predict%20Disk&source=1&view=2&start=&end=&startdate=&enddate=&mode=2&service_id=2702>
[http://nagios.vcaglobal.com/nagiosxi/includes/components/perfdata/graphApi.php?host=iSCSIgroup&service=Disk_Usage&source=1&view=1&start=&end=&rand=1439397117]<http://nagios.vcaglobal.com/nagiosxi/perfgraphs/?&host=iSCSIgroup&service=Disk%20Usage&source=1&view=1&start=&end=&startdate=&enddate=&mode=2&service_id=1351>

That final graph is a bit off because last Friday I added a new disk array into a pool and then removed an old disk array from the pool to the overall space changed in this time period.
Other insights into predicting disk usage can been seen in the link below. It is Nagios specific but the shell script to predict disk overflow is generic and could be used with any system
https://www.youtube.com/watch?v=7TdVTfp3cAs


From: Ondrej [via RRD Mailinglists] [mailto:ml-node+s937164n7583079h0 at n2.nabble.com]
Sent: Wednesday, August 12, 2015 11:46 AM
To: Robert C. Seiwert <rob at vcaglobal.com>
Subject: [GRAYMAIL] RE: Question about trend line

Hello,

thanks for reply. i tried your modification >> CDEF:trend=dt_month,POP,COUNT,slope,*,int,+

however this has no effect. Also in first two days, the value was 70Mibts (each day had 35Mbytes) so there were non zero value in the graph since beginning. The thing is that it is not so well visible as scale not adequate here in the graph.
________________________________
If you reply to this email, your message will be added to the discussion below:
http://rrd-mailinglists.937164.n2.nabble.com/Question-about-trend-line-tp7583077p7583079.html
To start a new topic under RRDtool Users Mailinglist, email ml-node+s937164n937053h94 at n2.nabble.com<mailto:ml-node+s937164n937053h94 at n2.nabble.com>
To unsubscribe from RRD Mailinglists, click here<http://rrd-mailinglists.937164.n2.nabble.com/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=937164&code=cm9iQHZjYWdsb2JhbC5jb218OTM3MTY0fC0yMTE0MzU4MzIz>.
NAML<http://rrd-mailinglists.937164.n2.nabble.com/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>


image001.png (30K) <http://rrd-mailinglists.937164.n2.nabble.com/attachment/7583082/0/image001.png>
image002.png (28K) <http://rrd-mailinglists.937164.n2.nabble.com/attachment/7583082/1/image002.png>
image003.png (46K) <http://rrd-mailinglists.937164.n2.nabble.com/attachment/7583082/2/image003.png>




--
View this message in context: http://rrd-mailinglists.937164.n2.nabble.com/Question-about-trend-line-tp7583077p7583082.html
Sent from the RRDtool Users Mailinglist mailing list archive at Nabble.com.



More information about the rrd-users mailing list