RRD Graph downward to 0 date prediction

Alexander von Gluck IV <[email protected]>
Newsgroups gmane.comp.db.rrdtool.user
Message-ID <[email protected]>
Good morning,

I'm working through doing a low-disk space prediction (based on slope)
I see a lot of examples floating around of doing a 90% and 100% 
prediction, however nothing for 0 prediction.

I'm extremely close to the final prediction and have a nice slope 
line... however I just can't seem to get the
prediction date to work:

#{c} is a string such as "storage01"
#.. is a commented out line (this is all ruby)

The final "GPRINT:#{c}warning:    2TB free @ %c\\l:strftime" is the 
final prediction
that isn't functioning. (I just get a "-")

     # A nice 500GB / 2TB limit red
     options.push("LINE1:0")
     options.push("AREA:500000000000#FF000044::STACK")
     options.push("AREA:2000000000000#FF000022::STACK")
     index = 0
     counters.each do |c|
          options.push("--end", "now+#{range}", "--start", 
"now-#{range}")
          options.push("--vertical-label", "Space Available")
          options.push("DEF:#{c}=#{rrdfile}:#{c}:MIN")
          options.push("VDEF:#{c}slope=#{c},LSLSLOPE")
          options.push("VDEF:#{c}int=#{c},LSLINT")
          
options.push("CDEF:#{c}avg=#{c},POP,#{c}slope,COUNT,*,#{c}int,+")
          options.push("CDEF:#{c}limit=#{c}avg,2000000000000,0,LIMIT")
          options.push("VDEF:#{c}warning=#{c}limit,FIRST")
          options.push("LINE2:#{c}#{get_color(index)}cc:#{c}")
          options.push("LINE1:#{c}avg#{get_color(index)}cc::dashes=2");
          options.push("GPRINT:#{c}:LAST:Available\\: %7.2lf %s\\l")
          #options.push("GPRINT:#{metric}:MIN:Min Available\\: %7.2lf 
%s")
          #options.push("GPRINT:#{metric}:MAX:Max Available\\: %7.2lf 
%s\\l")
          options.push("GPRINT:#{c}warning:    2TB free @ 
%c\\l:strftime")
          index += 1
     end
     options.push("--title", "#{(object[:name] or object[:hostname])} - 
Disksafe Storage Trending / Last #{range}")
     #options.push("--lower-limit", "0", "--upper-limit", 
"25000000000000")


Thoughts? Trying to predict when 2TB is going to be all that is 
remaining. All data is in bytes.


  -- Alex
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.