Community discussions

MikroTik App
 
Chrisszzyy
just joined
Topic Author
Posts: 7
Joined: Thu Sep 07, 2017 3:57 pm

CHR Locking Up when under load (Load Balancing)

Fri Feb 23, 2018 3:26 pm

Hi guys,

So recently, I've tried building a RouterOS Virtual Machine (Hyper-V virtualized) which can make use of our two internet connections at work.

Now for some reason, when performing an external speedtest (or any download) which makes use of the load balancing, the router will completely freeze for 2-3 seconds, then unfreeze and then freeze again.etc until the test is over.

The router stops responding to pings on its WAN interfaces and LAN interface.

If I try and make a transfer from a computer on its LAN interface from a PC on the WAN network (So it passes through the router), I can quite happily get 1Gbps speeds with no problem (or lock up).

It only seems to be when the load balancing occurs.

Does anyone know what could be causing this behavior? If there was a problem with the load balancing config, I'd still expect to be able to ping the router from the LAN interface.

I've checked and the CPU is not reaching anywhere near 100%; neither is the RAM.

Config:
# IP Addresses for reference purpose
/ip address
add address=192.168.60.254/24 network=192.168.60.0 broadcast=192.168.60.255 interface=Local
add address=192.168.10.174/24 network=192.168.10.0 broadcast=192.168.10.255 interface=WAN1
add address=192.168.50.174/24 network=192.168.20.0 broadcast=192.168.50.255 interface=WAN2

/ip firewall address-list
add address=192.168.0.1-192.168.0.255 list=allowed_users

# Accept Connections
/ip firewall mangle
add action=accept chain=prerouting in-interface=WAN1
add action=accept chain=prerouting in-interface=WAN2
 
# Mangle Section
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=WAN1_conn passthrough=yes src-address-list=allowed_users
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=WAN2_conn passthrough=yes src-address-list=allowed_users
 
# Marking Routing Marks to be used by ROUTES Section
add chain=prerouting connection-mark=WAN1_conn in-interface=Local action=mark-routing new-routing-mark=to_WAN1
add chain=prerouting connection-mark=WAN2_conn in-interface=Local action=mark-routing new-routing-mark=to_WAN2

# Adding ROUTE for marked routes (done by mangle earlier)
/ip route
add dst-address=0.0.0.0/0 gateway=192.168.10.254 routing-mark=to_WAN1 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.50.254 routing-mark=to_WAN2 check-gateway=ping

# DEFAULT ROUTES, OR Fail over routes , just incase in any router goes offline, then these default routes as per distance, will be used as default
add dst-address=0.0.0.0/0 gateway=192.168.10.254 distance=1 check-gateway=ping
add dst-address=0.0.0.0/0 gateway=192.168.50.254 distance=2 check-gateway=ping

# NAT/MASQUERADE the requests going on each interface (used by ROUTES)
/ip firewall nat
add chain=srcnat out-interface=WAN1 action=masquerade src-address-list=allowed_users
add chain=srcnat out-interface=WAN2 action=masquerade src-address-list=allowed_users
 
jarda
Forum Guru
Forum Guru
Posts: 7756
Joined: Mon Oct 22, 2012 4:46 pm

Re: CHR Locking Up when under load (Load Balancing)

Sat Feb 24, 2018 10:47 am

Aren't you using 1mbit per port limited testing license? If yes, obtain unlimited testing license and try again.

Who is online

Users browsing this forum: No registered users and 12 guests