Currently, I am running net-snmp-5.0.9-4.rh73.i386.rpm

My creation table is a follows:  

netsnmp_table_set_multi_add_default_row(table_set,
 
COLUMN_COMMBASESTATSENTRYINDEX,
                                                ASN_INTEGER, 0, NULL, 0,
 
COLUMN_COMMBASESTATSENTRYCARDNUMBER,
                                                ASN_INTEGER, 0, NULL, 0,
 
COLUMN_COMMBASESTATSENTRYPORTNUMBER,
                                                ASN_INTEGER, 0, NULL, 0,
 
COLUMN_COMMBASESTATSENTRYRADARTYPE,
                                                ASN_OCTET_STR, 0, NULL,
0,
 
COLUMN_COMMBASESTATSENTRYSTATUS,
                                                ASN_INTEGER, 0, NULL, 0,
 
COLUMN_COMMBASESTATSENTRYMSGOUTCNT,
                                                ASN_COUNTER, 0, NULL, 0,
 
COLUMN_COMMBASESTATSENTRYFRAMEINCNT,
                                                ASN_COUNTER, 0, NULL, 0,
 
COLUMN_COMMBASESTATSENTRYFRAMEBADCNT,
                                                ASN_COUNTER, 0, NULL, 0,
0);

 
netsnmp_register_table_data_set(netsnmp_create_handler_registration
 
("commBaseStatsEntryTable",
 
commBaseStatsEntryTable_handler,
 
commBaseStatsEntryTable_oid,
 
commBaseStatsEntryTable_oid_len,
                                                HANDLER_CAN_RWRITE),
table_set, NULL);

        for (i=1; i<= number_of_tables; i++){

                index = i;

                row = netsnmp_create_table_data_row();

                netsnmp_table_row_add_index(row, ASN_INTEGER, &index,
sizeof(int));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYINDEX,ASN_INTEGER,(c
har*)&index,sizeof(int));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYCARDNUMBER,ASN_INTEG
ER,(char*)&index,sizeof(int));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYPORTNUMBER,ASN_INTEG
ER,(char*)&index,sizeof(int));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYRADARTYPE,ASN_OCTET_
STR,tmp,strlen(tmp));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYSTATUS,ASN_INTEGER,(
char*)&index,sizeof(int));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYMSGOUTCNT,ASN_COUNTE
R,(char*)&index,sizeof(int));
 
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYFRAMEINCNT,ASN_COUNT
ER,(char*)&index,sizeof(int));
        
netsnmp_set_row_column(row,COLUMN_COMMBASESTATSENTRYFRAMEBADCNT,ASN_COUN
TER,(char*)&index,sizeof(int));
                netsnmp_table_dataset_add_row(table_set,row);
        }

        netsnmp_register_auto_data_table(table_set,NULL); 

What might be the problem, the columns are numbered 1,2,3,4,5,6,7,8.
The examples that I found always had the columns start with 2 after the
row_add_index insertion.  Could this be the problem.


-----Original Message-----
From: Robert Story [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 07, 2005 5:45 PM
To: Robillard, Greg L
Cc: net-snmp-users@lists.sourceforge.net
Subject: Re: Table index problem

On Wed, 02 Feb 2005 11:33:52 -0600 Greg wrote:
GLR> Thanks for the information.  When I execute my get statements, I am

GLR> returning the values that I am expecting.  I would additionally 
GLR> like the snmpwalks to return the identical information which it is
not.

Ahh, thanks for the example. Now I understand the problem. The walk
definitely should represent the same data that you see for a get.

Your initial message showed how you registered your table, but not how
you are creating rows in the table.

--
Robert Story; NET-SNMP Junkie
Support: <http://www.net-snmp.org/> <irc://irc.freenode.net/#net-snmp>
Archive:
<http://sourceforge.net/mailarchive/forum.php?forum=net-snmp-users>

You are lost in a twisty maze of little standards, all different. 




-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
Net-snmp-users mailing list
Net-snmp-users@lists.sourceforge.net
Please see the following page to unsubscribe or change other options:
https://lists.sourceforge.net/lists/listinfo/net-snmp-users

Reply via email to