Hi
I need to change the state from HARD to SOFT or OK.
Is it possible to do that from an event in a service?
My problem is that when I am monitoring a logfile I want a notification every hit. Lets say the monitorscript find two patterns that matches, it sends me a notification in a mail with all matched lines (I use $LONGSERVICEOUTPUT$ instead of $SERVICEOUTPUT$) . Now the service is in CRIT and HARD state. Next minute another error appears in the monitored log but I will not be notified on that. I want all the hits to be sent to me in a mail instead of logging into the server and check it manually) . So if I change the state in the service from HARD to SOFT or OK, next hit in the logfile will cause the state to change from OK/SOFT to HARD and notify me again.
My idea was this:
define service {
use local-service
host_name localhost
service_description Check_logfiles
check_command check_logfiles.pl
max_check_attempts 1
check_interval 1
event_handler
}
Kindly Regards
Claes