update
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
VERS='2.7.6-04222024'
|
VERS='2.7.7-04222024'
|
||||||
|
|
||||||
noheader=' update service dailytemp confsync -r -report '
|
noheader=' update service dailytemp confsync -r -report '
|
||||||
|
|
||||||
|
|||||||
@@ -1008,17 +1008,18 @@ Previous Temp: ${last_temp}${GAUGESH}"
|
|||||||
# fi
|
# fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
#### TRACKING TEMP CHANGES
|
||||||
if [ "${temp_f}" != "" ] && [[ "${SENSOR}" != *"CPU-Usage"* ]] && [[ "${SENSOR}" != *"FAN"* ]]; then
|
if [ "${temp_f}" != "" ] && [[ "${SENSOR}" != *"CPU-Usage"* ]] && [[ "${SENSOR}" != *"FAN"* ]]; then
|
||||||
if [ ! -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre ]; then
|
if [ ! -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre ]; then
|
||||||
echo "${temp_f}" > ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre
|
echo "${temp_f}" > ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre
|
||||||
|
|
||||||
elif ([ ! -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre)) -ge 1800 ]) || ([ -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old)) -ge 1800 ]); then
|
elif ([ ! -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre)) -ge 1800 ]) || ([ -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old ] && [ $(expr `date +%s` - $(stat -c %Y ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old)) -ge 1800 ]); then
|
||||||
mv ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old 2> /dev/null
|
[ -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old ] && mv -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old2
|
||||||
|
mv -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.old
|
||||||
|
sleep 1s
|
||||||
echo "${temp_f}" > ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre
|
echo "${temp_f}" > ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.pre
|
||||||
|
|
||||||
fi
|
fi
|
||||||
else
|
|
||||||
rm -f ${PW_TMPFOLDER}/.lastinsert/${SENSOR}.*
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
#### LOGGING OF SERVERROOM SENSOR DIFFERENCE
|
#### LOGGING OF SERVERROOM SENSOR DIFFERENCE
|
||||||
|
|||||||
Reference in New Issue
Block a user