What's new

WANFailover Dual WAN Failover ***v2 Release***

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

***v2.0.5-beta2 Release***
v2.0.5-beta2 - 06/04/2023
Fixes:
- Corrected minor issue when retrieving WAN NVRAM Parameters
- Corrected issue if WAN Failover would be stuck in a continuous loop if a router didn't have WAN USB capability.
- Corrected issue that causes WAN Failover to exit in Load Balance mode during failover events.
 
I am glad to see this script continuing to progress, even though I am not running any Asus products at this time.

Great work @Ranger802004 !
 
I know, off topic but, I decided to revisit Untangle now a product of Arista,

I have a 30 day trial but so far it looks even better than I remember it and now it supports the AES-NI capabilities of my little mini pc. The older versions did not even though pfSense was able to utilize it.

The main reason for it’s support is my fulltime VPN for my wife’s MLB viewing.

The old eero Pro units in Bridge mode are working great also.

This setup may be a “keeper” but you know how I am. :)
 
This may be a silly question but how to you enable dual WAN while disabling factory failover? When I enable dual WAN I can select failover or load balance. There is no other option.

I see how I can disable fallback by unchecked the box.

Per the Readme requirements.
"ASUS Factory Failover Disabled (Network Monitoring Options, Allow Failback Option under WAN > Dual WAN)"

I want to make sure I'm set up correctly before running this script.
 

Attachments

  • Screenshot_20230604_224520_Chrome.jpg
    Screenshot_20230604_224520_Chrome.jpg
    128.9 KB · Views: 77
This may be a silly question but how to you enable dual WAN while disabling factory failover? When I enable dual WAN I can select failover or load balance. There is no other option.

I see how I can disable fallback by unchecked the box.

Per the Readme requirements.
"ASUS Factory Failover Disabled (Network Monitoring Options, Allow Failback Option under WAN > Dual WAN)"

I want to make sure I'm set up correctly before running this script.
The readme will tell you to make sure options under Network Monitoring are unchecked.
 
This may be a silly question but how to you enable dual WAN while disabling factory failover? When I enable dual WAN I can select failover or load balance. There is no other option.

I see how I can disable fallback by unchecked the box.

Per the Readme requirements.
"ASUS Factory Failover Disabled (Network Monitoring Options, Allow Failback Option under WAN > Dual WAN)"

I want to make sure I'm set up correctly before running this script.
I think it is meant to say the "failback" option should be disabled (unticked) rather than "failover".
 
@Ranger802004
My installer is getting stuck "getting system settings" is there something special that I need to do to move past this prompt?
I need debug logs to determine what is going on
 
Does this work?
Yes, it’s failing to set DDNS name, I believe I had logic in place to handle that being null but I will verify later today and get back to you. In short term you can configure DDNS and it should get past that message.

EDIT:
Do you have DDNS enabled but the DDNS Hostname field blank?
 
Last edited:
Hi Again, I've installed v2.0.5-beta2 and I have been testing.

Test 1 - Unplug LAN cable from ASUS Router (eth1)
=============================
When I unplug the LAN cable I can see when checking the Routing Table that the routes get removed and my computer fails over to the WAN interface.

When I re-connect the cable the Routes are re-created and I fail back to the eth1 connection as expected.

Test 2 - Unplug feed connection from Modem - Leaving LAN connected to ASUS Router
=========================================================
This is where things don't work as expected. When checking SYSLOG I can see that its tried to delete the default route, but when I check the Routing Table its still there

Jun 5 18:54:32 wan-failover: Debug - WAN1 Status: DISCONNECTED

Jun 5 18:54:32 wan-failover: Load Balance Monitor - Removed nexthop via x.x.188.193 dev eth1 weight 1

I also see that it thinks its removing the DNS server entries from the Routing Table but again they are still there.

Jun 5 18:54:35 wan-failover: DNS Switch - Removing wan1 DNS1 Server: x.x.158.238
Jun 5 18:54:35 wan-failover: DNS Switch - Removed wan1 DNS1 Server: x.x.158.238
Jun 5 18:54:35 wan-failover: DNS Switch - Removing wan1 DNS2 Server: x.x.171.84
Jun 5 18:54:35 wan-failover: DNS Switch - Removed wan1 DNS2 Server: x.x.171.84

If I try a machine that's configured to use the eth1 link its not able to access the internet.

If needed I can provide send you the logs.
 
Yes, it’s failing to set DDNS name, I believe I had logic in place to handle that being null but I will verify later today and get back to you. In short term you can configure DDNS and it should get past that message.

EDIT:
Do you have DDNS enabled but the DDNS Hostname field blank?
Thank you, I was able to get it installed!

In my first functional test I pulled my primary WAN cable and the code failed over like a charm. Unfortunately it did not fail back to primary after reconnecting. I went and pulled some logs, I see the error below repeating. Wondering if this is the cause of the tailback fail.

I need to do more robust functional testing tonight.

Please note, that I did not change your default ping targets of 8.8.8.8 and 8.8.4.4 or www.google.com

Any thoughts?

Jun 5 15:35:37 wan-failover: Check Routing Table - ***Error*** Unable to add default route to Target IP: www.google.com for wan0 Routing Table via 73.1.x.x dev eth5
Jun 5 15:35:37 wan-failover: Debug - Setting parameters for wan1
Jun 5 15:35:38 wan-failover: Debug - Checking wan1 for null IP or Gateway
Jun 5 15:35:38 wan-failover: Debug - Checking wan1 for Default Route in 200
Jun 5 15:35:38 wan-failover: Debug - Checking wan1 for route to Target IP: 8.8.4.4 for wan1 Routing Table via 100.x.x.x dev eth0
Jun 5 15:35:38 wan-failover: Debug - Recursive Ping Check: 1
Jun 5 15:35:38 wan-failover: Debug - Checking wan0 for IP Rule to www.google.com
Jun 5 15:35:38 wan-failover: WAN Status - Adding IP Rule for www.google.com to monitor wan0
Jun 5 15:35:38 wan-failover: WAN Status - ***Error*** Unable to add IP Rule for www.google.com to monitor wan0
 

Attachments

  • IMG_0102.jpeg
    IMG_0102.jpeg
    27.8 KB · Views: 47
Thank you, I was able to get it installed!

In my first functional test I pulled my primary WAN cable and the code failed over like a charm. Unfortunately it did not fail back to primary after reconnecting. I went and pulled some logs, I see the error below repeating. Wondering if this is the cause of the tailback fail.

I need to do more robust functional testing tonight.

Please note, that I did not change your default ping targets of 8.8.8.8 and 8.8.4.4 or www.google.com

Any thoughts?

Jun 5 15:35:37 wan-failover: Check Routing Table - ***Error*** Unable to add default route to Target IP: www.google.com for wan0 Routing Table via 73.1.x.x dev eth5
Jun 5 15:35:37 wan-failover: Debug - Setting parameters for wan1
Jun 5 15:35:38 wan-failover: Debug - Checking wan1 for null IP or Gateway
Jun 5 15:35:38 wan-failover: Debug - Checking wan1 for Default Route in 200
Jun 5 15:35:38 wan-failover: Debug - Checking wan1 for route to Target IP: 8.8.4.4 for wan1 Routing Table via 100.x.x.x dev eth0
Jun 5 15:35:38 wan-failover: Debug - Recursive Ping Check: 1
Jun 5 15:35:38 wan-failover: Debug - Checking wan0 for IP Rule to www.google.com
Jun 5 15:35:38 wan-failover: WAN Status - Adding IP Rule for www.google.com to monitor wan0
Jun 5 15:35:38 wan-failover: WAN Status - ***Error*** Unable to add IP Rule for www.google.com to monitor wan0
Did you set www.google.com as your monitor target manually via config file? It has to be an IP Address.
 
No, I didn't set anything manually. So I need to use the configuration to change that?
Ahhhh I know what happened, it pulled that from your existing monitoring configuration during install, go ahead and modify your configuration manually to correct this back to an IP Address. such as 8.8.8.8. I'll have to add logic in the installation to only use that if the existing setting is an IP Address and not a domain.
 
Last edited:
***v2.0.5-beta3 Release***
v2.0.5-beta3 - 06/05/2023
Fixes:
- Corrected minor issue when retrieving WAN NVRAM Parameters
- Corrected issue if WAN Failover would be stuck in a continuous loop if a router didn't have WAN USB capability.
- Corrected issue that causes WAN Failover to exit in Load Balance mode during failover events.
- Corrected issue where DDNS Hostname being blank would cause the script to hang in a loop while collecting System Settings.
- Corrected issue during install where the existing monitor target value was a domain and being used as the WAN0 Target IP default value.
 
Ahhhh I know what happened, it pulled that from your existing monitoring configuration during install, go ahead and modify your configuration manually to correct this back to an IP Address. such as 8.8.8.8. I'll have to add logic in the installation to only use that if the existing setting is an IP Address and not a domain.
I updated manually and the error is gone! Thank you for all of your help. You are so quick to reapond.

I did some functional testing and I have the same experience as @ColinJOnes.

Failover works flawlessly when I physically pull the ethernet cable on the primary WAN.

However if I keep my modem connected with ethernet and disconnect the coax to the modem to simulate an outage failover does not occur.
 
Hi Again, I've installed v2.0.5-beta2 and I have been testing.

Test 1 - Unplug LAN cable from ASUS Router (eth1)
=============================
When I unplug the LAN cable I can see when checking the Routing Table that the routes get removed and my computer fails over to the WAN interface.

When I re-connect the cable the Routes are re-created and I fail back to the eth1 connection as expected.

Test 2 - Unplug feed connection from Modem - Leaving LAN connected to ASUS Router
=========================================================
This is where things don't work as expected. When checking SYSLOG I can see that its tried to delete the default route, but when I check the Routing Table its still there

Jun 5 18:54:32 wan-failover: Debug - WAN1 Status: DISCONNECTED

Jun 5 18:54:32 wan-failover: Load Balance Monitor - Removed nexthop via x.x.188.193 dev eth1 weight 1

I also see that it thinks its removing the DNS server entries from the Routing Table but again they are still there.

Jun 5 18:54:35 wan-failover: DNS Switch - Removing wan1 DNS1 Server: x.x.158.238
Jun 5 18:54:35 wan-failover: DNS Switch - Removed wan1 DNS1 Server: x.x.158.238
Jun 5 18:54:35 wan-failover: DNS Switch - Removing wan1 DNS2 Server: x.x.171.84
Jun 5 18:54:35 wan-failover: DNS Switch - Removed wan1 DNS2 Server: x.x.171.84

If I try a machine that's configured to use the eth1 link its not able to access the internet.

If needed I can provide send you the logs.
Yes please collect debug logs, as far as DNS, it is editing the dnsmasq file for the router on which DNS servers to use.
 
I updated manually and the error is gone! Thank you for all of your help. You are so quick to reapond.

I did some functional testing and I have the same experience as @ColinJOnes.

Failover works flawlessly when I physically pull the ethernet cable on the primary WAN.

However if I keep my modem connected with ethernet and disconnect the coax to the modem to simulate an outage failover does not occur.
Collect debug logs for me please.
 

Similar threads

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!
Top