You need to find some OID which always returns the value 0. 

Then construct your target line like this (OID1 and OID2 are the things
you want to track. OID0 is the "dummy"):

Target[xyz]: OID1&OID0:[EMAIL PROTECTED] + ( OID0&OID2:[EMAIL PROTECTED] / 1024
)

Mind the spacing. Math operators need to be surrounded by white space.

Jerry



-----Original Message-----
From: Garth Williams [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, July 30, 2003 11:11 AM
To: [EMAIL PROTECTED]
Subject: [mrtg] OID calculation


Hi folx!
I have a situation I wonder if someone could help me with

Given the following:
Target[xyz]: OID1&OID2:[EMAIL PROTECTED]

An SNMP GET on OID1 gives me a value like so: 3463168
An SNMP GET on OID2 gives me a value like so: 2123456789

Anyone got any ideas how I can scale down OID2 so that the values would
be in the same scal (to something like 2073688 ish) so that they will be
close

I have tried ...

Target[xyz]: OID1:[EMAIL PROTECTED]&OID2:[EMAIL PROTECTED] /1024

...which I thought would divide OID2 by 1024, but "no worky pas".

Is it because the result (2073688.2705078125) has a decimal remainder
value?

Help (as always) appreciated!

Garth



--
Unsubscribe mailto:[EMAIL PROTECTED]
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


Confidentiality Notice: This e-mail message, including any attachments,
is for the sole use of the intended recipient(s) and may contain
confidential and privileged information.  Any unauthorized review, use,
disclosure or distribution is prohibited.  If you are not the intended
recipient, please contact the sender by reply e-mail and destroy all
copies of the original message.

--
Unsubscribe mailto:[EMAIL PROTECTED]
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

Reply via email to