Uploaded by anchi.syam

Metode dan Skema Load balancing

advertisement
Metode dan Skema
Load Balanching
Administrasi Infrastruktur jaringan
Kelas 12 TKJ SMKN 1 Boalemo
Teori Dasar


Load balance pada mikrotik adalah teknik untuk
mendistribusikan beban trafik pada dua atau lebih jalur
koneksi secara seimbang, agar trafik dapat berjalan
optimal, memaksimalkan throughput, memperkecil waktu
tanggap dan menghindari overload pada salah satu jalur
koneksi.
Dalam penggunaan loadbalancing tidak seperti rumus
matematika 512 + 256 = 768, akan tetapi 512 + 256 =
512 + 256 artinya Bandwidth ke2 jalur tidak akan
digabung.
Contoh Skema Load Balanching
Metode Load Balanching
Method
Per-connection
Per-packet
Firewall marking
Yes
Yes
ECMP
Yes
No
PCC
Yes
No
Nth
Yes
Yes
Bonding
No
Yes
OSPF
Yes
No
BGP
Yes
No
Skema Metode ECMP
Metode ECMP









/ ip address
add address=192.168.0.1/24 network=192.168.0.0
broadcast=192.168.0.255 interface=Local
add address=10.111.0.2/24 network=10.111.0.0
broadcast=10.111.0.255 interface=wlan2
add address=10.112.0.2/24 network=10.112.0.0
broadcast=10.112.0.255 interface=wlan1
/ ip route
add dst-address=0.0.0.0/0 gateway=10.111.0.1,10.112.0.1 checkgateway=ping
/ ip firewall nat
add chain=srcnat out-interface=wlan1 action=masquerade
add chain=srcnat out-interface=wlan2 action=masquerade
Metode ECMP








/ ip firewall mangle
add chain=input in-interface=wlan1 action=mark-connection newconnection-mark=wlan1_conn
add chain=input in-interface=wlan2 action=mark-connection newconnection-mark=wlan2_conn
add chain=output connection-mark=wlan1_conn action=markrouting new-routing-mark=to_wla1
add chain=output connection-mark=wlan1_conn action=markrouting new-routing-mark=to_wla2
/ ip route
add dst-address=0.0.0.0/0 gateway=10.111.0.1 routingmark=to_wla1
add dst-address=0.0.0.0/0 gateway=10.112.0.1 routingmark=to_wla2
Skema Metode NTH
Metode NTH #1



















/ ip address
add address=192.168.0.1/24 network=192.168.0.0 broadcast=192.168.0.255 interface=Local
add address=10.111.0.2/24 network=10.111.0.0 broadcast=10.111.0.255 interface=wlan2
add address=10.112.0.2/24 network=10.112.0.0 broadcast=10.112.0.255 interface=wlan1
/ ip firewall mangle
add chain=prerouting src-address-list=odd in-interface=Local action=mark-connection \
new-connection-mark=odd passthrough=yes
add chain=prerouting src-address-list=odd in-interface=Local action=mark-routing \
new-routing-mark=odd passthrough=no
add chain=prerouting src-address-list=even in-interface=Local action=mark-connection \
new-connection-mark=even passthrough=yes
add chain=prerouting src-address-list=even in-interface=Local action=mark-routing \
new-routing-mark=even passthrough=no
add chain=prerouting in-interface=Local connection-state=new nth=2,1 \
action=mark-connection new-connection-mark=odd passthrough=yes
add chain=prerouting in-interface=Local action=add-src-to-address-list \
address-list=odd address-list-timeout=1d connection-mark=odd passthrough=yes
add chain=prerouting in-interface=Local connection-mark=odd action=mark-routing \
new-routing-mark=odd passthrough=no
Metode NTH #2













add chain=prerouting in-interface=Local connection-state=new nth=2,2 \
action=mark-connection new-connection-mark=even passthrough=yes
add chain=prerouting in-interface=Local action=add-src-to-address-list \
address-list=even address-list-timeout=1d connection-mark=even passthrough=yes
add chain=prerouting in-interface=Local connection-mark=even action=mark-routing \
new-routing-mark=even passthrough=no
/ ip firewall nat
add chain=srcnat out-interface=wlan1 action=masquerade
add chain=srcnat out-interface=wlan2 action=masquerade
/ ip route
add dst-address=0.0.0.0/0 gateway=10.111.0.1 scope=255 target-scope=10 routing-mark=odd
add dst-address=0.0.0.0/0 gateway=10.112.0.1 scope=255 target-scope=10 routingmark=even
add dst-address=0.0.0.0/0 gateway=10.112.0.1 scope=255 target-scope=10
Metode Firewall Marking : Load Balancing
Multiple Gateway
•Studi Kasus misalkan:
•Client 192.168.100.1-127 masuk
Group A melalui Jalur KUNING
•Client 192.168.100.128-253
masuk Group B melalui Jalur
Ungu
Metode Firewall Marking : Per-Trafic Load
Balanching




/ ip address
add address=192.168.100.1/24 network=192.168.100.0
broadcast=192.168.100.255 interface=Local
add address=10.1.0.1/24 network=10.1.0.0
broadcast=10.1.0.255 interface=wlan1
add address=10.5.8.1/24 network=10.5.8.0
broadcast=10.5.8.255 interface=wlan2
Metode Firewall Marking : Per-Trafic Load
Balanching
Metode Firewall Marking : Per-Trafic Load
Balanching
Metode Firewall Marking : Per-Trafic Load
Balanching
Metode Firewall Marking : Per-Trafic Load
Balanching
Download