Skip to content
Snippets Groups Projects
Commit 03ed3937 authored by Hahn Axel (hahn)'s avatar Hahn Axel (hahn)
Browse files

Merge branch '6092-check_eol-does-not-rotate-data' into 'master'

6092 check eol does not rotate data

See merge request !54
parents 0965e96c c2e0434d
No related branches found
No related tags found
1 merge request!546092 check eol does not rotate data
...@@ -48,6 +48,7 @@ ...@@ -48,6 +48,7 @@
# 2021-11-02 v1.3 <axel.hahn@iml.unibe.ch> detect centos stream # 2021-11-02 v1.3 <axel.hahn@iml.unibe.ch> detect centos stream
# 2022-02-28 v1.4 <axel.hahn@iml.unibe.ch> remove negative performance data # 2022-02-28 v1.4 <axel.hahn@iml.unibe.ch> remove negative performance data
# 2022-08-29 v1.5 <axel.hahn@iml.unibe.ch> fix help; shell syntax updates # 2022-08-29 v1.5 <axel.hahn@iml.unibe.ch> fix help; shell syntax updates
# 2023-01-30 v1.6 <axel.hahn@unibe.ch> add max value in performance data
# ====================================================================== # ======================================================================
. "$( dirname $0 )/inc_pluginfunctions" . "$( dirname $0 )/inc_pluginfunctions"
...@@ -261,8 +262,7 @@ else ...@@ -261,8 +262,7 @@ else
echo "Limit Info: warn below $iDaysWarn days; critical below $iDaysCritical days" echo "Limit Info: warn below $iDaysWarn days; critical below $iDaysCritical days"
test ${myDaysLeft} -lt 0 && myDaysLeft=0 test ${myDaysLeft} -lt 0 && myDaysLeft=0
ph.perfadd "$myKey-v$myEolVer" "${myDaysLeft}" $iDaysWarn $iDaysCritical 0 ph.perfadd "$myKey-v$myEolVer" "${myDaysLeft}" $iDaysWarn $iDaysCritical 0 100
fi fi
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
# 2020-09-01 v1.3 <axel.hahn@iml.unibe.ch> added ph.hasParamoption # 2020-09-01 v1.3 <axel.hahn@iml.unibe.ch> added ph.hasParamoption
# 2022-08-31 v1.4 <axel.hahn@iml.unibe.ch> shellfix corrections # 2022-08-31 v1.4 <axel.hahn@iml.unibe.ch> shellfix corrections
# 2022-10-25 v1.5 <axel.hahn@iml.unibe.ch> handle empty value in ph.perfadd # 2022-10-25 v1.5 <axel.hahn@iml.unibe.ch> handle empty value in ph.perfadd
# 2023-01-30 v1.6 <axel.hahn@unibe.ch> check performance params 5+6 and show a warning if missing
# ====================================================================== # ======================================================================
...@@ -439,7 +440,10 @@ function ph.perfadd(){ ...@@ -439,7 +440,10 @@ function ph.perfadd(){
local _max=$6 local _max=$6
test -z "$_value" && _value=0 test -z "$_value" && _value=0
test -z "$_min" && echo "WARNING from ph.perfadd: missing param 5 for minimum - setting it to 0"
test -z "$_min" && _min=0 test -z "$_min" && _min=0
test -z "$_max" && echo "WARNING from ph.perfadd: missing param 6 for maxiumun - setting it to 100"
test -z "$_max" && _max=100
echo "${_label}=${_value};${_w};${_c};${_min};${_max}" >>"${ph_perfdatafile}" echo "${_label}=${_value};${_w};${_c};${_min};${_max}" >>"${ph_perfdatafile}"
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment