Skip to content

Commit

Permalink
Start rules for "PluginCheckTask" logs
Browse files Browse the repository at this point in the history
helps with #12
  • Loading branch information
widhalmt committed May 3, 2019
1 parent 8973e8d commit bfb4a4b
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions filter-50-pluginchecktask.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
filter {
if [icinga][facility] == "PluginCheckTask" {
if [message] =~ /^Check command for object/ {
grok {
match => ["message","Check command for object '%{DATA:[icinga][object]}' \(PID: %{POSINT:[icinga][plugin][pid]}, arguments: '%{DATA:[icinga][plugin][plugin]}' %{DATA:[icinga][pugin][arguments]}\) terminated with exit code %{POSINT:[icinga][plugin][exitcode]}, output: %{GREEDYDATA:[icinga][plugin][output]}"]
id => "icinga_checkcommandforobject"
add_tag => "icinga_checkcommandforobject"
tag_on_failure => ["_grokparsefailure","icinga_checkcommandforobject_failed"]
add_field => {
"[icinga][eventtype]" => "icinga_checkcommandforobject"
}
}
}
}
}

0 comments on commit bfb4a4b

Please sign in to comment.