I am going to need to pass back a text string greater than 255 characters in 
some cirsumstances, so using the snmpAdminString is not going to work for me.= 
in all cases. 

Would you happen to know whether another type of string definition exists which 
will allow me to return a much larger text string or would I need to define my 
own string definition in my MIB to make this happen?

Lets say I want to return 2000 characters ..... is there a definition which 
exists which I can use in my MIB?    Are there any downsides to returning a 
2000 character text string for a SNMP query?



-----------------------------------------------------------------------------------------
From: 
Dave Shield <[EMAIL PROTECTED]>
Subject: Re: What is the 
difference between SnmpAdminString and DisplayString?
To: 
[EMAIL PROTECTED]
Cc: "net-snmp Coders" 
<[email protected]>
Date: Friday, June 27, 2008, 
7:36 AM

2008/6/27 Need Help <[EMAIL PROTECTED]>:
> I am writing a MIB for my company and one of the fields needs to pass back
> text but I am not sure whether to use the "SnmpAdminString" or
> "DisplayString" field type.
>
> Will someone explain the difference for me?

Have you tried reading the descriptions of these two types
in the relevant MIB
 files?

SNMPv2-TC:DisplayString ::= TEXTUAL-CONVENTION
    DISPLAY-HINT "255a"
    DESCRIPTION
            "Represents textual information taken from the NVT ASCII
            character set, as defined in pages 4, 10-11 of RFC 854...."
    SYNTAX       OCTET STRING (SIZE (0..255))

SNMP-FRAMEWORK-MIB::SnmpAdminString ::= TEXTUAL-CONVENTION
    DISPLAY-HINT "255t"
    STATUS       current
    DESCRIPTION "An octet string containing administrative
                 information, preferably in human-readable form.
                 .... represented using the ISO/IEC
                 IS 10646-1 character set, encoded as an octet
                 string using the UTF-8 transformation format
                 described in [RFC2279]....."
    SYNTAX       OCTET STRING (SIZE (0..255))


So they are both printable strings, of max length 255.
But DisplayString can only take 7-bit ASCII string
 values,
while SnmpAdminString can handle UTF-8-encoded
internationalised strings.


Hence if you're geographically-blinkered, and assume that
USA==TheWorld, you'll probably use DisplayString.
   If you've twigged the fact that not everyone works in
English, and some other languages can contain other
characters that don't appear on a US keyboard, then
you use SnmpAdminString.

   :-)

Dave



      
-------------------------------------------------------------------------
Check out the new SourceForge.net Marketplace.
It's the best place to buy or sell services for
just about anything Open Source.
http://sourceforge.net/services/buy/index.php
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to