RE: Trap question: OID for variable from a table

"McGowen, Wendy" <[email protected]>
Newsgroups gmane.network.net-snmp.user
Message-ID <E05F1FD208D5AA45B78B3983479ECF08029FD1DB@saturn.p3corpnet.pivot3.com>
So since this is a single indexed table, the vmName would be the last
index, making .118.109.49 acceptable. Plus I've defined it with IMPLIED
(although is that really necessary?):

    vmTableEntry OBJECT-TYPE
        SYNTAX  VMTableEntry
        MAX-ACCESS  not-accessible
        STATUS  current
        DESCRIPTION
            "A description of a vm."
        INDEX   { IMPLIED vmName }
        ::= { vmTable 1 }

And the "3" in your second example would be the length of the actual
string value, oh Jedi Master.  ;-)

Many thanks for your help, Dave!

Wendy

-----Original Message-----
From: Dave Shield [mailto:[email protected]] 
Sent: Wednesday, March 04, 2009 3:20 PM
To: McGowen, Wendy
Cc: [email protected]
Subject: Re: Trap question: OID for variable from a table

2009/3/4 McGowen, Wendy <[email protected]>:
>          I haven't done anything with string indices
> yet, but it looks like I just have to convert each character in the
> string to its ASCII equivalent (for example, "vm1" would be
.118.109.49,
> correct?).

Perhaps.
It depends on whether the index is IMPLIED or not.

If it's IMPLIED (which is only possible for the last index in a
table), then yes.
If not, then "vm1" would actually be 3.118.109.49

Where the '3' comes from is left as an exercise for the student....

Dave

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
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.