Hi Fulko

Thanks for your response.
Do you have any good examples or suggestions on how I can itorate the table in 
Getbulk operation in row instead of column?

Thanks,
Barclay

________________________________
From: Fulko Hew [mailto:fulko....@gmail.com]
Sent: 2013年4月24日 20:22
To: Zheng, Wenjie (Barclay)
Cc: Dave Shield; net-snmp-cod...@lists.sourceforge.net; 
net-snmp-users@lists.sourceforge.net
Subject: Re: Row operation in Net-SNMP


On Wed, Apr 24, 2013 at 2:02 AM, Zheng, Wenjie (Barclay) 
<barclay.zh...@alcatel-lucent.com<mailto:barclay.zh...@alcatel-lucent.com>> 
wrote:
Hi, Dave et al,

I have a puzzle of Net-SNMP table operation, for example I have a table like 
below:

a1-a2-a3-a4
b1-b2-b3-b4
c1-c2-c3-c4

In net-snmp, if I use iterator helper to implement the table handler, it will 
translate the getbulk request to bunch of get request, the order is:
a1->b1->c1->a2->b2->c2.....

So it's first column then send column and so on. In my case, the data is stored 
ourside in row order, like first row, second row. a1->a2->a3->a4->b1->b2....

The iterator, just like the definition of how getNext() works, is:
it follows OIDs 'in order'; and OIDs define entries as:

   table.column.index...

So the indexes are all traversed first ... before it 'backs up' to go to the 
next column
  ... before it goes to the next table... etc.

I can read the whole row one time, and then return all the values for the whole 
row. Then I only need read outside data 3 times for the whole table. But in the 
iterator helper, I will need to read outside data 12 times for the whole table.

That is indeed what you need to do if you want to optimize/minimize the number 
of
transactions on the network.

------------------------------------------------------------------------------
Try New Relic Now & We'll Send You this Cool Shirt
New Relic is the only SaaS-based application performance monitoring service 
that delivers powerful full stack analytics. Optimize and monitor your
browser, app, & servers with just a few lines of code. Try New Relic
and get this awesome Nerd Life shirt! http://p.sf.net/sfu/newrelic_d2d_apr
_______________________________________________
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