diff --git a/mm-scripts.sh b/mm-scripts.sh index f8c5169..b55648a 100755 --- a/mm-scripts.sh +++ b/mm-scripts.sh @@ -115,16 +115,12 @@ MMSTART(){ touch ${MMFOLDER}/mm.vpn.fail2 rm -f ${MMFOLDER}/mm.vpn.fail MMSTOP - sleep 5m - "${VPN_START[@]}" >/dev/null 2>&1 - sleep 10s - OUT=$(/sbin/ip link | grep "$VPN_INTERFACE") - if [ ${#OUT} = 0 ]; then - echo "$(date) - VPN Failure #2 - could not start system" >> $logfile - rm -f ${MMFOLDER}/mm.stop* - [ $VERBOSE = true ] && DEBUGLOGSTOP - exit 1 - fi + # sleep 2m + # "${VPN_START[@]}" >/dev/null 2>&1 + # sleep 10s + rm -f ${MMFOLDER}/mm.stop* + [ $VERBOSE = true ] && DEBUGLOGSTOP + exit 1 elif [ -f ${MMFOLDER}/mm.vpn.fail2 ]; then echo "$(date) - VPN Failure #3 - Shutting down Media Management systems" >> $logfile SENDNOTICE "VPN Failure" "Final Failure, shutting down system" 2 @@ -137,16 +133,12 @@ MMSTART(){ SENDNOTICE "VPN Failure" "1st Failure, will try and restart the VPN" 1 touch ${MMFOLDER}/mm.vpn.fail MMSTOP - sleep 10s - "${VPN_START[@]}" >/dev/null 2>&1 - sleep 10s - OUT=$(/sbin/ip link | grep "$VPN_INTERFACE") - if [ ${#OUT} = 0 ]; then - echo "$(date) - VPN Failure #1 - could not start vpn" >> $logfile - rm -f ${MMFOLDER}/mm.stop* - [ $VERBOSE = true ] && DEBUGLOGSTOP - exit 1 - fi + # sleep 10s + # "${VPN_START[@]}" >/dev/null 2>&1 + # sleep 10s + rm -f ${MMFOLDER}/mm.stop* + [ $VERBOSE = true ] && DEBUGLOGSTOP + exit 1 fi fi