From e921e1891703ca0058f0ba04a4702cbfd0e458d9 Mon Sep 17 00:00:00 2001 From: qgarnier Date: Thu, 23 Sep 2021 09:37:02 +0200 Subject: [PATCH] fix(hp/p2000): health mode - sensor threshold (#3132) --- storage/hp/p2000/xmlapi/mode/components/sensor.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/storage/hp/p2000/xmlapi/mode/components/sensor.pm b/storage/hp/p2000/xmlapi/mode/components/sensor.pm index 74fa72489..0a25fbcfb 100644 --- a/storage/hp/p2000/xmlapi/mode/components/sensor.pm +++ b/storage/hp/p2000/xmlapi/mode/components/sensor.pm @@ -105,7 +105,7 @@ sub check { my ($exit2, $warn, $crit, $checked) = $self->get_severity_numeric(section => 'sensor', instance => $type . '.' . $sensor_id, value => $value); if (!$self->{output}->is_status(value => $exit2, compare => 'ok', litteral => 1)) { $self->{output}->output_add( - severity => $exit, + severity => $exit2, short_msg => sprintf("Sensor '%s' is %s %s", $sensor_id, $value, defined($unit) ? $unit : '-') ); } @@ -116,7 +116,7 @@ sub check { instances => $sensor_id, value => $value, warning => $warn, - critical => $crit, + critical => $crit ); } }