On Thu, 4 Nov 2004 10:23:19 -0000 Maria wrote: MM> I've had a quick look at the disman event mib. Is there a way, from my MM> code, that I can detect when an alarm has been generated? I have a MM> requirement to be able to detect this within the code so that I can log MM> that a trap has been generated.
Only indirectly. The agent does have a callback when a trap is sent, so you could register for that. You would get called for all traps, not just event mib alarms, so you would have to peek into the pdu to decide if it is a trap you want to act on. MM> In relation to the Master Agent question, we would prefer to use the MM> net-snmp version bundled with Red hat (to avoid having to support it). Well, then that rules out adding your own callback to the disman event code. MM> Additionally, by changing the OIDs, does that in MM> effect mean either: (a) writing our own Master agent that will collate MM> all the information from the different Subagents and 'supply' the MM> information to a management browser using one OID; (b) supply multiple MM> MIBs to a management browser? (b) Note that I didn't say it was a good option. ;-) MM> We are currently using 5.0.9, but I see we can upgrade to 5.1.2. This MM> may be a problem for us. What do you need to change to register MM> different contexts? That depends on how you are registering now. If you are using new style code, then the netsnmp_handler_registration structure has a contextName member that you should set. But, as I said earlier, support for contexts in sub-agent is new to 5.2. I have no idea how long it will take RedHat to switch to 5.2, so if you want to used contexts then you may want to use dynamically loaded modules instead of a sub-agent. That assumes, of course, that RedHat enables dlmod support in their RPMs. I'm not sure that they do. -- Robert Story; NET-SNMP Junkie <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. ------------------------------------------------------- This SF.Net email is sponsored by: Sybase ASE Linux Express Edition - download now for FREE LinuxWorld Reader's Choice Award Winner for best database on Linux. http://ads.osdn.com/?ad_id=5588&alloc_id=12065&op=click _______________________________________________ Net-snmp-users mailing list [EMAIL PROTECTED] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users
