3 WAN ISPs and 2 LAN DHCP SERVERS

Hi,

I would like to know what is the best way to implement the following network:

3 WAN ISPs: ISP1, ISP2, ISP3 where ISP3 is a failover from ISP1 only (all ISPs with static IP address)

2 LAN DHCP Servers: DHCP1 and DHCP2 where all the traffic from DHCP1 goes through ISP1 (or ISP3 on failover) and all the traffic from DHCP2 goes through ISP2.

Winbox should work on ISP1 IP and ISP2 IP.

Thanks

I think your setup will be similar like below. It will be more efficient if you use Layer2 protocol like Spanning-Tree (STP).

/ip address add address=1.1.1.2/29 interface=ether1 comment=ISP1
/ip address add address=1.1.1.3/29 interface=ether2 comment=ISP2
/ip address add address=2.2.2.2/29 interface=ether3 comment=ISP3
/ip address add address=192.168.1.0/24 interface=ether4 comment=LAN1
/ip address add address=192.168.2.0/24 interface=ether5 comment=LAN2

/ip firewall mangle add chain=prerouting src-address=192.168.2.0/24 action=mark-routing new-routing-mark=WAN2

/ip firewall nat add chain=srcnat src-address=192.168.1.0/24 out-interface=ether1 action=masquerade
/ip firewall nat add chain=srcnat src-address=192.168.1.0/24 out-interface=ether2 action=masquerade
/ip firewall nat add chain=srcnat src-address=192.168.2.0/24 action=src-nat to-address=2.2.2.2

/ip pool add name=pool1 ranges=192.168.1.2-192.168.1.254
/ip pool add name=pool2 ranges=192.168.2.2-192.168.2.254

/ip dhcp-server network add address=192.168.1.0/24 comment="Network1" dns-server=192.168.1.1 gateway=192.168.1.1
/ip dhcp-server add address-pool=pool1 interface=ether4 name=DHCP1
/ip dhcp-server network add address=192.168.2.0/24 comment="Network2" dns-server=192.168.2.1 gateway=192.168.2.1
/ip dhcp-server add address-pool=pool2 interface=ether5 name=DHCP2

/ip route add dst-address=0.0.0.0/0 gateway=ether1 distance=1
/ip route add dst-address=0.0.0.0/0 gateway=ether2 distance=2
/ip route add dst-address=0.0.0.0/0 gateway=2.2.2.1 distance=1 routing-mark=WAN2