Re: trap information interchange: in text format

"Dave Shield" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <[email protected]>
On 21/03/07, Joao Miguel Ferreira <[email protected]> wrote:
>  I need to find a suitable string format for receiving information to be
>  sent as traps.

Are you looking at generating SNMPv1-style traps, or SNMPv2
notifications?    Will you need to specify version information
(including community/SNMPv3 user settings), or just the "payload"
of the trap?

At a minimum, you'll need to be able to handle:

   SNMPv1)   trap type (2 integers)
                      enterprise (OID)
                      + arbitrary varbind list

  SNMPv2)    trap OID
                      + arbitrary varbind list

You may wish to be able to specify uptime and (v1) agent as well,
but this is going to be the bare minimum.




>  TRAP_OID=".1.3.6.1.2.1.1.x.y.z"  TRAP_TYPE="Integer" TRAP_VALUE="1234"

A single OID is probably sufficient here (assuming v2-style)
TRAP_TYPE is redundant.
TRAP_VALUE is misleading (and either insufficient, or redundant)


>  VARBIND_OID=".1.3.6.1.2.1.a.b.c.d.e"
> VARBIND_TYPE="Integer"
>  VARBIND_VALUE="1000"
> VARBIND_OID=".1.3.6.1.2.13.45.w.v.z.q"
>  VARBIND_TYPE="Srting" VARBIND_VALUE="Hello World"

That should work, yes

How would you handle string values containing a " character?

Do you have a full list of acceptable TYPE tokens?
If not, then I'd suggest using the standard SYNTAX types from
the SNMP specification, rather than inventing your own.

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.