Awesome job on the script!!! Trying the script now; the official release kept throwing these error:
Code:
Mar 22 10:53:00 wan-failover: Debug - failed to set WAN1GWIFNAME
Mar 22 10:53:00 wan-failover: Debug - failed to set WAN1GWIFNAME
I'm trying latest beta (2.0.1_beta4) currently and I'm no longer seeing the error above. While updating to the latest beta I did get the error message (last line) below:
Code:
admim@GT-AX11000-xxxx:/tmp/home/root# /jffs/scripts/wan-failover.sh update
***Dev Mode is Enabled***
wan-failover is out of date - Current Version: v2.0.0 Available Version: v2.0.1-beta4
Do you want to update to the latest beta version? v2.0.1-beta4 ***Enter Y for Yes or N for No***
> Y
wan-failover: Update - wan-failover has been updated to version: v2.0.1-beta4
wan-failover: Restart - Restarting wan-failover ***This can take up to approximately 1 minute***
wan-failover: Restart - Killing wan-failover Process ID: 17039
wan-failover: Restart - Killed wan-failover Process ID: 17039
wan-failover: Restart - Killing wan-failover Process ID: 8867335
kill: can't kill pid 8867335: No such process
wan-failover: Restart - ***Error*** Unable to kill wan-failover Process ID: 8867335
wan-failover: Restart - Killing wan-failover Process ID: 17040
wan-failover: Restart - Killed wan-failover Process ID: 17040
Cannot find device ""
wan-failover: Restart - Waiting for wan-failover to restart from Cron Job
wan-failover: Restart - Successfully Restarted wan-failover Process ID(s): 03867 8867335 03868 8867335
Successfully Restarted wan-failover Process ID(s): 03867,8867335,03868,8867335
/jffs/scripts/wan-failover.sh: line 6072: syntax error: unterminated quoted string
So far so good, no errors to report.
Code:
Mar 22 11:00:03 wan-failover: Debug - Log Level: 7
Mar 22 11:00:03 wan-failover: System Check - Process ID: 7448
Mar 22 11:00:03 wan-failover: System Check - Version: v2.0.1-beta4
Mar 22 11:00:03 wan-failover: System Check - Checksum: 663c9bbe627f0adbc262fa247cccdf5c9f77aa206767f327b09cf9bacdf998d8
Mar 22 11:00:03 wan-failover: Debug - Firmware: 388.1
Mar 22 11:00:03 wan-failover: System Check - IP Version: 5.11.0
Mar 22 11:00:03 wan-failover: Debug - JFFS custom scripts and configs: 1
Mar 22 11:00:03 wan-failover: Debug - Checking Alias in /jffs/configs/profile.add
Mar 22 11:00:03 wan-failover: Debug - Checking for Configuration File: /jffs/configs/wan-failover.conf
Mar 22 11:00:03 wan-failover: Debug - Function: update
Mar 22 11:00:03 wan-failover: wan-failover is up to date - Version: v2.0.1-beta4
Mar 22 11:00:03 wan-failover: Debug - Function: cleanup
Mar 22 11:00:03 wan-failover: Debug - Setting parameters for wan0
Mar 22 11:00:03 wan-failover: Debug - Checking wan0 for IP Rule to 8.8.8.8
Mar 22 11:00:03 wan-failover: Debug - Checking wan0 for Default Route in 100
Mar 22 11:00:03 wan-failover: Debug - Setting parameters for wan1
Mar 22 11:00:03 wan-failover: Debug - Checking wan1 for IP Rule to 8.8.4.4
Mar 22 11:00:03 wan-failover: Debug - Checking wan1 for Default Route in 200
Mar 22 11:00:03 wan-failover: Debug - Checking for Lock File: /var/lock/wan-failover.lock
Mar 22 11:00:03 wan-failover: Cleanup - Deleting /var/lock/wan-failover.lock
Mar 22 11:00:03 wan-failover: Cleanup - Deleted /var/lock/wan-failover.lock
Mar 22 11:00:03 wan-failover: Debug - Checking for /tmp/wan0packetloss.tmp
Mar 22 11:00:03 wan-failover: Debug - Checking for /tmp/wan1packetloss.tmp
For those running Fail-over mode, on the secondary ISP, are you guys disabling the NAT option or what's the recommended option (enabled by default)?