>>>>> On Wed, 17 Aug 2011 06:50:42 +0100, Dave Shield 
>>>>> <d.t.shi...@liverpool.ac.uk> said:

DS> The simplest way to do that (though not the most efficient) would
DS> probably be to clear the database table completely, and walk the MIB
DS> table in its entireity.  But there are better ways to handle this,
DS> without throwing away perfectly valid data.

FYI, what we did for Net-Policy was to augment the table with a few
other bits of information in some special columns:
  timetaken:      time the particular collection was taken
  clientid:       the id of the client the data came from
                  (so you can store more than one client in the table)
  collectionnum:  A numeric incrementing integer that captures which
                  rows came from a particular "data gathering" (IE, walk).
  sysuptime:      So you could track reboots for discontunities

The big one in there is the 'colectionnum', which should be an index
itself so that lookups via "where collectionnum = max(collectionnum)"
(or equivalent; I forget the exact expression we used) are fast.  But it
lets you track both history, time and select based on what you need.
Recording *only one* Counter object, for example, is useless.  You must
have at 2 to get meaningful data out of it.
-- 
Wes Hardaker
Please mail all replies to net-snmp-coders@lists.sourceforge.net

------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system, 
user administration capabilities and model configuration. Take 
the hassle out of deploying and managing Subversion and the 
tools developers use with it. http://p.sf.net/sfu/wandisco-d2d-2
_______________________________________________
Net-snmp-coders mailing list
Net-snmp-coders@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to