Hi,

I am having trouble walking a table of a mib I have created.
It only prints the first column of each table row.

I created a mib and ran the mib2c program to create a skeleton
source code, then went in and added code were the XXXs are and
following the examples in the net-snmp-5.1.1 source tree.

Maybe I do not understand the three functions called:

<tablename>_get_first_data_point() -
 Point to first structure in linked list, the stucture
 contains all the information for a single row in the table.

<tablename>_get_next_data_point() -
 Move point to next row in linked list.

<tablename>_handler() -
 Loop through the row returning the value for each column
 in a single table row.

When I use the DEBUGMSGTL macro and place an output trace message
in each function I will see the following pattern in the snmpd.log
file.

<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.
<tablename>_get_first_data_point here 1.

<tablename>_get_next_data_point here 2.

<tablename>_handler here 3.

The table has only 1 index and it is of type INTEGER and the total
number of columns in the table is 9.  (min_column = 2, max_colum = 9)

The 'requests' loop in the <tablename>_handler function will only
loop once.

If the <tablename>_get_first_data_point is used to set the starting
point of the table rows then why is it called once for each column
in the table minus the index count?

Who sets up the requests link list that is passed to the
<tablename>_handler function?

The scalar objects in my mib work fine.  Been working on the table
part of this for a week now and I am getting no were.

As a note, the examples on the web site need to be expanded.  Use
mibs with more than one table and several columns per table.  I for
one learn best with examples and documentation pointing out the
finer points of the code.

Thanks in advance for any help you can give.

--
Confidentiality Notice: This message, including any attachments, is for the sole use 
of the intended recipient(s) and may contain confidential, proprietary, and privileged 
information. Any unauthorized review, use, disclosure, or distribution is strictly 
prohibited and may be unlawful. If you are not the intended recipient, please contact 
the sender by reply e-mail and destroy all copies of the original message.

begin:vcard
fn:Kelly Wiles
n:Wiles;Kelly
org:NexGen City, LP
adr;dom:;;1680 Glenville Rd;Richardson;Tx;75081
email;internet:kwiles.nexgencity.com
title:Software Configuration Management Engineer
tel;work:214-420-4996
version:2.1
end:vcard

Reply via email to