improved check plugin for Netways EventDB
check_eventdb2.pl is the improved check plugin for Netways EventDB. The code has grown heavily (around 70%). But also a lot of new features has been implemented:
-r | --regexp will treat messagestrings as regular expressions -s | --show shows the found messages in Nagios. Lenght of string can be set in $message_lenght and multilineoutput can be HTML style or Nagios 3 style. See $ml_show_msg. --acknowledged will include acknowledged entries in the select statement --version added to print program version Values for priority can be added as single scalar (for example emerg) or as a comma separated list (for example emerg,alert,crit) variable Â§matches removed. It was replaced by $rowcnt because we let not count the database. We count the rows received from the database. --maxage Maximum age for records use for alerts
Acting as eventhandler:
In case of using check_eventdb as a event handler all three variables (
--serviceoutput) nust be used together. Records found will be acknowledged.
--servicestate Contains $SERVICESTATE$ from Nagios if started as eventhandler for acknowledging or deleting records/entries --servicestatetype Contains $SERVICESTATETYPE$ from Nagios if started as eventhandler for acknowledging records/entries --serviceoutput Contains $SERVICEOUTPUT$ from Nagios if started as eventhandler for acknowledging or deleting records/entries. $SERVICESTATE$ MUST be OK or UP, $SERVICESTATETYPE$ MUST be hard and $SERVICEOUTPUT$ should contain the output of your "submit passive check result" together with the name of the operator (for example "problem fixed - D.Duck") --recover The messagestring following this will cause a recovery. Wildcards are allowed. If -r is set the string will be interpreted as a regular expression. -H must been set. And the message containing the recovery string must be the latest. If there are alerts newer than the recovery string only this alerts are used. --recover_regexp Interpret recoverstring as regular expression (awk/sed style). Works only with --recover set. --recover_prio The messagestring following this will contain the priority for recovery -H must been set. --recover_prog This will contain a name of a program causing the recovery in case the recovery message is not sent by the program causing the error. -H must been set.
See readme.txt and Wiki for full documentation.