-->

Breaking

logo

Wednesday, March 9, 2016

Setting 2 ISP Load Balancing

Setting 2 ISP Load Balancing

gambar 1.1 - load balancing 2 isp

Configure the proxy load balancing 2 isp 
Internet access for a cafe or office use two ISPs, for example under the interface used on the proxy router is ether1, ether2, and ether3 as follows:

/ip address
add address=192.168.80.1/24 network=192.168.80.0 broadcast=192.168.80.255 interface=Ether3-lan 
add address=103.12.9.2/24 network=103.12.9.0 broadcast=103.12.9.255 interface=ether1-wan
add address=103.55.9.2/24 network=103.55.9.0 broadcast=103.55.9.255 interface=ether2-wan
add a rule for failover
/ip route
add dst-address=0.0.0.0/0 gateway=103.12.9.1,103.55.9.1 check-gateway=ping 
Routing has been made, we just need to set src-address for all outgoing packets. if this packet will leave through WAN1 will go to 103.12.9.2/24, if through WAN2 then go to 103.55.9.2/24
/ip firewall nat 
add chain=srcnat out-interface=ether2-wan action=masquerade
add chain=srcnat out-interface=ether1-wan action=masquerade
mark his package in mangle
/ip firewall mangle
add chain=input in-interface=ether2-wan action=mark-connection new-connection-mark=ether2-wan_conn
add chain=input in-interface=ether1-wan action=mark-connection new-connection-mark=ether1-wan_conn
add chain=output connection-mark=ether2-wan_conn action=mark-routing new-routing-mark=to_wan1     
add chain=output connection-mark=ether2-wan_conn action=mark-routing new-routing-mark=to_wan2
then add the default route in your mikrotik
/ip route
add dst-address=0.0.0.0/0 gateway=103.12.9.1 routing-mark=to_wan1 
add dst-address=0.0.0.0/0 gateway=103.55.9.1 routing-mark=to_wan2
thus setting an example of load balancing 2 isp, the above example is only an illustration, taken from the source:
http://wiki.mikrotik.com

Disclaimer: Images, articles or videos that exist on the web sometimes come from various sources of other media. Copyright is fully owned by the source. If there is a problem with this matter, you can contact