________________________________
From: Wes Hardaker <[email protected]>
To: sujata patra <[email protected]>
Cc: [email protected]
Sent: Tue, December 21, 2010 6:11:08 AM
Subject: Re: doubt in nested table implementation

>>>>> On Sun, 19 Dec 2010 02:43:26 -0800 (PST), sujata patra 
>>>>><[email protected]> said:

sp> I have implemented simple table quite a few times . But I am confused to  
sp> implement when the mib contain more than one table  and the tables are  
sp> nested(means the second table data repeats for each row of first table  
data, 

sp> which I think is very common).

When you mean nested, you actually mean a table with indexes that
reference indexes from the first table right?
Thanks Wes. That's right . I have got it now and able to progress . I was 
confused whether to make tree structure .
This is basically making the tree to linear array by storing  the indexes of 
each parent/grand parent node. right ?

Another issue I am finding that OID's are getting registerd two times(might 
be). 
snmpwalk is showing duplicate data . I could not figure out .  what could be 
the 
issue ?
I have added  all the columns.
   netsnmp_table_helper_add_indexes(table_info,
                           ASN_INTEGER,  /* index: messageIndex */
                           ASN_INTEGER,  /* index: msgVMIndex */
                           ASN_OCTET_STR, /*vmName*/
                           ASN_INTEGER,  /* vmId */
                           0);
If I do not add all the columns, it is crashing. is it mandatory to add all the 
columns ?



You need to understand a bit more about SNMP to properly implement
that.  You can still do it with the iterator code, but you need to
handle returning the multiple indexes from the lookup functions (_first
and _next).  The data function will still need to retrieve the right
data given the indexes found.

-- 
Wes Hardaker
Please mail all replies to [email protected]



      
------------------------------------------------------------------------------
Forrester recently released a report on the Return on Investment (ROI) of
Google Apps. They found a 300% ROI, 38%-56% cost savings, and break-even
within 7 months.  Over 3 million businesses have gone Google with Google Apps:
an online email calendar, and document program that's accessible from your 
browser. Read the Forrester report: http://p.sf.net/sfu/googleapps-sfnew
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to