-
Notifications
You must be signed in to change notification settings - Fork 2
MFD:ifXTable:Data_Access
The net-snmp access routine returns a container of netsnmp_interface_entry pointers that contain a snapshot of the current data. However, as I mentioned before, this structure does not contain all the data we need for ifXTable mib. For example, the Linux kernel doesn't report the last time an interface was changed. We have to periodically poll for the interfaces, and check to see if each entry has changed. This polling has the added benefit of always keeping our cache current.
When the agent starts up and initializes, the ifXTable_init_data function will be called to allow us to do any initilization for our data access functions. We don't have any, so we'll just leave the function body empty.
The cached-container access method also has it's own initilization routine, ifXTable_container_init. This allow you to use a custom container or tweak the cache parameters. We'll cover both of these more advanced topic in a later tutorial. For now, we'll leave the function body alone, using the default container and default cache parameters.
|