netsnmp version : 5.1.2
operating system tested on: windows xp sp1
The patch is about supporting multiple ip or ip address
range to snmpget to query multiple ip address for the
same snmp object id. It also include support of
additional option -Ci filename to read ip address list from
the filename.
The patch include changes to snmpget.c, snmpget.dsp
and added two additional files range.c, range.h to net-
snmp5.1.2/apps directory.
I have made the following changes to snmpget.c
1. modified to accept multiple range of ipaddress for eg:
192.168.1.10-20 or 192.168.1.0/16. added range.[ch]
to provide this support to snmpget.dsp
2. provided one more option -Ci to accept inputfile that
contains the list of ipaddresses. With -Ci option, the
command line still needs a dummy target ip address to
work with snmp_parse_args( ). eg: snmpget -c public -
v1 -Ci ipfile 0.0.0.0 1.3.6.1.2.1.1.1.0 (where ipfile is the
file containing list of ipaddresses)
3. replaced fprintf with snmp_log to log the output or
error with -Lf filename option
-Ganga
include snmpget.c.patch,snmpget.dsp.patch,range.c range.h
Logged In: YES
user_id=848638
Please also see the corresponding thread on the -coders list:
http://sourceforge.net/mailarchive/message.php?msg_id=9673402
I'd love to see this functionality in 5.2.
Logged In: YES
user_id=848638
The discussion on this feature ended without reaching a
result/consensus. I'd still like to see this functionality
in 5.3. Any further comments/objections? Shall we go for it?
Logged In: YES
user_id=1310219
Hi Thomas,
Your patch is fine, but i wanted to reduce the packects i send
to some vlan or group of computers by broadcasting only one
packet ( one request ).
Yours solution is same as "forking" many single snmpget
requests, and this was already done in some othre ways already.
Is there any why to broadcast one snmpget request, and any
host listening will reply...
David
Logged In: YES
user_id=848638
David, this is not *my* patch. As for (limited) UDP
broadcast support, have a look at patch 700681 instead:
http://sf.net/support/tracker.php?aid=700681
Logged In: YES
user_id=1310219
Thanks!
I will check it.
David