Update temp.inc.sh
This commit is contained in:
@@ -57,11 +57,12 @@ CHECKTEMP(){
|
||||
vHOSTNAME=${PW_ESXI_HOST_NAMES[${vHOSTiDRACIP}]}
|
||||
|
||||
echo -en "\r\033[K${idsCL[White]}${idsST[Bold]}${SENSOR} Host Sensors ${idsST[Reset]}${idsCL[White]}[${vHOSTiDRACIP}]"
|
||||
if [ ! -f ${PW_TMPFOLDER}/${SENSOR}.down ] && [ "${SENSOR}" != "iDS-vMS-Host6xxx" ]; then
|
||||
if [ ! -f ${PW_TMPFOLDER}/${SENSOR}.down ]; then
|
||||
echo -en "${idsCL[LightCyan]} Getting FanSpeed..."
|
||||
RPM=$(snmpwalk -v 1 -c public -t 2 ${PW_HOST_IDRACS[${SENSORa}]} .1.3.6.1.4.1.674.10892.5.4.700.12.1.6.1.3 -O vq)
|
||||
[ ! -f ${PW_TMPFOLDER}/.fanspeed.${SENSOR} ] && until [ -f ${PW_TMPFOLDER}/.fanspeed.${SENSOR} ]; do tmp=tmp; done
|
||||
echo -en "\r\033[K${idsCL[White]}${idsST[Bold]}${SENSOR} Host Sensors ${idsST[Reset]}${idsCL[White]}[${vHOSTiDRACIP}]"
|
||||
echo -e "${idsCL[LightCyan]} [FanSpeed=$(cat ${PW_TMPFOLDER}/.fanspeed.${SENSOR})'%]${idsCL[Default]}"
|
||||
echo -e "${idsCL[LightCyan]} [FanSpeed=$(cat ${PW_TMPFOLDER}/.fanspeed.${SENSOR})'%,$(IDS_NUMBER_FORMAT ${RPM})'RPM]${idsCL[Default]}"
|
||||
else
|
||||
echo -e "${idsCL[Default]}"
|
||||
fi
|
||||
@@ -553,7 +554,6 @@ Previous Temp: ${last_temp}${GAUGESH}"
|
||||
####### Fan Issue Workaround #######
|
||||
if [ "${PW_SENSOR_TYPE[${SENSORa}]}" == "esxi" ] && [ ! -f ${PW_TMPFOLDER}/${SENSORa}.down ] && [ "${FanSpeed}" != "" ]; then
|
||||
if [ ! -f ${PW_TMPFOLDER}/.fancheck.${SENSORa} ] || [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.fancheck.${SENSORa})) -ge 300 ]; then
|
||||
# if [ ${FanSpeed} -lt 26 ] || [ ${FanSpeed} -gt 34 ]; then
|
||||
if [ ${FanSpeed} -ne 30 ]; then
|
||||
if [ "${PW_HOST_IDRACS[${SENSORa}]}" == "10.2.1.21" ] || [ "${PW_HOST_IDRACS[${SENSORa}]}" == "10.10.2.27" ] || [ "${PW_HOST_IDRACS[${SENSORa}]}" == "10.10.2.26" ]; then
|
||||
SENDNOTICE "${PW_HOST_IDRACS[${SENSORa}]} Fan Issue" "Settings fans back to normal 30%"
|
||||
|
||||
Reference in New Issue
Block a user