Update offsite-power-check.sh

This commit is contained in:
2023-11-05 22:01:26 -06:00
parent 51024e99bf
commit 77707161e6

View File

@@ -26,7 +26,6 @@ fi
PWO_START(){
startup=true
while true; do
start=`date +%s`
upsinfo=$(upsc CP1500PFCLCD)
if [ "$(echo "${upsinfo}" | grep 'input.voltage:' | sed 's/.*: //')" != "" ]; then
OFFSITE_VOLTIN=$(echo "${upsinfo}" | grep 'input.voltage:' | sed 's/.*: //')
@@ -100,7 +99,6 @@ PWO_START(){
/usr/local/etc/rc.d/nut.sh restart
sleep 10s
fi
end=`date +%s`; runtime=$((end-start)); echo -e "\nruntime: ${runtime}\nsleeping for 5secs ... "
sleep 5s
done
}