mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-31 01:35:36 +02:00
Skip recover alert if was alredy recovered
This commit is contained in:
parent
7341d27d6c
commit
561e8c4c20
@ -1041,8 +1041,12 @@ sub pandora_execute_alert {
|
|||||||
$event_generated = 1;
|
$event_generated = 1;
|
||||||
$monitoring_event_custom_data = $custom_data;
|
$monitoring_event_custom_data = $custom_data;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if($alert_mode == FIRED_ALERT || ($alert_mode == RECOVERED_ALERT && $action->{'recovered'} == 0)) {
|
||||||
pandora_execute_action ($pa_config, $data, $agent, $alert, $alert_mode, $action, $module, $dbh, $timestamp, $extra_macros, $monitoring_event_custom_data);
|
pandora_execute_action ($pa_config, $data, $agent, $alert, $alert_mode, $action, $module, $dbh, $timestamp, $extra_macros, $monitoring_event_custom_data);
|
||||||
|
}else{
|
||||||
|
logger ($pa_config, "Skipping recover action " . safe_output($action->{'name'}) . " for alert '" . safe_output($alert->{'name'}) . "' module '" . safe_output($module->{'nombre'}) . "'.", 10);
|
||||||
|
}
|
||||||
|
|
||||||
if($alert_mode == RECOVERED_ALERT) {
|
if($alert_mode == RECOVERED_ALERT) {
|
||||||
# Reset action thresholds and set recovered
|
# Reset action thresholds and set recovered
|
||||||
|
Loading…
x
Reference in New Issue
Block a user