Load Balancing Via Mikrotik

Conditions: ISP where we work as Administrator to use more than one gateway to connect to the Internet. Everything must be able to serve the upstream and downstream services. Because the case would be different if one of them can only serve downstream, for example when using One-way VSAT DVB.
For this case let's say the ISP has two paths to the Internet. One using DSL access (256 Kbps) and the other using the Wireless (512 Kbps). DSL usage ratio: Wireless = 1:2.
To be performed:
A. Using all the available gateway channels with load-balancing techniques.
2. Make one of them as back-up with fail-over techniques.
OK, let's just get started experiments:
A. IP address for access to the LAN:
> / Ip address add address = 192.168.0.1/28 interface = LAN
IP address for access to DSL lines:
> / Ip address add address = 10.32.57.253/29 interface = DSL
IP address for access to a Wireless:
> / Ip address add address = 10.9.8.2/29 interface = WIRELESS
Specify the gateway and the ratio of each:
> / Ip route add gateway = 10.32.57.254,10.9.8.1,10.9.8.1
2. In the case of fail-over technique. Assumed to be the main route through Wireless with DSL lines as a back-up if the main line can not be passed. To check whether the main line can be passed or not, use the ping command.
> / Ip firewall mangle add chain = prerouting src-address = 192.168.0.0/28 action = mark-routing new-routing-mark = SUBNET1-RM
> / Ip route add gateway = 10.9.8.1 routing-mark = SUBNET1-RM check-gateway = ping
> / Ip route add gateway = 10.32.57.254
3. Good Luck!

================================================== =====================================
use a mikrotik jg seem able to "load balancing" stay put 3 interface,
A to Speedy1 interface, such as IP 192.168.1.1
B for Speedy2 interface, such as IP 192.168.2.1
C interface to the LAN, such as IP 10.10.10.0/24

config in mikrotik like this:
> / Ip address add address = 10.10.10.0/24 interface = LAN
IP address for SpeedyA:
> / Ip address add address = 192.168.1.1/32 interface = SpeedyA
IP address for SpeedyB:
> / Ip address add address = 192.168.2.1/32 interface = SpeedyB
Next we specify the gateway to the priority:
> / Ip route add gateway = 192.168.1.1,192.168.2.1,192.168.2.1
Can also add the config for failover, for example one of the main jd some speedy death can directly use the speedy track of them,
> / Ip firewall mangle add chain = prerouting src-address = 10.10.10.0/24 action = mark-routing new-routing-mark = RM-SPEEDY
> / Ip route add gateway = 192.168.2.1 routing-mark = rm-speedyB check-gateway = ping
> / Ip route add gateway = 192.168.1.1

Or other alternative dg is, we divide the traffic into two lanes speedy is based on our LAN network group,
We are setting the IP in each "interface mikrotik,
/ Ip address add address 192.168.1.1/32 interface speedyA
/ Ip address add address 192.168.2.1/32 interface speedyB
/ Ip address add address 10.10.10.1/24 LAN interface
Next we try to network into 2 Group
add chain = prerouting action = mark-connection src-address 10.10.10.0/25 new-routing-mark = Group-A
add chain = prerouting action = mark-connection new 10.10.10.128/25 src-address-routing-mark = Group-B
then we set the default gateway of each group
/ Ip route add gateway = 192.168.1.1 routing-mark = Group-A
/ Ip route add gateway = 192.168.2.1 routing-mark = Group-B
Also make sure we've NAT settings on our network
/ Ip firewall nat add chain = src-address srcnat 10.10.10.0/24 action = masquerade
================================================== ==============================
Using a 3 etrernet card
ether1 ==> wireless
ether2 ==> speedy
ethet3 ==> Lan
mikrotik command:
/ Ip address add address 202.152.74.1/32 interface ether1
/ Ip address add address 192.168.1.2/32 interface ether2
/ Ip address add address 192.168.10.1/24 interface ether3
Divide into 2 Ip Group
add chain = prerouting action = mark-connection src-address 192.168.10.0/25 new-routing-mark = Group-A
add chain = prerouting action = mark-connection src-address 192.168.10.128/25 new-routing-mark = Group-B
Each default gw Group
Group-A = 192.168.10.0/25 default gw 192.168.1.1
Group-B = default gw 202.152.74.128 192.168.10.128/25
mikrotik command:
/ Ip route add gateway = 192.168.1.1 routing-mark = Group-A
/ Ip route add gateway = 202.152.74.128 routing-mark = Group-B
Local ip nat
192.168.10.0/24 ==> masquerade
mikrotik command:
/ Ip firewall nat add chain = src-address srcnat 192.168.10.0/24 action = masquerade
================================================== ================================
ip route add dst-address = 0.0.0.0 / 0 gateway = 192.168.1.1 gateway = ping check-
ip route add dst-address = 0.0.0.0 / 0 gateway = 10.0.148.254 check-gateway = ping
Where 192.168.1.1 ADSL router & gateway 10.0.148.254 RT / RW-net pake only 2.4GHz dah just like that anyway ..
pake ping gateway checks so that the gateway down
Direct switch. If ya down directly on two at once, rich does load balancing
I just happen to add the parameters in the gateway distance = 2 RT / RW-net can be a lower priority ..
Firewall / NAT makes two seeds for each gateway
for easy client
add a default route IP-ether-mikrotik
PC / Router which I operate existing mikrotik 3 LAN card
2 to the ADSL modem, 1 to the LAN
clients are directed to the Ethernet LAN gateway aja mikrotik
Good luck and Best wishes .... ...
Title : Load Balancing Via Mikrotik
Description : Conditions: ISP where we work as Administrator to use more than one gateway to connect to the Internet. Everything must be able to serve t...

0 Response to "Load Balancing Via Mikrotik"

Posting Komentar