|
The snmpget_by_index is an example of an SNMP GET application for an object where the index values can be specified more easily. This example application gets an SNMP table column instance by specifying the column name and values of one or more indices.
Source
Refer the source code for the snmp_get_by_index example present in <examples/applications/snmp_get_by_index.java> for more information.
Usage
The usage of the snmpget_by_index is provided below. The "-d" option enables the debug and prints the packet dumps. The "host" "OID" and the "Index" arguments are mandatory and the rest are optional.
java snmpget_by_index [-v version(v1,v2,v3)] [-m MIB_files] [-c community] [-p port] [-t timeout] [-r retries] [-u user] [-a auth_protocol] [-w auth_password] [-pp privProtocol(DES/AES-128/AES-192/AES-256/3DES)] [-s priv_password] [-n contextName] [-i contextID] [-d debug] host OID index [index] ...
Example Command
java snmpget_by_index -m "../../mibs/RFC1213-mib" 10.3.2.120 atIfIndex 2 128.253.154.1
java snmpget_by_index -v v3 -u initial -w initialPass -a MD5 -m "../../mibs/RFC1213-mib" 10.3.2.120 atPhysAddrress 2 128.253.154.1
java snmpget_by_index -v v3 -u initial -w initialPass -a MD5 -m "../../mibs/RFC1213-mib" 10.3.2.120 ifDescr 2
|