[AGENT++] Walking table row by row using SNMP++

Jochen Katz katz at agentpp.com
Tue May 1 18:57:13 CEST 2007


Hi,

> For the second answer though, are you saing that I should the OIDs of the
> columns in the request? Since, from the documentation, you can set a single
> OID for a specific VB (using the setOID method), I assume you will have add
> multiple VBs to the request PDU as follows:
> 
> Pdu pdu;
> Vb vb;
> vb.set_oid (column1Oid);
> pdu+= vb;
> vb.set_oid (column2Oid);
> pdu+= vb;
> vb.set_oid (column3Oid);
> pdu+= vb;

yes, this is the way to do it.

> 1. If I set the max repetitions to n and the use the above pdu in a getBulk
> request, should I get n rows with 3 columns each (specified by the OIDs
> above)?

Yes, if the pdu size limit is not reached, you will get n rows

> 2. If in 1, the table only has n-1 rows, then should agent return an
> end-of-table or it is based on the agent implementation? Or will I probably
> get a no-such instance?

As the the "get bulk processing engine" does not know anything about the
table structure, after the last row, you will get the first row from
column 2 and the first object after the table.

> 3. By adding the row number to each columnOid as follows, should I be able
> to select a particular row:
> 
> Pdu pdu;
> Vb vb;
> vb.set_oid (column1Oid+"."+rowIndex);
> ..

Yes.

> Of course I can simply try these out and see the results but it would be
> helpful to know what to expect.

I just wrote, what I would expect...

Regards,
  Jochen




More information about the AGENTPP mailing list