X. WAN
ExpiredLoad Balancing
All Draytek routers that support simultaneous WAN connections support session based load balancing - this is designed to make the best use of multiple WAN connections by spreading the assignment of new sessions so that they are utilised evenly. It may be necessary to bypass this automatic load balancing if you want to split traffic so that for instance phones go through WAN1 while general data goes through WAN2, or an email server may only be allowed to send email through a specific WAN interface.
On some routers it is also possible to configure specific WANs to be exempt from the load balance pool which is useful in situations where you have a WAN that may not provide internet access but provides access to another internal network using a load balance policy.
Note: On later firmware (eg. 2830 3.6.4.1, 2860, 2925) Policy route replaces Load-Balance Policy http://www.draytek.co.uk/support/guides/kb-policy-routing-guide
Examples
Force all traffic from specified local IPs through a specific WAN
You can specify which WAN is used for internet access by specific network segments for instance if you have one IP range for phones and another for PCs by specifying the Source IP range in a load balance rule.
Go to [WAN] - [Load-Balance Policy], on that page, select an un-used Index # and set the rule as shown with this example forcing internet access from PCs in the 192.168.14.50 to 192.168.14.60 range to go through WAN2:
Access to specific IP goes through a specific WAN
You can specify which WAN is used to access a remote IP address by setting the Destination IP address in a load balance rule, this is useful for IP phones on a network where the phones may not be in a continuous IP range but they are all connecting to the same hosted PBX server.
Go to [WAN] - [Load-Balance Policy], on that page, select an un-used Index # and set the rule as shown with this example sending all traffic to the 88.64.123.64 IP address through WAN2:
Force SMTP traffic / specified ports through a specific WAN
SMTP traffic can be set up to send through a specific WAN connection only which is necessary with some mail server configurations. It can also be set so that it will not be allowed to send through the remaining WAN interfaces if the correct one should go down.
Go to [WAN] - [Load-Balance Policy], on that page, select an un-used Index # and set the rule as shown with this example sending SMTP traffic from the 192.168.14.254 server through WAN1 only. The "Auto failover to the other WAN" option is unticked so that if WAN1 stops working, the mail server will be unable to send through the remaining WAN interfaces:
Force HTTPS traffic to use WAN2 only
HTTPS sessions are more sensitive to load balancing than other internet connections, if you find that this is working less reliably once load balancing has been configured, you can set HTTPS connections to go through a specified WAN only.
Go to [WAN] - [Load-Balance Policy], on that page, select an un-used Index # and set the rule as shown with this example sending all HTTPS traffic through WAN2:
Configure default route - Dedicate a single WAN for internet access
When using load balancing, you may want to set up a single WAN to be used for internet access with specific traffic going over the other WAN only, the best way to set this up currently is to configure a default route for this main internet WAN and use load balance rules send traffic such as VoIP over the other WAN interface. This is accessible through telnet on the router with this command syntax:
ip route default wan1
sets WAN1 as the default route interface.
ip route default wan2
sets WAN2 as the default route interface
ip route default off
This disables the default route, the router will do load balancing again.
Remove WAN interface from Load Balance pool
Routers with 3.6.4 and later firmware can remove WAN connections from the load balance pool which is useful in scenarios where you want to have a WAN dedicated to a specific function such as VoIP or if the WAN connection does not route to the internet.
To remove a WAN connection from the load balance pool, go to [WAN] - [General Setup], on that page, go to the [Details Page] for the WAN interface that you want to remove from the load balance pool.
On the settings page, simply untick the Load Balance option and click OK. That WAN interface will no longer be part of the load balance pool and can then only be used for outbound connections if a load balance policy is set.
How do you rate this article?
- First Published: 18/03/2013
- Last Updated: 22/04/2021