Community discussions

MikroTik App
 
User avatar
stalin
just joined
Topic Author
Posts: 6
Joined: Sat Aug 02, 2014 1:58 pm

control download speed for specific file ext mikrotik ver6.x

Thu Aug 07, 2014 4:07 pm

In versions prior to version 6, we used to mark packets and create rule in queue tree to control traffic of sepcific file extensions like "MP4, EXE, MPEG, etc"
In version 6.x mikrotik introduced "global" parent in queue tree and removed "global-out" "global-in", and all previous configurations are not working.

Please i need to know step by step how to control download speed for any file extension "exe, mp4, mp3, etc." on versions 6.X
 
kozmonov
newbie
Posts: 34
Joined: Mon Dec 19, 2011 1:14 am

Re: control download speed for specific file ext mikrotik ve

Sat Aug 09, 2014 9:17 am

http://oranggantengoknet.wordpress.com/ ... -mikrotik/

Im terrible at Regular Expressions but there is probably a way to combine these REGEX into one L7 rule. Having a ton of Mangle/L7 Rules will give you a fairly large performance hit.
 
User avatar
stalin
just joined
Topic Author
Posts: 6
Joined: Sat Aug 02, 2014 1:58 pm

Re: control download speed for specific file ext mikrotik ve

Sat Aug 09, 2014 2:38 pm

Thank you kozmonov for replying, i have applied what is written in the link regarding marking packets for download, but when it comes to simple queues, this method dosent work on ver 6.x.

i will explain what i did exactly on version 6.17, knowing that i have edited some codes because they dont apply on this version:

Step1 (layer 7 defining file extension):
/ip firewall layer7-protocol
add comment=”” name=”Extension \” .exe \”” regexp=”^.*get.+\\.exe.*\$”

Step2 (Mangle rules):
/ip firewall mangle
add action=mark-connection chain=prerouting comment=”exe DOWNS” disabled=no layer7-protocol=”Extension \” .exe \”” new-connection-mark=”exe DOWNS” passthrough=yes protocol=tcp
add action=mark-packet chain=postrouting comment=”” connection-mark=”exe DOWNS” disabled=no new-packet-mark=exe passthrough=no protocol=tcp

Step3 "Adding simple queue for marked packets, but this will shape all traffic for all users, thats why i made it unlimited and created a child queue for specific IP":
/queue simple
add burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s comment=”” disabled=no limit-at=unlimited max-limit=unlimited name=”download max” packet-marks=exe parent=none priority=8 total-queue=default-small

Step4 (This is a script to generate all queues in one click, these queues should limit the download of the file extension .exe):
{
for i from=0 to=254 do={
queue simple add burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s comment=”” disabled=no limit-at=128k/128k max-limit=128k/128k name="172.16.22 network $i" parent=”download max” priority=”8” target=”172.16.22.$i” total-queue=”default-small”
}}

what is happening, is that all traffic is shaped and not only exe
 
User avatar
stalin
just joined
Topic Author
Posts: 6
Joined: Sat Aug 02, 2014 1:58 pm

Re: control download speed for specific file ext mikrotik ve

Tue Aug 12, 2014 10:39 pm

Please I need a solution, anyone can help??? :( :( :(
Simple Queue configuration for specific file extension (.exe, .mp4, .mov, etc.) in Mikrotik version 6.x, board ccr-1036.

Who is online

Users browsing this forum: No registered users and 78 guests