Community discussions

MikroTik App
 
emielkuiper
just joined
Topic Author
Posts: 1
Joined: Thu Aug 25, 2011 5:42 pm

RouterOS, QinQ vlans and QoS

Thu Aug 25, 2011 6:09 pm

Hello,

currently I am using a routerBOARD 750 with version 4.11 and what I want to accomplish right now
is QoS on QinQ vlans.

Please take a look at the following interfaces:
[admin@mikrotik-01] /interface vlan> print 
Flags: X - disabled, R - running, S - slave 
 #    NAME                                         MTU   ARP        VLAN-ID INTERFACE                                        
 0 R  vlan10                                       1500  enabled    10      WAN-ether1                                       
 1 R  c-vlan70                                     1500  enabled    70      vlan10                                           
 2 R  c-vlan80                                     1500  enabled    80      vlan10   
 (…)

So, the physical port 1 is named "WAN-ether1". This interface has been used to serve as a parent for "vlan10".
The interface "vlan10" serves as a parent for two QinQ vlans: c-vlan70 and c-vlan80.

This all works as it should; packets are flowing.

(Please note that I am using VRF's here:
/ip route vrf
add comment="" disabled=no interfaces=LAN-DATA,c-vlan70 route-distinguisher=10:70 routing-mark=c-data
add comment="" disabled=no interfaces=LAN-VOIP,c-vlan80 route-distinguisher=10:80 routing-mark=c-voip)
However, when I want to apply a simple queue to this setup I get some unexpected results.

This setup, for example, does not work as expected:
[admin@mikrotik-01] /queue simple> print 
Flags: X - disabled, I - invalid, D - dynamic 
 0    ;;; MAIN-QUEUE_WAN
      name="main-queue" dst-address=0.0.0.0/0 interface=WAN-ether1 parent=none direction=both priority=1 
      queue=default-small/default-small limit-at=10M/10M max-limit=10M/10M burst-limit=0/0 burst-threshold=0/0 
      burst-time=0s/0s total-queue=default-small 

 1    ;;; CHILD-QUEUE_WAN-DATA
      name="data-child-queue" dst-address=0.0.0.0/0 interface=c-vlan70 parent=main-queue direction=both priority=8 
      queue=default-small/default-small limit-at=2M/2M max-limit=3M/3M burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s 
      total-queue=default-small 

 2    ;;; CHILD-QUEUE_WAN-VOIP
      name="voip-child-queue" dst-address=0.0.0.0/0 interface=c-vlan80 parent=main-queue direction=both priority=1 
      queue=default-small/default-small limit-at=5M/5M max-limit=5M/5M burst-limit=0/0 burst-threshold=0/0 burst-time=0s/0s 
      total-queue=default-small 

In this example I attached the main-queue to the interface WAN-ether1 as I expected that all packets
bound for the outside world would have to be processed by this interface.

I expected to be able to get at most 3 MB in the queue "data-child-queue".

However, QoS does not seem to kick in at all in this example.

Only when I set the 'interface' of MAIN-QUEUE_WAN to "all" or "c-vlan70" I indeed get 3 MB. This is not what
I expected.


Is there anybody who has expercience with both QinQ vlans and QoS on RouterOS?

I followed the packet flow as described in: http://wiki.mikrotik.com/wiki/Manual:Packet_Flow
but this does not seem to work this way when using nested vlan interfaces.


Any explanation regarding this subject is more then welcome.

Best regards,

Emiel
 
User avatar
macgaiver
Forum Guru
Forum Guru
Posts: 1764
Joined: Wed May 18, 2005 5:57 pm
Location: Sol III, Sol system, Sector 001, Alpha Quadrant

Re: RouterOS, QinQ vlans and QoS

Fri Aug 26, 2011 3:55 pm

Your problem is simple.

From Global-in and Global-out point of view there are no IP packets that are going out via WAN interface, QoS see traffic that are going out VLAN interfaces, fact that both are related are unknown.

So no traffic is captured by parent and child also doesn't see that traffic.
Don't forget that you work in Layer3, not Layer2.

Follow this setup:
1) mark both VLAN traffics in mangle chain forward
use mark-connection and then mark-packet upload and download separately
2) create small queue tree in Global-out - 1 parent and 2 childs
3) assign mangle marks to both childs,

Bottom line, for queue structures choose only queue tree.

Who is online

Users browsing this forum: Ahrefs [Bot], Bing [Bot], Mr47, Semrush [Bot] and 120 guests