Community discussions

MikroTik App
 
conchalnet
Member Candidate
Member Candidate
Topic Author
Posts: 274
Joined: Thu Nov 03, 2005 1:44 pm
Location: Brazil

QoS and Bandwidth limitation

Fri Jan 20, 2006 12:20 pm

Hi all,

I'm tring to do the QoS of same services and the bandwidth limitation.
The QoS I'm doing using mangle+queue tree and the bandwidth limitation I'm doing using the simples queues. But when I active the queue tree the traffic of my clients don't match the simple queue anymore.

The major doubt ie: can I use the simple queue and queue tree at same time??? The first do limit the maximum upload and download bandwidth for each client and the second to do the QoS control.

Below I show an example of configuration that I'm tring to use:

Mangle:
/ ip firewall mangle
add chain=prerouting protocol=tcp dst-port=5061 action=mark-connection new-connection-mark=VOIP_CON passthrough=yes \
comment="VoIP" disabled=no
add chain=prerouting protocol=udp dst-port=5061 action=mark-connection new-connection-mark=VOIP_CON passthrough=yes \
comment="" disabled=no
add chain=prerouting protocol=tcp dst-port=19000-20000 action=mark-connection new-connection-mark=VOIP_CON passthrough=yes \
comment="" disabled=no
add chain=prerouting protocol=udp dst-port=19000-20000 action=mark-connection new-connection-mark=VOIP_CON passthrough=yes \
comment="" disabled=no
add chain=prerouting connection-mark=VOIP_CON action=mark-packet new-packet-mark=ALTA passthrough=no comment="" \
disabled=no
add chain=prerouting protocol=udp dst-port=53 action=mark-connection new-connection-mark=DNS_CON passthrough=yes \
comment="DNS" disabled=no
add chain=prerouting protocol=udp dst-port=53 action=mark-packet new-packet-mark=ALTA passthrough=no comment="" \
disabled=no
add chain=prerouting protocol=tcp dst-port=80 action=mark-connection new-connection-mark=HTTP_CON passthrough=yes \
comment="HTTP" disabled=no
add chain=prerouting protocol=tcp dst-port=443 action=mark-connection new-connection-mark=HTTP_CON passthrough=yes \
comment="" disabled=no
add chain=prerouting protocol=tcp dst-port=8080 action=mark-connection new-connection-mark=HTTP_CON passthrough=yes \
comment="" disabled=no
add chain=prerouting connection-mark=HTTP_CON action=mark-packet new-packet-mark=ALTA passthrough=no comment="" \
disabled=no
add chain=prerouting protocol=tcp dst-port=1863 action=mark-connection new-connection-mark=MSN_CON passthrough=yes \
comment="MSN" disabled=no
add chain=prerouting protocol=tcp dst-port=1863 connection-mark=MSN_CON action=mark-packet new-packet-mark=MEDIA_ALTA \
passthrough=no comment="" disabled=no
add chain=prerouting p2p=all-p2p action=mark-connection new-connection-mark=P2P_CON passthrough=yes comment="P2P" \
disabled=no
add chain=prerouting connection-mark=P2P_CON action=mark-packet new-packet-mark=P2P passthrough=no comment="" disabled=no
add chain=prerouting action=mark-connection new-connection-mark=OUTROS_CON passthrough=yes comment="Restante do tr fego" \
disabled=no
add chain=prerouting connection-mark=OUTROS_CON action=mark-packet new-packet-mark=MEDIA_BAIXA passthrough=yes comment="" \
disabled=no

Queue tree
/ queue tree
add name="8-P2P" parent=global-out packet-mark=P2P limit-at=128000 queue=default priority=8 max-limit=512000 burst-limit=0 \
burst-threshold=0 burst-time=0s disabled=no
add name="1-Alta" parent=global-out packet-mark=ALTA limit-at=0 queue=default priority=1 max-limit=0 burst-limit=0 \
burst-threshold=0 burst-time=0s disabled=no
add name="3-M dia alta" parent=global-out packet-mark=MEDIA_ALTA limit-at=0 queue=default priority=3 max-limit=0 \
burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="5-M dia baixa" parent=global-out packet-mark=MEDIA_BAIXA limit-at=0 queue=default priority=5 max-limit=0 \
burst-limit=0 burst-threshold=0 burst-time=0s disabled=no
add name="7-Baixa" parent=global-out packet-mark=BAIXA limit-at=0 queue=default priority=7 max-limit=0 burst-limit=0 \
burst-threshold=0 burst-time=0s disabled=no

Simple queues (one for each client):
add name="Vinicius" target-addresses=200.YYY.XXX.99/32 dst-address=0.0.0.0/0 interface=all parent=none \
direction=both priority=1 queue=default/default limit-at=64000/300000 max-limit=64000/300000 total-queue=default \
disabled=no
add name="Ezequiel" target-addresses=200.YYY.XXX.79/32 dst-address=0.0.0.0/0 interface=all parent=none \
direction=both priority=1 queue=default/default limit-at=64000/300000 max-limit=64000/300000 total-queue=default \
disabled=no
add name="Leandro" target-addresses=200.YYY.XXX.102/32 dst-address=0.0.0.0/0 interface=all parent=none \
direction=both priority=1 queue=default/default limit-at=128000/400000 max-limit=128000/400000 total-queue=default \
disabled=no
add name="Supermercado" target-addresses=200.YYY.XXX.89/32 dst-address=0.0.0.0/0 interface=all parent=none \
direction=both priority=8 queue=default/default limit-at=130000/400000 max-limit=130000/400000 total-queue=default \
disabled=no
add name="Wanderleia" target-addresses=200.YYY.XXX.214/32 dst-address=0.0.0.0/0 interface=all parent=none \
direction=both priority=8 queue=default/default limit-at=128000/400000 max-limit=128000/400000 total-queue=default \
disabled=no

Why does the traffic just match only the queue tree and don't pass by the simple queue ???

Thanks
 
conchalnet
Member Candidate
Member Candidate
Topic Author
Posts: 274
Joined: Thu Nov 03, 2005 1:44 pm
Location: Brazil

Sat Jan 21, 2006 2:20 am

Can anyone help me with this???

I just want know if is it possible to use the queue tree with simple queue?

Queue tree - QoS
Simple queue - Bandwidth limitation

Thanks
 
User avatar
Hugh Hartman
Frequent Visitor
Frequent Visitor
Posts: 92
Joined: Fri May 28, 2004 2:01 pm
Location: Fort Kent, Maine

Sat Jan 21, 2006 1:27 pm

RouterOS applies the queue tree first, then the simple queue.
I QoS in queue tree and bandwidth limit/burst in simple queues
 
conchalnet
Member Candidate
Member Candidate
Topic Author
Posts: 274
Joined: Thu Nov 03, 2005 1:44 pm
Location: Brazil

Sat Jan 21, 2006 4:33 pm

Hi Hugh

Thanks for your reply but this doesn't occour here. If the traffic macth the queue tree the simple queue is don't used.

I'm using the global-out interface to do the QoS control in the Queue Tree, if I change the global-out to Public interface the simple queues are used but I don't know if the QoS is doing right.

Thanks again
 
User avatar
Hugh Hartman
Frequent Visitor
Frequent Visitor
Posts: 92
Joined: Fri May 28, 2004 2:01 pm
Location: Fort Kent, Maine

Sat Jan 21, 2006 7:14 pm

I use 2.8--so this may not apply:

I mangle the "whole pipe" using the local (in) and public (out) interfaces as the parent.---then this becomes the parent for all the traffic you are trying to shape:
I only use global-out for limiting P2P upload speeds on a per connection bases.