I'd like to configure my RB4011 to handle dual Wan with automatic failover, but no luck.
I tried the following article: https://wiki.mikrotik.com/wiki/Advanced ... _Scripting
Here are the details:
ISP1: UPC (static address, DHCP)
ISP2: Telekom (static address, PPPoE)
And the related part of my config:
Code: Select all
/interface pppoe-client
add add-default-route=yes default-route-distance=2 disabled=no interface=ISP2-TELEKOM keepalive-timeout=disabled name=pppoe-telekom password=****** use-peer-dns=yes user=**********
/ip address
add address=10.0.0.1/16 interface=LAN-BRIDGE network=10.0.0.0
/ip dhcp-client
add default-route-distance=3 dhcp-options=hostname,clientid disabled=no interface=ISP1-UPC
/ip dhcp-server network
add address=10.0.0.0/16 dns-server=8.8.8.8 domain=8.8.4.4 gateway=10.0.0.1 netmask=16
/ip firewall nat
add action=masquerade chain=srcnat out-interface=ISP1-UPC src-address=10.0.0.0/16
add action=masquerade chain=srcnat out-interface=pppoe-telekom src-address=10.0.0.0/16
/ip route
add comment="Virtual Hop" distance=1 gateway=10.9.9.9 routing-mark=UPC scope=10
add comment="UPC > Quad9" distance=1 dst-address=9.9.9.9/32 gateway=ISP1-UPC scope=10
add comment="UPC -> OpenDNS" distance=1 dst-address=208.67.222.222/32 gateway=ISP1-UPC scope=10
add check-gateway=ping comment=Quad9 distance=1 dst-address=10.9.9.9/32 gateway=9.9.9.9 scope=10
add check-gateway=ping comment=OpenDNS distance=1 dst-address=10.9.9.9/32 gateway=208.67.222.222 scope=10