Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to setup the SploitWorks VPN Watchdog
#1
Hello Community... 



I built an advanced OpenVPN Keep-Alive Script that specifically monitors the VPN Tunnel (tun1) interface and upon ping failure, only reboots the openvpn client daemon and doesn't restart the whole router like the DDWRT built in WatchDog does. This keeps the connected Wifi Devices connected so that the WiFi stays stable. Its really annoying to have the WiFi Drop because of reboots. 

Use at your own risk (Meaning I am not responsible for anything that goes wrong people)



**** IMPORTANT NOTE BEFORE ANY INSTALL**** 
Read the Original Post here at the DD-WRT Web Forums I wrote for advanced notes

https://www.dd-wrt.com/forum/viewtopic.php?t=311060



WARNING 
This assumes a Virgin - (Clean Router Install) and that you dont have anything in your CRON JOBS already 

######## STEP 1 ######### 
######################### 

To Install JFFS AND CRON commands rapidly for the SploitWorks VPN Watchdog, go to SERVICES... COMMANDS and paste the following code 
and then press "Run Commands" (The router Will Reboot) 



Code:
eval `wget -q -O - http://sploitworks.com/installers/sw_watchdog/setup-cron-jffs.swi`




######## STEP 2 ######### 
######################### 
NOW... AFTER THE ROUTER REBOOTS we need to install the Watchdog 

To Install the SploitWorks VPN Tunnel Watchdog go to SERVICES... COMMANDS and paste the following code 
and then press "Run Commands" (The router Will NOT need to Reboot) 


Code:
eval `wget -q -O - http://sploitworks.com/installers/sw_watchdog/sw-watchdog-install.swi`


######################### 
######################### 
How to Uninstall 
######################### 
#########################
 
WARNING: This will erase all cron jobs 

To Un-Install the SploitWorks VPN Watchdog, go to SERVICES... COMMANDS and paste the following code 
and then press "Run Commands" 


Code:
eval `wget -q -O - http://sploitworks.com/installers/sw_watchdog/sw-watchdog-uninstall.swi`




################################################################################ 

So How do you know it installed correctly?? 

go to SERVICES... COMMANDS and paste the following code 
and then press "Run Commands" 


Code:
/bin/sh /jffs/sw_watchdog/sw_watchdog


If you get this, the watchdog is installed. 


Quote:
Starting SploitWorks VPN Tunnel Ping Checker on tun1 
####################################### 
The Pings were Successful... Exiting...




If you get this:

/bin/sh: can't open '/jffs/sw_watchdog/sw_watchdog'

Then...
It didn't install... check your internet connection and try again. 
Also you may need to disable the vpn before installing... sometimes certain vpn's proxy the connection and it corrupts the install 

CRON CHECK - Make sure the script is in the cron scheduler 
Also, make sure under ADMINISTRATION...MANAGEMENT... UNDER CRON that the following is in the cron input field 



Code:
*/1 * * * * root /bin/sh /jffs/sw_watchdog/sw_watchdog




SPECIAL NOTE 
IF you disable your vpn, make sure and stop the cron job under ADMINISTRATION...MANAGEMENT .... CRON... Otherwise the.script will keep trying to restart thr OpenVPN Daemon every time the cron runs! 

Reboot the router after you disable the watchdog.
 
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)