Welcome to Questions - Ask OpenNMS, where you can ask questions and receive answers from other members of the community.

Why OpenNMS behaves like this when thresholding events will be deleted?

0 votes
  • A node got a low threshold event
  • Then I delete this low event from database (with pqsl command line)
  • Now OpenNMS won't detect this low threshold again (waited 4-5 polling cylces)
  • When I restart OpenNMS, it will detect  this low threshold again
OpenNMS version
asked Oct 15, 2013 by mfuhrmann (7,350 points)

1 Answer

+1 vote
Best answer
It is has something to do with "state". Thresholds are processed by collectd. If you collect the data, Collectd applies your threshold configuration. Imagine you have to query every time the database to see if already a "low-threshold-exceeded" event appeared and you collect data every 2 minutes for 50.000 metrics? You don't want to query the file system or the database all the time. Same thing with "trigger", you apply a trigger which creates a threshold exceeded event if the value is 3 times in a row over your configured threshold. You cannot read from RRD the last 2 collected metrics to compare the value. So it is expensive to read/write this state from a hard disk or a database. Collectd handles all of it in memory. If you restart OpenNMS, Collectd lose his memory and the state information for a threshold. Currently the only chance to get a clear state after restart is to apply your threshold configuration as it is again. The event in the database has no effect on the data collection, it is just a result of the in-memory calculation of Collectd. This is the reason, it has no effect deleting the event in the database. It seems possible to recreate the last threshold state from the database events just for a restart of Collectd to suppress already applied thresholds except for them with a trigger > 1.
answered Oct 15, 2013 by indigo (11,640 points)
edited Oct 15, 2013 by indigo