Re: Defining the MIB - experts opinion needed

"Dave Shield" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <[email protected]>
On 08/01/07, srikrishnan <[email protected]> wrote:
> I need some experts opinion in defining the base data type in the mib.
>
> What is the difference in describing the data type as shown in the below
> two forms.
> 1.
> Unsigned32 ::=
>     [APPLICATION 2]
>        IMPLICIT INTEGER (0..4294967295)
>
> 2.
> Unsigned32 ::=  INTEGER (0..4294967295)

You shouldn't be defining Unsigned32 yourself.
You should simply IMPORT it from SNMPv2-SMI


> Is there any significance ?  I can see the 1 st way of defining the base
> data types in the SNMPv2-SMI and not as shown in the 2nd way. Can any
> one explain the significance ?

SNMP uses the first definition.
This allows SNMP applications to recognise U32 values as such,
even without the relevant MIB files.

With the second approach, it would be impossible to tell whether
a particular (positive) value was signed or unsigned, simply from
the raw SNMP packet.

But that's purely academic - you shouldn't be defining either form.
You should use the definiton that's already there.

Dave

-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Net-snmp-users mailing list
[email protected]
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.