[SNMP4J] How to get units of a variable from an SNMP stream?

Frank Fock fock at agentpp.com
Mon May 26 09:56:06 CEST 2014


Hi,

You could purchase SNMP4J-SMI-PRO to get detailed MIB information at runtime
for the OIDs you are processing. Including the UNITS.
The MIB information is not sent over the wire, thus it has been loaded 
at sender
side separately - if needed.

Best regards,
Frank

Am 26.05.2014 05:36, schrieb Sajini De Silva:
> Hi,
>
> I'm new to snmp4j. I used the sample code in [1] to extract some
> meaningful information from a SNMP stream.
>
> In the sample code, oid and value of the variable is extracted, but
> the value comes without its units. For example
>
> ,oid 1.3.6.1.4.1.2021.4.6.0 (SNMP-MIB::memAvailReal.0) gives the value
> 13385068 without its unit KB. Is there a way to get the value with its
> units in snmp4j?
>
> Can somebody please look in to this?
>
> [1]https://gist.github.com/akirad/5597203
>
>
>

-- 
---
AGENT++
Maximilian-Kolbe-Str. 10
73257 Koengen, Germany
https://agentpp.com
Phone: +49 7024 8688230
Fax:   +49 7024 8688231




More information about the SNMP4J mailing list