Manual:Queue Size: Difference between revisions

From MikroTik Wiki
Jump to navigation Jump to search
Megis (talk | contribs)
 
(10 intermediate revisions by 3 users not shown)
Line 1: Line 1:
{{Versions|2.9, v3, v4}}
__TOC__
__TOC__


Line 5: Line 7:
This example was created to highlight queue size impact on traffic that was queued by specific queue.  
This example was created to highlight queue size impact on traffic that was queued by specific queue.  


In Mikrotik RouterOS queue size can be specified in the "/queue type" menu. Each queue type have a different option for specifying queue size (pfifo-limit, bfifo-limit, pcq-limit, pcq-total-limit, red-limit), but all principles are the same - queue size is main option that decide should the package be drooped or scheduled for later time.
In Mikrotik RouterOS queue size can be specified in the "/queue type" menu. Each queue type have a different option for specifying queue size (pfifo-limit, bfifo-limit, pcq-limit, pcq-total-limit, red-limit), but all principles are the same - queue size is main option that decide should the package be dropped or scheduled for later time.


In real time environment this process is happening continuously without any stops, steps or other interruptions, but in order to show it as an example we will divide it into steps, where it is possible to know exactly how many packets will be received/transited in every step.
In real time environment this process is happening continuously without any stops, steps or other interruptions, but in order to show it as an example we will divide it into steps, where it is possible to know exactly how many packets will be received/transited in every step.
Line 27: Line 29:


==100% Scheduler==
==100% Scheduler==
Queue is 100% Scheduler when there is no packet drops at all, all packets are queued and will be sent out at the first possible moment.
In each step queue must send out queued packets from previous steps first and only then sent out packets from this step, this way it is possible to keep right sequence of packets.
We will again use same limit ('''100 packets per step''')


[[Image:Queue_size_Unlimited_Packets.PNG|700px|100% Scheduler]]
[[Image:Queue_size_Unlimited_Packets.PNG|700px|100% Scheduler]]
There was no packet loss, but 630 '''(39,1%) packets had 1 step delay''', and other 170 '''(10,6%) packets had 2 step delay'''. (delay = latency)


==Default-small queue type==
==Default-small queue type==
It is also possible to choose the middle way, when queue use both of these queuing aspects (shaping and scheduling)
By default most of the queues in RouterOS have queue size of 10.


[[Image:Queue_size_10_packets.PNG|700px|Default-small]]
[[Image:Queue_size_10_packets.PNG|700px|Default-small]]
There were 320 '''(19,9%) packets dropped''' and 80 '''(5,0%) packets had 1 step delay'''.


==Default queue type==
==Default queue type==
Other popular queue size in RouterOS is 50


[[Image:Queue_size_50_packets.PNG|700px|Default]]
[[Image:Queue_size_50_packets.PNG|700px|Default]]


[[Category:Manual]]
There were 190 '''(11,8%) packets dropped''' and 400 '''(24,8%) packets had 1 step delay'''.
 
[[Category:Manual|Queuessize]]
[[Category:QoS|Queuessize]]
[[Category:Case Studies|Queuessize]]

Latest revision as of 11:50, 14 April 2010

Applies to RouterOS: 2.9, v3, v4

Queue Size Example

This example was created to highlight queue size impact on traffic that was queued by specific queue.

In Mikrotik RouterOS queue size can be specified in the "/queue type" menu. Each queue type have a different option for specifying queue size (pfifo-limit, bfifo-limit, pcq-limit, pcq-total-limit, red-limit), but all principles are the same - queue size is main option that decide should the package be dropped or scheduled for later time.

In real time environment this process is happening continuously without any stops, steps or other interruptions, but in order to show it as an example we will divide it into steps, where it is possible to know exactly how many packets will be received/transited in every step.

We will not go into specific details of TCP and dropped packet retransmission - consider these packets as simple UDP stream.

Queue Size Example

As you can see in the picture above there are 25 steps and there are total of 1610 incoming packets over this time frame.

100% Shaper

Queue is 100% shaper when every packet that is over allowed limits will be dropped immediately. This way all packages that are not dropped will be sent out without any delay.

Lets apply max-limit=100 packets per step limitation to our example:

100% Shaper


With this type of limitation only 1250 out of 1610 packets were able to pass the queue (22,4% packet drop), but all packets arrive without delay.

100% Scheduler

Queue is 100% Scheduler when there is no packet drops at all, all packets are queued and will be sent out at the first possible moment.

In each step queue must send out queued packets from previous steps first and only then sent out packets from this step, this way it is possible to keep right sequence of packets.

We will again use same limit (100 packets per step)

100% Scheduler

There was no packet loss, but 630 (39,1%) packets had 1 step delay, and other 170 (10,6%) packets had 2 step delay. (delay = latency)

Default-small queue type

It is also possible to choose the middle way, when queue use both of these queuing aspects (shaping and scheduling) By default most of the queues in RouterOS have queue size of 10.


Default-small


There were 320 (19,9%) packets dropped and 80 (5,0%) packets had 1 step delay.

Default queue type

Other popular queue size in RouterOS is 50

Default

There were 190 (11,8%) packets dropped and 400 (24,8%) packets had 1 step delay.