ada pembahasan sebelumnya Load Balancing Dual WAN dengan menggunakan Mikrotik 3.0 maka di kesempatan ini Pakirwan mencoba memposting Load Balancing Mikrotik dengan menggunakan RB750 yang memiliki 5 port router. PCC disini maksudnya per-connection-classifier

yang terdapat pada RB750 dengan asumsi sebagai berikut:


2 port yang terhubung dengan dua Router DSL yang berbeda,
dan 1 port terhubung dengan LAN.
Kedua DSL memiliki kecepatan yang sama.

Local = 192.168.0.1
Modem1 = 192.168.1.1
Modem2 = 192.168.2.1

Jangan lupa untuk merubah nama-nama dari setiap interface nya.
Berikut ini adalah script yang Sobat bisa kopi paste kan diterminal mikrotiknya.

/ip address
add address=192.168.0.1/24 network=192.168.0.0 broadcast=192.168.0.255 interface=Local
add address=192.168.1.2/24 network=192.168.1.0 broadcast=192.168.1.255 interface=Modem1
add address=192.168.2.2/24 network=192.168.2.0 broadcast=192.168.2.255 interface=Modem2

/ip dns set allow-remote-requests=yes cache-max-ttl=1w cache-size=5000KiB max-udp-packet-size=512 servers=221.132.112.8,8.8.8.8

/ip firewall mangle
add chain=input in-interface=Modem1 action=mark-connection new-connection-mark=Modem1_conn
add chain=input in-interface=Modem2 action=mark-connection new-connection-mark=Modem2_conn

add chain=output connection-mark=Modem1_conn action=mark-routing new-routing-mark=to_Modem1
add chain=output connection-mark=Modem2_conn action=mark-routing new-routing-mark=to_Modem2

add chain=prerouting dst-address=192.168.1.0/24 action=accept in-interface=Local
add chain=prerouting dst-address=192.168.2.0/24 action=accept in-interface=Local

add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/0 action=mark-connection new-connection-mark=Modem1_conn passthrough=yes
add chain=prerouting dst-address-type=!local in-interface=Local per-connection-classifier=both-addresses-and-ports:2/1 action=mark-connection new-connection-mark=Modem2_conn passthrough=yes

add chain=prerouting connection-mark=Modem1_conn in-interface=Local action=mark-routing new-routing-mark=to_Modem1
add chain=prerouting connection-mark=Modem2_conn in-interface=Local action=mark-routing new-routing-mark=to_Modem2

/ip route
add dst-address=0.0.0.0/0 gateway=192.168.1.1 routing-mark=to_Modem1 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.2.1 routing-mark=to_Modem2 check-gateway=ping

add dst-address=0.0.0.0/0 gateway=192.168.1.1 distance=1 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.2.1 distance=2 check-gateway=ping

/ip firewall nat
add chain=srcnat out-interface=Modem1 action=masquerade
add chain=srcnat out-interface=Modem2 action=masquerade

 Copyright stekom.ac.id 2018 All Right Reserved