Update dsmon.sh
This commit is contained in:
10
dsmon.sh
10
dsmon.sh
@@ -106,9 +106,9 @@ CHECK(){
|
|||||||
for hostname in "${hostnames_sort[@]}"; do
|
for hostname in "${hostnames_sort[@]}"; do
|
||||||
hostid=${host_ids[$hostname]}
|
hostid=${host_ids[$hostname]}
|
||||||
if [ "${1}" != "report" ]; then
|
if [ "${1}" != "report" ]; then
|
||||||
echo -e "${idsST[Bold]}"; DIVIDER false lightCyan 100
|
echo -e "${idsST[Bold]}"; DIVIDER false lightCyan 90
|
||||||
echo -e "${idsCL[LightCyan]} ${host_name[$hostid]} - Drive Space Check${idsCL[Default]}"
|
echo -e "${idsCL[LightCyan]} ${host_name[$hostid]} - Drive Space Check${idsCL[Default]}"
|
||||||
DIVIDER false lightCyan 100
|
DIVIDER false lightCyan 90
|
||||||
fi
|
fi
|
||||||
|
|
||||||
checkhost=$(CHECK_HOST ${host_ip[$hostid]})
|
checkhost=$(CHECK_HOST ${host_ip[$hostid]})
|
||||||
@@ -171,7 +171,7 @@ CHECK(){
|
|||||||
# echo
|
# echo
|
||||||
|
|
||||||
if [ "${1}" != "report" ]; then
|
if [ "${1}" != "report" ]; then
|
||||||
c=0; cw=40; spcA=''
|
c=0; cw=30; spcA=''
|
||||||
spc1=`expr ${cw} - 5`
|
spc1=`expr ${cw} - 5`
|
||||||
until [ $c = ${spc1} ]; do spcA="${spcA} "; c=`expr $c + 1`; done
|
until [ $c = ${spc1} ]; do spcA="${spcA} "; c=`expr $c + 1`; done
|
||||||
c=0; cw=10; spcB=''
|
c=0; cw=10; spcB=''
|
||||||
@@ -196,8 +196,8 @@ CHECK(){
|
|||||||
CRITICAL_LEVEL=$(printf "%0.2f" $(jq -n $WARNING_LEVEL-$WARNING_LEVEL/2))
|
CRITICAL_LEVEL=$(printf "%0.2f" $(jq -n $WARNING_LEVEL-$WARNING_LEVEL/2))
|
||||||
|
|
||||||
if [ "${1}" != "report" ]; then
|
if [ "${1}" != "report" ]; then
|
||||||
c=0; cw=40; spcA=''
|
c=0; cw=30; spcA=''
|
||||||
spc1=`expr ${cw} - ${#DRIVE}`
|
spc1=`expr ${cw} - ${#DRIVEINFO_SHORTNAME[$DRIVE]}`
|
||||||
until [ $c = ${spc1} ]; do spcA="${spcA} "; c=`expr $c + 1`; done
|
until [ $c = ${spc1} ]; do spcA="${spcA} "; c=`expr $c + 1`; done
|
||||||
c=0; cw=10; spcB=''
|
c=0; cw=10; spcB=''
|
||||||
spc2=`expr ${cw} - ${#DRIVEINFO_FREE[$DRIVE]}`
|
spc2=`expr ${cw} - ${#DRIVEINFO_FREE[$DRIVE]}`
|
||||||
|
|||||||
Reference in New Issue
Block a user