On 3 February 2011 05:02, Biswajit Mandal <[email protected]> wrote:
> I have query regarding the objects whose SYNTAX is PortList.
>
> Currently the objects having PortList SYNTAX, scaling the number of ports
> becomes a problem.
>
> For example say,
> The number of ports in the system can scale upto a few thousands-say 32k.
> To configure the ports 30001-30100 to a VLAN, the user has to specify:
> 3750 bytes of 00 and then set the bits for the ports from 30001-30100.
>
> Would like to know if there is a way of representing the MIB object which
> supports a better user friendly configuration.


Are you talking about how such values are represented "on-the-wire",
or how the end-user would specify these values to a client application?

Assuming the latter, then your application could accept a list of port
numbers (or port ranges) and parse the individual numbers to set the
appropriate bits in the octet string

  This is effectively what the 'snmp_add_var()' routine does for the BITS
type.  (Though without the handling of ranges)

Dave

------------------------------------------------------------------------------
The modern datacenter depends on network connectivity to access resources
and provide services. The best practices for maximizing a physical server's
connectivity to a physical network are well understood - see how these
rules translate into the virtual world? 
http://p.sf.net/sfu/oracle-sfdevnlfb
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to