add new metrics qnap hardware
This commit is contained in:
parent
588a5dcd7b
commit
1c2f8aaee9
|
@ -89,11 +89,14 @@ sub check {
|
|||
$self->{output}->output_add(severity => $exit2,
|
||||
short_msg => sprintf("Disk '%s' temperature is %s degree centigrade", $result->{HdDescr}, $disk_temp));
|
||||
}
|
||||
$self->{output}->perfdata_add(label => 'temp_disk_' . $instance, unit => 'C',
|
||||
value => $disk_temp
|
||||
);
|
||||
$self->{output}->perfdata_add(
|
||||
label => 'temp_disk', unit => 'C',
|
||||
nlabel => 'hardware.disk.temperature.celsius',
|
||||
instances => $instance,
|
||||
value => $disk_temp
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
1;
|
||||
1;
|
||||
|
|
|
@ -61,9 +61,12 @@ sub check {
|
|||
$self->{output}->output_add(severity => $exit,
|
||||
short_msg => sprintf("Fan '%s' speed is %s rpm", $fan_descr, $fan_speed_value));
|
||||
}
|
||||
$self->{output}->perfdata_add(label => 'fan_' . $instance, unit => 'rpm',
|
||||
value => $fan_speed_value, min => 0
|
||||
);
|
||||
$self->{output}->perfdata_add(
|
||||
label => 'fan', unit => 'rpm',
|
||||
nlabel => 'hardware.fan.speed.rpm',
|
||||
instances => $instance,
|
||||
value => $fan_speed_value, min => 0
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -54,9 +54,12 @@ sub check {
|
|||
$self->{output}->output_add(severity => $exit,
|
||||
short_msg => sprintf("CPU Temperature is '%s' degree centigrade", $value));
|
||||
}
|
||||
$self->{output}->perfdata_add(label => 'temp_cpu', unit => 'C',
|
||||
value => $value
|
||||
);
|
||||
$self->{output}->perfdata_add(
|
||||
label => 'temp', unit => 'C',
|
||||
nlabel => 'hardware.temperature.celsius',
|
||||
instances => 'cpu',
|
||||
value => $value
|
||||
);
|
||||
}
|
||||
|
||||
my $system_temp = defined($self->{results}->{$oid_SystemTemperature_entry}->{$oid_SystemTemperature}) ?
|
||||
|
@ -71,9 +74,12 @@ sub check {
|
|||
$self->{output}->output_add(severity => $exit,
|
||||
short_msg => sprintf("System Temperature is '%s' degree centigrade", $value));
|
||||
}
|
||||
$self->{output}->perfdata_add(label => 'temp_system', unit => 'C',
|
||||
value => $value
|
||||
);
|
||||
$self->{output}->perfdata_add(
|
||||
label => 'temp', unit => 'C',
|
||||
nlabel => 'hardware.temperature.celsius',
|
||||
instances => 'system',
|
||||
value => $value
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue