[rrd-users] Re: problems summing many sources together

2006-06-10 Thread Georges Toth
 Granted, 0 is as good as any other number (including 3).  Propose it.
 Be prepared for Tobi to say patches are welcome :)

:-)...I'm currently too busy with other things


 If such an option would be there, hard wired zero would not be
 good enough imho.

 If your goal is to meter bandwidth used, 0 is the better option.
 If your goal is to compute bandwidth available, the maximum rate
 is probably better...

I get your point.
So the solution would be a configurable default setting for UNKNOWN.
If you don't set it, it will be the usual UNKNOWN, and it can be set to a 
variable or some numeric data.

Guess that would be a really nice feature...


-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: problems summing many sources together

2006-06-09 Thread Georges Toth
 This seems alot cleaner to me than doing all the CDEFs.  This will not
 work, of course, if you don't use routers2.cgi for your graph
 creation.

I'm using rrdtool with some custom scripts, so that is not a option for me.
But thanks for your help

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: problems summing many sources together

2006-06-09 Thread Georges Toth
  (...)
 This creates 44 extra arrays containing ranges.
 
  CDEF:intot=in1,UN,0,in1,IF,in1,UN,0,in1,IF,in2,UN,0,in2,IF,in3,UN,0,in3,I
 F,in4,UN,0,in4,IF,in5,UN,0,in5,IF,in6,UN,0,in6,IF,in7,UN,0,in7,IF,in8,UN,0
 ,in8,IF,in9,UN,0,in9,IF,in10,UN,0,in10,IF,in11,UN,0,in11,IF,in12,UN,0,in12
  ()
 This creates two extra arrays containing ranges.

Ah right, ok


 If your system is low on memory and will have to use swap space, I bet
 the first mentioned way will be much slower.
 On the other hand, if you hit a limit in your operating system, where
 lines become too long, you may have to do your adding in at least a
 couple of steps.

The system I'm doing the graphing on has surely enough ram to handle those 44 
arrays and more.
I guess I would rather hit the maximum line-length limit.


  Also, is there no more efficient solution for doing this ?

 How much is 1 plus 2 plus unknown plus 4 plus 5 ?

 There is only one answer: unknown.

Right. I just assumed that rrd would automatically translate unknown to 0 in 
this case.
Or that there was a global option to tell it so...


Anyway, thanks for your help and clear explanations !


-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] problems summing many sources together

2006-06-07 Thread Georges Toth
Hi all,

I need to sum 21 sources.
What's the best way to do that ?

I tried it like this:
CDEF:intot=in1,in2,in3,+,in4,+,in5,+,in6,+,in7,+,in8,+,in9,+,in10,+,in11,
+,in12,+,in13,+,in14,+,in15,+,in16,+,in17,+,in18,+,in19,+,in20,+,in21,+ 

Which looks fine if all the soruces contain data.
But if some sources don't contain data, I just get NAN.

I also tried this:
CDEF:intot=in1,in2,in3,in4,in5,in6,in7,in8,in9,in10,in11,in12,in13,in14,in15,in16,in17,in18,in19,in20,in21,
+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+

Which doesn't work neither.
I'm not sure if that is the correct way to do it

Could somebody please help me ? :-)


-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: problems summing many sources together

2006-06-07 Thread Georges Toth
 you need to add an IF directive there which returns data or zero if 
undefined:
 | CDEF:mycdef=mydef,UN,0,mydef,IF

Thanks a lot !
That did the trick :-).

I tried two different approaches.
First one is to define 21 times this:
CDEF:in_1=in1,UN,0,in1,IF
CDEF:out_1=out1,UN,0,out1,IF
and then sum it like this:
CDEF:intot=in_1,in_2,+,in_3,+,in_4,+,in_5,+,in_6,+,in_7,+,in_8,+,in_9,
+,in_10,+,in_11,+,in_12,+,in_13,+,in_14,+,in_15,+,in_16,+,in_17,+,in_18,
+,in_19,+,in_20,+,in_21,+ 
CDEF:outtot=out_1,out_2,+,out_3,+,out_4,+,out_5,+,out_6,+,out_7,+,out_8,
+,out_9,+,out_10,+,out_11,+,out_12,+,out_13,+,out_14,+,out_15,+,out_16,
+,out_17,+,out_18,+,out_19,+,out_20,+,out_21,+


Second one was like you suggested (but I only read that when I already tried 
the first one...):

CDEF:intot=in1,UN,0,in1,IF,in1,UN,0,in1,IF,in2,UN,0,in2,IF,in3,UN,0,in3,IF,in4,UN,0,in4,IF,in5,UN,0,in5,IF,in6,UN,0,in6,IF,in7,UN,0,in7,IF,in8,UN,0,in8,IF,in9,UN,0,in9,IF,in10,UN,0,in10,IF,in11,UN,0,in11,IF,in12,UN,0,in12,IF,in13,UN,0,in13,IF,in14,UN,0,in14,IF,in15,UN,0,in15,IF,in16,UN,0,in16,IF,in17,UN,0,in17,IF,in18,UN,0,in18,IF,in19,UN,0,in19,IF,in20,UN,0,in20,IF,in21,UN,0,in21,IF,
+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+
CDEF:outtot=out1,UN,0,out1,IF,out2,UN,0,out2,IF,out3,UN,0,out3,IF,out4,UN,0,out4,IF,out5,UN,0,out5,IF,out6,UN,0,out6,IF,out7,UN,0,out7,IF,out8,UN,0,out8,IF,out9,UN,0,out9,IF,out10,UN,0,out10,IF,out11,UN,0,out11,IF,out12,UN,0,out12,IF,out13,UN,0,out13,IF,out14,UN,0,out14,IF,out15,UN,0,out15,IF,out16,UN,0,out16,IF,out17,UN,0,out17,IF,out18,UN,0,out18,IF,out19,UN,0,out19,IF,out20,UN,0,out20,IF,out21,UN,0,out21,IF,
+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+,+


I'm wondering which one is better / faster ?

Also, is there no more efficient solution for doing this ?


Thnx

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: How can I use RRDTool with PHP?

2006-06-05 Thread Georges Toth
 It can work, but always return the image's width and heigth.
 How can I discard it?

execute that command (with system or exec or whatever)
- it only prints an error or the widthxheightit doesn't output the actual 
image

use an html img tag to load the image

or

open the image in php (fopen), read it and print it (obviously you have to 
call the php script within an img tag from a html page)


hope that helps

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: help needed here !!!!1

2006-06-05 Thread Georges Toth
 2.I wanted to read the data from RRDTOOL into php web pages. Please suggest
 me some ways to go ahead. I am helpless now regaring creating web pages
 with the data from RRDs.
 Thanks in advance.

One method I've used is to execute the command for generating the graph in 
php.
And then opening the image (fopen) and printing it.

When you call the php script from within an html-img tag, the graph gets 
displayed as expected :-)


-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] remove peaks

2005-08-17 Thread Georges Toth
Hi,

I got a problem with my rrd's.
They get updated every 5min, with a specific value.
That value gets incremented til the end of the month, and then gets reset.
The data is a traffic counter.

So far so good.
The problem now is that I get unusual high peaks when that reset occurs.

If I only had one rrd, I could easily filter those peaks (with setting those 
peaks to UNKN).
But as I got many rrd's, where the data, and as such those high peaks, are 
very different from each other, I have no clue how I possibly could filter 
peaks from all of my rrd's.

Another problem is that if I got nearly no traffic, the peak is at a value 
which might be reasonable. So if I filter the peak, and such traffic suddenly 
occurs, I filter the traffic as well.


I doubt there is a solution for one of either problems.
But I thought I'd ask anyway :-)

Thnx for any comments


-- 
regards,

Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: remove peaks

2005-08-17 Thread Georges Toth
Hi Tobias,

 use DS type DERIVE and set the minimal value to 0 then you will get
 one unknown value after a reset.

I will try that, thanks a lot!
But, is it possible to change my current rrd's, without editing them by hand ?
Because I would rather not want to loose 1 year worth of data :-/.


 Today Georges Toth wrote:
  Hi,
 
  I got a problem with my rrd's.
  They get updated every 5min, with a specific value.
  That value gets incremented til the end of the month, and then gets
  reset. The data is a traffic counter.
 
  So far so good.
  The problem now is that I get unusual high peaks when that reset occurs.
 
  If I only had one rrd, I could easily filter those peaks (with setting
  those peaks to UNKN).
  But as I got many rrd's, where the data, and as such those high peaks,
  are very different from each other, I have no clue how I possibly could
  filter peaks from all of my rrd's.
 
  Another problem is that if I got nearly no traffic, the peak is at a
  value which might be reasonable. So if I filter the peak, and such
  traffic suddenly occurs, I filter the traffic as well.
 
 
  I doubt there is a solution for one of either problems.
  But I thought I'd ask anyway :-)
 
  Thnx for any comments

-- 
regards,

Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: remove peaks

2005-08-17 Thread Georges Toth
  I will try that, thanks a lot!
  But, is it possible to change my current rrd's, without editing them by
  hand ? Because I would rather not want to loose 1 year worth of data :-/.
 sure ... try rrdtool tune

That worked.
But I still got those peaks.
I tried to dump the file and restore it, but that didn't help either.

Any idea ?

-- 
regards,

Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: remove peaks

2005-08-17 Thread Georges Toth
Hi Tobias,

 you mean the pre-existing peaks ? 

Yes


 well these you can only remove by 
 setting a max value for the relevant datasource and then dumping
 and restoring with the -r option ... the change I told you works
 only for new samples

I guessed so... :-/
I wrote a small script for automating the changemax-dump-restore-restoremax 
(to 0)  But I can only use it with rrd's where the data is +/- the same 
all the time.
Else I loose correct informations...
f.ex. when the wrong-peaks are at 50k, and there are sometimes real peaks of 
60k.


Anyway, thanks a lot for your quick help!

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://lists.ee.ethz.ch/rrd-users
WebAdminhttp://lists.ee.ethz.ch/lsg2.cgi


[rrd-users] Re: Calculate total over a give period of time

2005-02-24 Thread Georges Toth
 some old scripting what I did. http://haas.oezie.org/overzicht.html
 http://haas.oezie.org/overzicht.pl it is al perl script. later I made
 some adjustments to make some nice plots like gbgraph.
 http://haas.oezie.org/cgi-bin/traffic.pl?jaar=2005 or
 http://haas.oezie.org/cgi-bin/traffic.pl?jaar=2005maand=2 the source is
 at the bottom of the page.

thanks for your quick reply!

so basically what i need to do is this:
CDEF:totin=in,X,*,$i,*
CDEF:totout=out,X,*,$i,*
CDEF:tot=totin,totout,+

where X is the timeframe i'm graphing?

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://www.ee.ethz.ch/~slist/rrd-users
WebAdminhttp://www.ee.ethz.ch/~slist/lsg2.cgi


[rrd-users] Re: rrdtool create

2004-12-09 Thread Georges Toth
 No, it's not.
 
 This happened in 300 seconds, so thats about 61,500,000,000,000,000
 per second.  You programmed your RRA to behave like this.

thnx for the explanation


 Would you have set a sane maximum rate, as instructed by the documentation,
 this rate would have been ignored and you'd have ended up with unknown
 data.  Since you really don't know the rate before and after the reset,
 that's not unreasonable.

hmm i understand.
the problem is i don't know the maximum.
but i guess i could set one which is far too high but still below what rrdtool 
calculated :-)


 Only if you're willing to ignore This way you have the most accurate
 results.

what is so different from counter and derive then ?


 rrdtool tune can be used to alter the data source type and to change
 the minimum allowed rate.

i tried rrdtool tune to change the dst to derive. a minimum was already set.
if i graph a month view, i only see the end of the month, with those far too 
high numbers.
so i guess the changed dst will only make a difference by the next end of the 
month, when those too high values won't be added to the db but instead, 
unknown. is that right?

if so, is it possible to change those some values around last endofmonth, to 
unknown ?

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://www.ee.ethz.ch/~slist/rrd-users
WebAdminhttp://www.ee.ethz.ch/~slist/lsg2.cgi


[rrd-users] Re: rrdtool create

2004-12-09 Thread Georges Toth
 If you use the DERIVE_with_minimum_rate_zero method, you are telling
 RRDtool to ignore the updates around the reset. This results in a loss
 of information (a couple of updates will result in unknown data).

i see


 If you use the tripple_update method, you are telling RRDtool what the
 rate was just before the reset, and when the reset happened.  This way,
 RRDtool has no unknown data hence it has more reliable data.  You will
 still loose some information, but this loss is limited as it is only
 the amount of data between the last update and the reset.  This is one
 second, if you follow my suggestion.

i understand that that is the best mehod. but it is not so elegant to 
implement.
i mean i would have to make some more cronjobs, and only for the end of the 
months.
hmm

 I think you are looking at data that's already in the RRD.  Changing
 the DS_type will only influence data that is collected after this change.

oh ok :-)
well i was looking at already existing data..


 Option 1:
  - dump the database (rrdtool dump)
  - edit the xml file
  - restore the database (rrdtool restore)
 This modifies the available data.

i tried that, but somehow it didn't work as expected.
anyway, i can't do that because i have around 300 rrds :-).


 Option 2:
  - read the tutorial
  - implement the pretend weird data isn't there workaround
 This modifies the representation of the available data.

that did it!
awesome, my graphs look just as i expect them to look like :-).
thank you very much for your help Alex!!!

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://www.ee.ethz.ch/~slist/rrd-users
WebAdminhttp://www.ee.ethz.ch/~slist/lsg2.cgi


[rrd-users] rrdtool create

2004-12-08 Thread Georges Toth
Hi All,

i'm monitoring a traffic counter, which gets reset by the end of the month (so 
not at the 32 or 64bit boundary).
what datasource type should i use for that?

i tried counter, but when the month is over, the graph looks very strange if i 
graph some hours before and after the reset, in one graph.

can somebody help me plz?

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://www.ee.ethz.ch/~slist/rrd-users
WebAdminhttp://www.ee.ethz.ch/~slist/lsg2.cgi


[rrd-users] Re: rrdtool create

2004-12-08 Thread Georges Toth
 Counter, or derive.

i would prefer not to recreate everything :-)
but as i read the rest of the mail, i would better doing so.
is it possible to keep the current data but somehow change from counter to 
derive ?
like dump and restore ?


 You didn't set a proper maximum, or your counter increases to _almost_ the
 full value in one month.

i didn't set a maximum, that's correct.
the data it plotted... some hours before and some hours after... it contained 
some PETA values etc...
very strange


 #1 Just before the counter gets reset, update your database. One
second later, update the database with U (for unknown).
Another second later (preferably exactly when the counter is reset)
update the database with zero.
This way you have the most accurate results

hmmm...


 #2 Use DERIVE as your datasource type.  When the counter is reset, RRDtool
will see this as a negative rate.  Tell RRDtool it should not accept
negative rates (minimum value set to zero)

that's probably the best way to go...
only wondering now if i can keep my old data... hope so :-/ ... ?

-- 

regards,
Georges Toth

--
Unsubscribe mailto:[EMAIL PROTECTED]
Helpmailto:[EMAIL PROTECTED]
Archive http://www.ee.ethz.ch/~slist/rrd-users
WebAdminhttp://www.ee.ethz.ch/~slist/lsg2.cgi