EdgeRouter WAN
Dual WAN
Settings Overview:
load-balance { group <name> { interface <name> { route { default table <name> } weight <number> failover-only route-test { type { default ping { target <host> } script <name> } initial-delay <number> interval <number> count { success <number> failure <number> } } } } }
Load Balancing
minimal config:
ubnt@ER-Pro# show load-balance group WLB { interface eth0 { } interface eth1 { } } ubnt@ER-Pro# show firewall modify modify WAN_WLB { rule 10 { action modify modify { lb-group WLB } } } ubnt@ER-Pro# show interfaces ethernet eth2 description LAN address 192.168.16.1/24 firewall { in { modify WAN_WLB } }
WAN Failover
For a more detailed look at dual WAN, but only use WAN2 for failover. Let's assume:
eth0 | WAN1 | primary |
---|---|---|
eth1 | WAN2 | backup |
eth2 | LAN | internal |
First create the load-balance group with eth1 as failover-only:
configure set load-balance group WAN_FAILOVER interface eth0 set load-balance group WAN_FAILOVER interface eth1 failover-only commit ubnt@ubnt# show load-balance group WAN_FAILOVER { interface eth0 { } interface eth1 { failover-only } } [edit]
Then create the policy the the LAN interfaces will use:
set firewall modify WAN_POLICY rule 10 action modify set firewall modify WAN_POLICY rule 10 modify lb-group WAN_FAILOVER commit ubnt@ubnt# show firewall modify modify WAN_POLICY { rule 10 { action modify modify { lb-group WAN_FAILOVER } } } [edit]
Then apply to the LAN interface(s):
set interfaces ethernet eth2 description LAN set interfaces ethernet eth2 firewall in modify WAN_POLICY commit save exit
(Source: Re: 802.3ad failover)
PPPoE
set interfaces ethernet eth1 pppoe 0 user-id joe set interfaces ethernet eth1 pppoe 0 password secret2 connect interface pppoe0 disconnect interface pppoe0
(Source: PPPoE Client - CLI Commands)
Troubleshooting
PPPoE gets IP, but no route
It's possible that the default route is still active. The PPPoE route can be forced on connecting with the following setting:
set interfaces ethernet eth2 pppoe 0 default-route force