[mrtg] how to add one GE traffic to another GE?

王 丽 wangli_7805 at hotmail.com
Fri May 12 08:34:14 MEST 2006


hello,everyone!

     This is my first time of using this mail-lists,and my English is 
poor,so please help me and thanks very much!

     I use mrtg to monitor the traffic of a GE for a long time,it works 
very good.
     (config :Target[GigabitEthernet0_2]: 
\GigabitEthernet0/2:public at A.B.C.D:::::2)

     Yesterday, I planned to add the traffic of GE0/2 to GE0/1,then I 
found it didn't work.
(config :Target[GigabitEthernet0_1_and_0_2]: 
\GigabitEthernet0/1:public at A.B.C.D:::::2 + 
\GigabitEthernet0/2:public at A.B.C.D:::::2)

    I read the mrtg preference doc,it says:"
    Multi Target Syntax
    You can also combine several target definitions in a mathematical 
expression. Any syntactically correct expression that the Perl interpreter 
can evaluate to will work. An expression could be used, for example, to 
aggregate both B channels in an ISDN connection or to calculate the 
percentage hard disk utilization of a server from the absolute used space 
and total capacity. 
Examples:
 Target[ezwf]: 2:public at wellfleetA + 1:public at wellfleetA
 Target[ezwf]: 1.3.6.1.4.1.999.1&1.3.6.1.4.1.999.2:public at mydevice /
     1.3.6.1.4.1.999.3&1.3.6.1.4.1.999.4:public at mydevice * 100
Note that whitespace must surround each target definition in the 
expression. Target definitions themselves must not contain whitespace, 
except in interface descriptions and interface names, where each whitespace 
character is escaped by a backslash.
MRTG automatically rounds the result of the expression to an integer unless 
RRDTool logging is in use and the gauge option is in effect for the target. 
Internally MRTG uses Perl's Math::BigFloat package to calculate the result 
of the expression with 40 digits of precision. Even in extreme cases, 
where, for example, you take the difference of two 64-bit integers, the 
result of the expression should be accurate.  "


    So I think,maybe,because " MRTG uses Perl's Math::BigFloat package to 
calculate the result of the expression with 40 digits of precision",but 
SNMPv2 use 64-bit counters,so I can't get the accurate result. 

    Now how can I resovle this problem? thanks very much !



        wangli_7805
        2006-05-12

_________________________________________________________________
免费下载 MSN Explorer:   http://explorer.msn.com/lccn/  

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



More information about the mrtg mailing list