This commit is contained in:
2023-12-05 23:11:36 -06:00
parent 08212ce67f
commit fdbf2f3eff
5 changed files with 4 additions and 37 deletions

View File

@@ -132,7 +132,6 @@ STATUS(){
########################
for NTYPE in "${ntypesel[@]}"; do
nid=1
dockers=${NTYPE}_DOCKERS_CHECK[@]
hosts=${NTYPE}_HOSTS[@]
@@ -451,7 +450,6 @@ STATUS(){
fi
[ "${ST_ACTION}" != "check" ] && echo
nid=`expr $nid + 1`
done
fi #GOFORCHECK
@@ -624,7 +622,6 @@ It was down for $(SHOW_TIME ${toterrtime})"
echo -e "${idsCL[Yellow]} ${NM_NODETYPES[$NTYPE]}-Node(s) Free Space Scan${idsCL[Default]}"
DIVIDER; echo -e "${idsST[Reset]}"
fi
nid=1
var=${NTYPE}_HOSTS[@]
for nip in "${!var}"; do
if [[ $"{RNIP}" == *"${nip}"* ]]; then NCMD=''; LH='- localhost'
@@ -721,7 +718,6 @@ It was down for $(SHOW_TIME ${toterrtime})"
# fi
# done
nid=`expr $nid + 1`
echo
done
done
@@ -769,25 +765,24 @@ REPLCHECK(){
}
STATUS_SCANTIMES(){
scandefault=200
while [ $# -gt 0 ]; do
case "${1}" in
-l|-last) LAST=${2};;
-h|-help|--help)
echo -e "Usage: ${idsCL[Yellow]}[nodemgmt or nmg] scantimes {opt}${idsCL[Default]} {"
width=15
printf "%-${width}s- %s\n" " -l|-last" "(number of last scantimes to average from, defaults to 480)"
printf "%-${width}s- %s\n" " -l|-last" "(number of last scan times to average from, defaults to ${scandefault})"
echo -e "}\n"
exit 0;;
esac
shift
done
[ "${LAST}" == "" ] && LAST=200
[ "${LAST}" == "" ] && LAST=${scandefault}
echo -en "${idsCL[Yellow]}Pulling data and calculating average scan times for the last '${LAST}' scans ... "
lastscantime=$(tail -n 1 ${NM_LOGFOLDER}/status-check.scantimes)
scantimes=($(tail -n ${LAST} ${NM_LOGFOLDER}/status-check.scantimes))
scantimes_total=0; scansfound=0
for scantime in "${scantimes[@]}"; do