Skip to content

Commit

Permalink
Correct performance data output
Browse files Browse the repository at this point in the history
See issue bytewriter#2, just added the trailing semicolon (it need to be always 4)
  • Loading branch information
KaliszAd authored Jan 27, 2020
1 parent dab51c0 commit d3fc931
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions check_common_ups
Original file line number Diff line number Diff line change
Expand Up @@ -448,9 +448,9 @@ if [[ $temp -gt $tempwarn ]];then
fi
fi

perfdata=";| Temp=$temp;$tempwarn;$tempcrit;0 Line_Voltage=$involtsdata;$inhigh;;$inlow Load=$load;$loadwarn;$loadcrit;0 RunTime=$runtime;$runwarn;$runcrit;0"
[[ $diagdata == "no" ]] || perfdata="$perfdata Diagnostic=${diagdays:-0};$diagwarn;$diagcrit;0"
[[ $calibdata == "no" ]] || perfdata="$perfdata Calibration=${calibdays:-0};$calibwarn;$calibcrit;0"
perfdata=";| Temp=$temp;$tempwarn;$tempcrit;0; Line_Voltage=$involtsdata;$inhigh;;$inlow; Load=$load;$loadwarn;$loadcrit;0; RunTime=$runtime;$runwarn;$runcrit;0;"
[[ $diagdata == "no" ]] || perfdata="$perfdata Diagnostic=${diagdays:-0};$diagwarn;$diagcrit;0;"
[[ $calibdata == "no" ]] || perfdata="$perfdata Calibration=${calibdays:-0};$calibwarn;$calibcrit;0;"
[[ -z $exitstring ]] && exitstring="OK"
exitstring="host: $upshostname: $upsvendorPrettyName ${upsmodel:-(Unknown Model)}: $exitstring$perfdata"
case $exitstatus in
Expand Down

0 comments on commit d3fc931

Please sign in to comment.