I would like to graph data that can take these 6 discrete values:
16, 64, 256, 1024, 4096, 16384
Unfortunately, the logarithmic scale of rrdtool is base 10, not base 2, so that scaling is not quite correct. I am also unable to get a sensible y-axis grid numbers this way (either SI-units or exponential, both is ugly).
If I compute the logarithm with base 2 from the values as cdef, I get the values 4, 6, 8, 10, 12, 14, which are nice to graph. This is how the graph should look like.
But I cannot get the y-axis description to 16, 64, 256 etc. Only to 4, 6, 8, etc.
Does anybody has a hint what I can do to graph the values as 4, 6, 8... but show 16, 64, 256... on the y-axis? Is there a feature in rrdtool that enables me to compute y-axis numbers instead of just formatting?
Graphing powers of 2 with logarithmic scale
Moderators: Developers, Moderators
Re: Graphing powers of 2 with logarithmic scale
No surprise nobody has a solution for it. Seems I'm asking things from rrdtool it doesn't contain.
My solution is to show the y-axis as bits and not as actual value. To get the bits as log2(value), I created a cdef with this definition: cdef=CURRENT_DATA_SOURCE,LOG,2,LOG,/
This is the resulting graph:
My solution is to show the y-axis as bits and not as actual value. To get the bits as log2(value), I created a cdef with this definition: cdef=CURRENT_DATA_SOURCE,LOG,2,LOG,/
This is the resulting graph:
Re: Graphing powers of 2 with logarithmic scale
Sounds like you've made some progress though, that's good to know!
Cacti Developer & Release Manager
The Cacti Group
Director
BV IT Solutions Ltd
+--------------------------------------------------------------------------+
Cacti Resources:
Cacti Website (including releases)
Cacti Issues
Cacti Development Releases
Cacti Development Documentation
The Cacti Group
Director
BV IT Solutions Ltd
+--------------------------------------------------------------------------+
Cacti Resources:
Cacti Website (including releases)
Cacti Issues
Cacti Development Releases
Cacti Development Documentation
Re: Graphing powers of 2 with logarithmic scale
It's a very boring graph, actually. On my connection, it sticks to 64 all day, and if the line has some noise, it goes down to 16 for short amount of time, then back to 64. The corresponding downstream graph is even more boring: it sticks to 256 all day, and if it's not 256, it is empty and the line is disconnected.
Who is online
Users browsing this forum: No registered users and 1 guest