We are using Kapacitor to generate alerts for several services.
Using this command on CLI : kapacitor show-topic main:v_trigger_reachable:alert5
Result is:
ID: main:v_trigger_reachable:alert5
Level: CRITICAL
Collected: 0
Handlers: []
Events:
Event Level Message Date
reachable front002 CRITICAL CRITICAL Host front002 is dead. Time=2018-07-20 11:36:00 +0000 UTC 20 Jul 18 11:36 UTC
reachable back003 CRITICAL CRITICAL Host back003 is dead. Time=2018-07-20 11:36:00 +0000 UTC
As those hosts don’t exist anymore, we would like to delete those events (not sure the term is right), but we don’t know how to proceed. Does someone have a clue how to do it ?
So then, to be clear, you want to clear the event, but still have the event history available? I believe that you can either delete the event, in which case the history goes with it, or you can keep the history by disabling the event.
I guess it would also be possible to write a query to pull all the event history out, and re-store it under a different measurement, and then delete the event.
Sorry for late response.
Maybe I should talk about our needs.
On a alert, we have for example disk space > 80% alerts for all our servers. When a server is shutdown, we still have the last event in kapacitor. If possible, we would like to handle this case in kapacitor.
Deleting everything, filtering and recreating seems to us a big work for such an little need.
We have a similar problem - when a host is not submitting measurements, kapacitor raises a deadman event based on the system measurement - this will be resent every 5 minutes.
When a host is decommissioned we cannot delete the alert event from kapacitor.