Community discussions

MikroTik App
 
ktw-matt
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 97
Joined: Fri Mar 03, 2006 8:32 pm
Location: USA

Queue Tree & Simple Queues (How?)

Tue Aug 15, 2006 10:06 pm

Hey guys.

I have some mangle rules + queue trees setup so that I can equalize traffic, in both directions, with a max-limit of something like 11M.

It works... but this stops my dynamic (radius-added) and static simple queues from working.

Is there a way to have both?
 
Stryker777
Frequent Visitor
Frequent Visitor
Posts: 71
Joined: Fri Jul 07, 2006 11:40 pm
Contact:

Wed Aug 16, 2006 6:07 am

Are you using global out as your parent? If so, then it queues all output on all interfaces and your other queues dont really mean anything. If you do it based on output interface, it takes time to add the trees for every device, but you can control it well.
 
ktw-matt
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 97
Joined: Fri Mar 03, 2006 8:32 pm
Location: USA

Thu Aug 17, 2006 6:16 pm

Oh.. yeah, we're using global-in and global-out.

So would I be able to specify the actual interface for my in and out mangle/queue trees? If I understood you right.

Edit: Because my queue trees didn't seem to work when I placed them on the interface. Well, I'll try it out.
 
ktw-matt
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 97
Joined: Fri Mar 03, 2006 8:32 pm
Location: USA

Thu Aug 17, 2006 6:40 pm

Ok, when I set the parents of my queue trees to their interface, only the "out" trees work.

Here's a setup on one of our routers.

Mangle Rules:
/ ip firewall mangle 
add chain=prerouting in-interface=ether1 action=mark-packet \
    new-packet-mark=in-ether1 passthrough=no comment="" disabled=no 
add chain=postrouting out-interface=ether1 action=mark-packet \
    new-packet-mark=out-ether1 passthrough=no comment="" disabled=no 
add chain=prerouting in-interface=ether2 action=mark-packet \
    new-packet-mark=in-ether2 passthrough=no comment="" disabled=no 
add chain=postrouting out-interface=ether2 action=mark-packet \
    new-packet-mark=out-ether2 passthrough=no comment="" disabled=no
Queue Trees (max-limit=10M):
/ queue tree 
add name="in-ether1" parent=ether1 packet-mark=in-ether1 limit-at=0 \
    queue=pcq-dst priority=8 max-limit=10000000 burst-limit=0 \
    burst-threshold=0 burst-time=0s disabled=no 
add name="out-ether1" parent=ether1 packet-mark=out-ether1 limit-at=0 \
    queue=pcq-src priority=8 max-limit=10000000 burst-limit=0 \
    burst-threshold=0 burst-time=0s disabled=no 
add name="in-ether2" parent=ether2 packet-mark=in-ether2 limit-at=0 \
    queue=pcq-dst priority=8 max-limit=10000000 burst-limit=0 \
    burst-threshold=0 burst-time=0s disabled=no 
add name="out-ether2" parent=ether2 packet-mark=out-ether2 limit-at=0 \
    queue=pcq-src priority=8 max-limit=10000000 burst-limit=0 \
    burst-threshold=0 burst-time=0s disabled=no
 
Ozelo
Member
Member
Posts: 338
Joined: Fri Jun 02, 2006 3:56 am

Thu Aug 17, 2006 8:07 pm

You cant control incoming packets where you mark them just after they arrived, they already arrived. Also, about using simple queues + queue trees, just pay attention to the HTB´s in order (global-in, global-total, global-out and finally, the interface queue).
MTCRE - 1104RE006
MTCINE - 1104INE001
 
ktw-matt
Frequent Visitor
Frequent Visitor
Topic Author
Posts: 97
Joined: Fri Mar 03, 2006 8:32 pm
Location: USA

Thu Aug 17, 2006 11:28 pm

I just read back over that part of the manual and it does make sense.

Let me see if I've got it right this time:
/ ip firewall mangle 
add chain=forward out-interface=ether1 action=mark-packet \
    new-packet-mark=ether1 passthrough=yes comment="" disabled=no 
add chain=forward out-interface=ether2 action=mark-packet \
    new-packet-mark=ether2 passthrough=yes comment="" disabled=no

/ queue tree 
add name="ether1-DL" parent=ether1 packet-mark=ether1 limit-at=0 queue=pcq-src \
    priority=8 max-limit=2000000 burst-limit=0 burst-threshold=0 burst-time=0s \
    disabled=no 
add name="ether2-UL" parent=ether2 packet-mark=ether2 limit-at=0 queue=pcq-dst \
    priority=8 max-limit=512000 burst-limit=0 burst-threshold=0 burst-time=0s \
    disabled=no
Also, with this setup on another router, both my simple queues and these queue trees seem to work now.

Edit: In the above code, ether1 is local and ether2 is public.

Who is online

Users browsing this forum: arvan214, bandini981, CoUL, fcucci, Google [Bot], Guscht, timotei, Zacharias and 160 guests