Community discussions

MikroTik App
 
User avatar
azrael
just joined
Topic Author
Posts: 1
Joined: Wed Feb 14, 2018 11:02 am

Trasparent Traffic Shaper on bridge

Mon Mar 08, 2021 7:01 pm

Greetings, I need help in configuring trasparent traffic shaping on a bridged Mikrotik.
A client asked me to provide a traffic shaper for his network, so we installed a Mikrotik with all its interfaces in the same bridge; one of these interfaces is connected to the network gateway, and the others are connected to the client's LAN.
All the traffic from the LAN to its gateway will pass through the Mikrotik, but the Mikrotik has to be configured as a trasparent bridge and will not route anything.
The Mikrotik needs to prioritize the traffic towards a network (10.158.158.0/24) and limit everything towards the rest of the client's net (10.0.0.0/8) at 1Mb/s.
I've tried using some templates from this forum, but nothing works effectively.

This is the relevant configuration:
/interface bridge
add name=bridge1 protocol-mode=none
/queue simple
add max-limit=4M/4M name=main target=10.0.0.0/8
add limit-at=512k/512k max-limit=4M/4M name=voip packet-marks=voip parent=main priority=1/1 target=10.0.0.0/8
add max-limit=1M/1M name=besteffort packet-marks=besteffort parent=main target=10.0.0.0/8
/interface bridge port
add bridge=bridge1 interface=ether1
add bridge=bridge1 interface=ether2
add bridge=bridge1 interface=ether3
add bridge=bridge1 interface=ether4
add bridge=bridge1 interface=ether5
/interface bridge settings
set use-ip-firewall=yes
/ip firewall mangle
add action=mark-connection chain=forward dst-address=10.0.0.0/8 new-connection-mark=besteffort_conn passthrough=yes
add action=mark-packet chain=forward connection-mark=besteffort_conn new-packet-mark=besteffort passthrough=no
add action=mark-connection chain=forward dst-address=10.158.158.0/24 new-connection-mark=voip_conn passthrough=yes
add action=mark-packet chain=forward connection-mark=voip_conn new-packet-mark=voip passthrough=no
The mangle seems to be tagging packets from or towards the Mikrotik, but the rest of the LAN traffic isn't tracked in the firewall->connections section, and the queues won't limit anything.
Does anyone has any idea of how to make this work?
Thank you in advance.

Who is online

Users browsing this forum: baragoon, ips, kos, Laxity, zekino and 86 guests