This is a discussion on Re: array_user.conf row creation within the SNMP Users forums, part of the Networking and Network Related category; On Fri, 22 Apr 2005 08:06:16 -0700 George, wrote: GG> Can you please provide some information regarding ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
On Fri, 22 Apr 2005 08:06:16 -0700 George, wrote:
GG> Can you please provide some information regarding addition of caching to GG> this? There are two ways to do this. One is to completely flush the cache each time, and reload it from scratch. The other is to search the cache for exiting rows to update/add/remove. The first is fairly simple. use CONTAINER_FOR_EACH to go through and free each row, then CONTAINER_CLEAR, followed by inserting all rows again. The second is a little more complicated, but required if you want to keep some non-cache data in the row. For an example, see the ifTable cache_load in mibgroup/if-mib/ifTable/ifTable_data_access.c. GG> 1) The question is can I directly add snmp_alarm_register? After GG> Initialization Something like the below statement which basically GG> reloads data? GG> GG> snmp_alarm_register(timeout, SA_REPEAT, Reload, NULL); yep, that would work. GG> 2) If I add my own refresh routines, how to handle the requests while GG> reloading the data? Since the agent is single threaded, and alarms don't run while requests are being processed, it shouldn't be an issue. -- NOTE: messages sent directly to me, instead of the lists, will be deleted unless they are requests for paid consulting services. 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/...net-snmp-users |