I'm trying to use Active Monitoring and the DisMan module to manage my processes and I ran into a weird situation. DisMan would fix my processes only if the process restarted successfully and could run successfully for a given time window. In my case, around 1 minute. If the process died again too quickly or never started, no new prFixit event was fired.
In short, the prErrorFlag flag in the prTable had to transition like so prErrorFlag values: 0 => 1 => 0 => 1 OK - prFixIt event fired on each transition from 0 to 1 0 => 1 => 1 => 1 Not OK - prFixIt event only fired once I checked the value of mteTrigger->flags and bitmask MTE_TRIGGER_FLAG_DELTA was *not* set (actual value was 111100110010) but it acted like mteTrigger.c needed a change to actually fire the event. What I think is happening is there's logic to not try to send the same event twice. There's an additional concern though! The process table is cached so even if find a way to fire prFixit events on each monitor run, I'll be firing events based on values in the process cache, not the actual process list from the OS so if the process does start ok, I'll be attempting to start the process unnecessarily. Version: 5.7.1 (from git) OS: Fedora 14/64bit Relevant Config: ====================== setEvent prFixIt prErrFix = 1 monitor -r 10 -e prFixIt "procTable" prErrorFlag != 0 proc sendmail procfix sendmail /etc/init.d/sendmail start Debug Output: ====================== disman:event:delta: Bool comparison: (1 != 0) 1 disman:event:trigger:fire: Firing boolean test: UCD-SNMP-MIB::prErrorFlag.1 disman:event:trigger:monitor: Running trigger (procTable) disman:event:delta: Bool comparison: (1 != 0) 1 disman:event:trigger:monitor: Running trigger (procTable) disman:event:delta: Bool comparison: (1 != 0) 1 ... ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Net-snmp-coders mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/net-snmp-coders
