Bin noch nicht wirklich weiter gekommen, aber das debug.log zeigt das, was ich beschrieben habe:
Code: Alles auswählen
# tail -f /var/log/icinga2/debug.log | grep 'j2' | grep "perfdata = 'procs"
[2020-12-17 19:26:02 +0100] debug/IdoMysqlConnection: Query: UPDATE icinga_servicestatus SET acknowledgement_type = '0', active_checks_enabled = '1', check_command = 'procs', check_source = 'j2.gehrke.local', check_type = '0', current_check_attempt = '1', current_notification_number = '0', current_state = '0', endpoint_object_id = 319, event_handler_enabled = '1', execution_time = '0.030935', flap_detection_enabled = '0', has_been_checked = '1', instance_id = 1, is_flapping = '0', is_reachable = '1', last_check = FROM_UNIXTIME(1608229561), last_hard_state = '0', last_hard_state_change = FROM_UNIXTIME(1608229561), last_state_change = FROM_UNIXTIME(1608229561), last_time_critical = FROM_UNIXTIME(1607862767), last_time_ok = FROM_UNIXTIME(1608229561), last_time_unknown = FROM_UNIXTIME(1608227467), last_time_warning = FROM_UNIXTIME(1608229532), latency = '0', long_output = '', max_check_attempts = '5', next_check = FROM_UNIXTIME(1608229618), normal_check_interval = '1', notifications_enabled = '1', original_attributes = 'null', output = 'PROCS OK: 285 processes ', passive_checks_enabled = '1', percent_state_change = '99', perfdata = 'procs=285;350;500;0;', problem_has_been_acknowledged = '0', process_performance_data = '1', retry_check_interval = '0.500000', scheduled_downtime_depth = '0', service_object_id = 404, should_be_scheduled = '1', state_type = '1', status_update_time = FROM_UNIXTIME(1608229561) WHERE service_object_id = 404
[2020-12-17 19:26:33 +0100] debug/IdoMysqlConnection: Query: UPDATE icinga_servicestatus SET acknowledgement_type = '0', active_checks_enabled = '1', check_command = 'procs', check_source = 'j2.gehrke.local', check_type = '0', current_check_attempt = '1', current_notification_number = '0', current_state = '1', endpoint_object_id = 319, event_handler_enabled = '1', execution_time = '0.030845', flap_detection_enabled = '0', has_been_checked = '1', instance_id = 1, is_flapping = '0', is_reachable = '1', last_check = FROM_UNIXTIME(1608229592), last_hard_state = '0', last_hard_state_change = FROM_UNIXTIME(1608229561), last_state_change = FROM_UNIXTIME(1608229592), last_time_critical = FROM_UNIXTIME(1607862767), last_time_ok = FROM_UNIXTIME(1608229561), last_time_unknown = FROM_UNIXTIME(1608227467), last_time_warning = FROM_UNIXTIME(1608229592), latency = '0.000592', long_output = '', max_check_attempts = '5', next_check = FROM_UNIXTIME(1608229621), normal_check_interval = '1', notifications_enabled = '1', original_attributes = 'null', output = 'PROCS WARNING: 289 processes ', passive_checks_enabled = '1', percent_state_change = '99', perfdata = 'procs=289;250;400;0;', problem_has_been_acknowledged = '0', process_performance_data = '1', retry_check_interval = '0.500000', scheduled_downtime_depth = '0', service_object_id = 404, should_be_scheduled = '1', state_type = '0', status_update_time = FROM_UNIXTIME(1608229592) WHERE service_object_id = 404
Zuerst werden die Limits 350;500 angelegt, 31 Sekunden später 250;400.
Bei 289 Prozessen bleibt die erste Variante grün, die zweite wird gelb.