Setup guide

queues (known as classless queues) are attached to the main (attached to the root, which represent
real interface) Hierarchical Token Bucket (HTB) and thus have some properties derived from that
parent queue. With classful queues it is possible to deploy hierarchical queue trees. For example,
we can set a maximum data rate for a workgroup and then distribute that amount of traffic between
the members of that group as we can do with simple queues attached to the main HTB, but with
upper limit.
Each queue represents a virtual interface with the allowed data rate. It can be borrowed from sibling
queues (queues that are children of one queue) when max-limit is greater than limit-at. If so, the
queue would use over the allocated data rate whenever possible. Only when other queues are getting
too long and a connection is not to be satisfied, then the borrowing queues would be limited at their
allocated data rate.
When a parent is allowed to send some amount of traffic, it asks its inner queues in order of
priority (priorities are processed one after another, from 1 to 8, where 1 means the highest priority).
When a queue reaches its limit-at value, its priority is not to be taken in account, such a queue will
be less-prioritative than the ones not reached this limit.
Information Rates and Contention Ratios
Quality of Service (QoS) means that router should prioritize and shape network traffic. QoS is not
so much about limiting, it is more about providing quality. The main terms used to describe the
level of QoS for network applications are:
CIR (Committed Information Rate) - the guaranteed data rate. It means that traffic not
exceeding this rate should always be delivered
MIR (Maximal Information Rate) - the maximal data rate router will provide
Contention Ratio - the ratio to which the defined data rate is shared between users (i.e., data
rate is allocated to a number of subscribers). For example, the contention ratio of 1:4 means
that the allocated data rate may be shared between no more than 4 users
Priority - the order of importance in what traffic will be processed. You can give priority to
some traffic in order it to be handeled before some other traffic.
Wandy RouterOS may be used to provide CIR and MIR with some contention level and priority.
Here we will talk in terms of queues (which represent either real or virtual interface) and classes
(children of a queue; each class has an another queue attached to it):
limit-at property is used to specify CIR. If the queue will be able to provide that data rate, it
will (i.e, the parent queue (and the link the router is connected to) should be able to provide the
total data rate equal or greater that the sum of all CIRs the queue should satisfy in order to
quarantee these CIRs). CIRs will be satisfied in order of their priority.
max-limit property is used to specify MIR. If the queue has satisfied all the CIRs and it is able
to provide some additional data rate, it will try to distribute that additional data rate between all
its classes regardless of their priorities and not exceeding their MIRs.
• Filters in RouterOS are very powerful and flexible. Providing Contention Ratio is only one
application of what they can do. Using firewall mangle you can mark some a number of hosts
with a flow-mark, so the data rate allocated for that mark will be shared between these hosts.
Virtual Interfaces
In addition to real interfaces, there are two vitrual interfaces you can attach tree queues to:
global-out - represents all the output interfaces in general. Queues attached to it applies before
the ones attached to a specific interface.