On 05/09/06, Arnaud BODENAN <[EMAIL PROTECTED]> wrote: > Thanks Dave. What I've done now is:
I'm sorry - this code is meaningless to me. You're listing assorted numeric OIDs, but I have no idea what MIB objects they refer to. I'm pretty sure that they aren't correct, since: > // Declare the top Oid for my table > oid genServerTableOid[] = { 1, 3, 6, 1, 4, 1, 99999, 10000, 1, 1 }; > // Define the oid of the first column from the index returned > oid genServerAllocatedOid[] = { 1, 3, 6, 1, 4, 1, 99999, 10000, 1, 1, > allocatedIndex }; don't seem to match. I'd expect another field in the column-instance OID array. But you've never listed your MIB file, so I'm forced to guess. And quite frankly, I don't have the time to waste at the moment. I'm also not confident that initialising an array using another variable is particularly safe. You'd probably be much safer using a dummy placeholder field, and explicitly inserting the index value: oid genServerAllocatedOid[] = { 1, 3, 6, 1, 4, 1, 99999, 10000, 1, 1, 1?, 999 }; genServerAllocatedOid[ genServerAllocatedOidLen-1 ] = allocatedIndex; > // Set the range_subid to the first column of the row > handlerServerTable->range_subid = genServerAllocatedOid; No The range_subid is an *index* into this array - not the whole OID. Please re-read the AgentX specifications. You clearly haven't grasped how this mechanism works. > // set the range_ubound ??? > handlerServerTable->range_ubound = allocatedIndex; No. This is the value of the maximum column *object* subidentifier (the bit you seem to have omitted in the earlier code). Not the row index (instance) subidentifier. > If I understand you, I should set range_ubound to 5 (I have five columns in > my row) ? Yes. Or at least Probably. I can't be sure, 'cos you've never shown us the MIB file that defines this table. If there are five columns in the table, they would typically be numbered 1..5, in which case range_ubound would indeed be 5. But if they're numbered 2..6 (for example) then ubound would be 6. Dave ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ 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