Return to Snippet

Revision: 66705
at June 22, 2014 22:44 by dbiesecke


Initial Code
#!/bin/sh

ping -c3 10.8.3.0 > pingreport
result=`grep "0 received" pingreport`
truncresult="`echo "$result" | sed 's/^\(.................................\).*$/\1/'`"
if [[ $truncresult == "3 packets transmitted, 0 received" ]]; then
pon company-vpn
fi

Initial URL

                                

Initial Description
make a cron like: 

   `*/5 *   * * *   root    bash /root/vpn-check.sh`

Initial Title
unix-cron-pptp-restart

Initial Tags
unix

Initial Language
Bash