This commit is contained in:
2024-02-02 08:52:43 -06:00
parent 7eebe15dfa
commit d6c351c5a2
2 changed files with 2 additions and 2 deletions

View File

@@ -1,6 +1,6 @@
#!/usr/bin/env bash
VERS='2.5.238-02022024'
VERS='2.5.239-02022024'
noheader=' update service dailytemp confsync -r -report '

View File

@@ -1,5 +1,5 @@
GET_HOST_FANSPEED(){
if [ -f ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]} ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]})) -lt 600 ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]})) -lt $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]}.set)) ]; then
if [ -f ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]} ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]})) -lt 600 ] && ([ ! -f ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]}.set ] || [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]})) -lt $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]}.set)) ]); then
FanSpeed=$(cat ${PW_TMPFOLDER}/.lastfancheck/${PW_ESXI_HOST_NAMES[${1}]})
else
vHOSTFAN=$(ssh -q -o ConnectTimeout=3 -o ConnectionAttempts=1 root@${PW_RACADM_ACCESS} racadm -r ${PW_HOST_IDRACS[${PW_ESXI_HOST_NAMES[${1}]}]} -u ${PW_ESXI_USER} -p "'${PW_ESXI_PASS}'" getsensorinfo | grep "System Board Fan3" 2>&1)