Fix stupid errors in generate_sensors_ini

tags/zabbix-agent-addons-0.2.20-1
Daniel Berteaud 9 years ago
parent 9a0d53a805
commit c5bf918c51
  1. 7
      zabbix_scripts/util_generate_sensors_ini

@ -38,7 +38,7 @@ GetOptions(
"pwr-margin=i" => \$pwr_margin, "pwr-margin=i" => \$pwr_margin,
"temp-hyst=i" => \$temp_hyst, "temp-hyst=i" => \$temp_hyst,
"temp-hd-hyst=i" => \$temp_hd_hyst, "temp-hd-hyst=i" => \$temp_hd_hyst,
"temp-ups-hyst=i" => \$temp_hyst_hyst, "temp-ups-hyst=i" => \$temp_ups_hyst,
"pwr-hyst=i" => \$pwr_hyst "pwr-hyst=i" => \$pwr_hyst
); );
@ -262,8 +262,8 @@ if ($upsc && -x $upsc){
my $sensor = { my $sensor = {
description => "ups temperature", description => "ups temperature",
type => 'temp', type => 'temp',
threshold_high => $def_temp_threshold_high, threshold_high => $def_temp_thres_high,
threshold_low => $def_temp_threshold_high-$temp_ups_hyst, threshold_low => $def_temp_thres_high-$temp_ups_hyst,
unit => '°C', unit => '°C',
cmd => "$upsc $ups ups.temperature" cmd => "$upsc $ups ups.temperature"
}; };
@ -271,7 +271,6 @@ if ($upsc && -x $upsc){
} }
} }
} }
}
# TODO: add support for lm sensors, but its ouput is harder to parse # TODO: add support for lm sensors, but its ouput is harder to parse
foreach my $s (keys %$sensors){ foreach my $s (keys %$sensors){

Loading…
Cancel
Save