[mrtg] Re: Total Traffic per Switch

Alex van den Bogaerdt alex at slot.hollandcasino.nl
Wed Feb 21 15:27:19 MET 2001


Thierry Silly wrote:
> 
> 
> 2- I'm using RRDtool too for other things. In fact, on the other hand of\
> my mrtg stats, I use rrdtool to generate a database,
>      with all my ports traffic and to only graph the datas when I need t\
> o monitor 1 port. (just a little new
>      challenge for me, I know some tools are doing that).
>      my problem is that I don't know if I can create a rrd file with abo\
> ut 300 DS in it. Does someone know  if it is possible ?
>      How can I create such a rrd file  in another way than typing 300 ti\
> me DS:...:...:...:...: ?

In general you shouldn't create a database with that many DSes (but
it can be done).  If you add more interfaces, you would like to add
new DSes to the RRD and this can't be done (yet).  Even if it could
be done, it would result in a huge file.

Best is to have an RRD per interface.  These RRDs will have two DSes.
MRTG can create these databases for you ("logformat rrd" or something
similar to that, see the docs).  When doing so, you also need to use
14all.cgi to view your stats.

If you want to add up traffic for all of your interfaces, you can create
a script that creates a graph.  Use "rrdtool graph" for this.
   DEF:if1ds0=if1.rrd:ds0:AVERAGE
   DEF:if1ds1=if1.rrd:ds1:AVERAGE
   DEF:if2ds0=if2.rrd:ds0:AVERAGE
   DEF:if2ds1=if2.rrd:ds1:AVERAGE
ectetera.
   CDEF:module1ds0=if1ds0,if2ds0,if3ds0,+,+,+
   CDEF:module1ds1=if1ds1,if2ds1,if3ds1,+,+,+
etcetera.
   CDEF:switch1ds0=module1ds0,module2ds0,+,+
   CDEF:switch1ds1=module1ds1,module2ds1,+,+
etcetera.
   CDEF:totaltraffic=switch1ds0,switch1ds1,+
   AREA:switch1ds0#00C000:"Total switch traffic"

You can build this script using another script, using all rrd files.
And yes, you can create a single graph from data in several RRDs.

cheers,
-- 
   __________________________________________________________________
 / alex at slot.hollandcasino.nl                  alex at ergens.op.het.net \
| work                                                         private |
| My employer is capable of speaking therefore I speak only for myself |
+----------------------------------------------------------------------+
| Technical questions sent directly to me will be nuked. Use the list. | 
+----------------------------------------------------------------------+
| http://faq.mrtg.org/                                                 |
| http://rrdtool.eu.org  --> tutorial                                  |
+----------------------------------------------------------------------+

--
Unsubscribe mailto:mrtg-request at list.ee.ethz.ch?subject=unsubscribe
Archive     http://www.ee.ethz.ch/~slist/mrtg
FAQ         http://faq.mrtg.org    Homepage     http://www.mrtg.org
WebAdmin    http://www.ee.ethz.ch/~slist/lsg2.cgi



More information about the mrtg mailing list