Community discussions

MikroTik App
 
mducharme
Trainer
Trainer
Topic Author
Posts: 1019
Joined: Tue Jul 19, 2016 6:45 pm

MPLS/VPLS and HTB / EXP bits

Wed Aug 17, 2016 6:47 pm

We have a chain of Mikrotiks in a test lab, with VPLS and MPLS-TE tunnels.

MKT1 <--> MKT2 <--> MKT3 <--> MKT4

We have a TE tunnel and VPLS tunnel connecting MKT3 to MKT1, and the same connecting MKT4 to MKT1. On MKT4, we are using a bridge filter to set the priority for all packets entering the tunnel to MKT1 as priority 7. We have no filter on MKT3 since they should be experimental bits at that point, and the tunnel from MKT3 to MKT1 should not be prioritized.

To simulate congestion, on MKT3's interface that connects to MKT2, we implemented a queue tree with a 20Mbps limit, matching no-mark. It matches all packets and shapes to 20Mbps. However, it seems to ignore the MPLS EXP bits set by MKT4 and gives the traffic the same priority as the MKT3 traffic.

NOTE: To test this, we have a UDP packet generator on MKT4 sending to an IP of a computer plugged into the VPLS tunnel endpoint at MKT1. We have a similar UDP packet generator on MKT3 sending to the same computer. The rate of the UDP packet generator on MKT4 is the bare minimum packets per second required to create a 5Mbps rate (the guaranteed rate for the customer), but have UDP packets going through MKT3 with a much higher rate (30 or 40 Mbps). We can see the rate that packets are arriving at the tunnel endpoint at MKT1. When we start the traffic generator on MKT3, the traffic from MKT4 drops down from 5Mbps to 4.2. Disabling the traffic generator causes the MKT4 tunnel traffic to return to the customer guaranteed 5Mbps. If we try disabling and enabling the bridge filter on MKT4 that applies the priority to the packets, it has no impact on the 4.2 value, which suggests that the MPLS experimental bits are either not being set or not being honored.

I'm not sure whether this is caused by the HTB not recognizing that the EXP bits should have priority, or whether the EXP bits are not getting applied properly from the beginning.

Any ideas?
 
leviton
just joined
Posts: 2
Joined: Wed Aug 17, 2016 8:58 pm

Re: MPLS/VPLS and HTB / EXP bits

Wed Aug 17, 2016 9:00 pm

This is good topic! I like it!
 
mducharme
Trainer
Trainer
Topic Author
Posts: 1019
Joined: Tue Jul 19, 2016 6:45 pm

Re: MPLS/VPLS and HTB / EXP bits

Fri Aug 19, 2016 9:28 am

I believe I have found a successful method of marking mpls frames which works in the queue tree.

On MKT3's interface that receives data from MKT4 I created a bridge. I made that bridge the ldp and mpls TE interface. I applied a bridge filter on that router that takes packets with ingress priority 7 and applies a mark. That mark then works on the queue tree on the port going to mkt2 and seems to work. I will do more testing tomorrow.
 
mducharme
Trainer
Trainer
Topic Author
Posts: 1019
Joined: Tue Jul 19, 2016 6:45 pm

Re: MPLS/VPLS and HTB / EXP bits

Sun Aug 21, 2016 9:51 pm

Yes, I have confirmed that it works. This provides a method for QoS with MPLS/VPLS, and allows marking of MPLS frames for use in queue trees. The last post was slightly incorrect. It is actually quite simple:

- Both VPLS tunnel endpoints should be connected to bridges
- A bridge filter should be set up on the 'forward' chain, to 'set priority' to a value 0-7 that you want the MPLS experimental bits to be set to.

On other routers where you have congested links (ex wireless), set up a queue tree on either side of the link that shapes to the link's maximum. Then, do the following to properly mark the MPLS packets for use in your queue tree:
- At the egress interface that has your queue tree set up, create a bridge that includes only that interface
- Add a bridge filter for chain 'output' that matches 'ingress priority' equal to the value that you had assigned on the endpoints (i.e. the experimental bit values)
- Set the action to 'mark packet'

The queue tree will now properly classify the MPLS packet in the queue and properly do QoS.
 
User avatar
shaoranrch
Member Candidate
Member Candidate
Posts: 184
Joined: Thu Feb 13, 2014 8:03 pm

Re: RE: Re: MPLS/VPLS and HTB / EXP bits

Sun Aug 21, 2016 11:02 pm

Yes, I have confirmed that it works. This provides a method for QoS with MPLS/VPLS, and allows marking of MPLS frames for use in queue trees. The last post was slightly incorrect. It is actually quite simple:

- Both VPLS tunnel endpoints should be connected to bridges
- A bridge filter should be set up on the 'forward' chain, to 'set priority' to a value 0-7 that you want the MPLS experimental bits to be set to.

On other routers where you have congested links (ex wireless), set up a queue tree on either side of the link that shapes to the link's maximum. Then, do the following to properly mark the MPLS packets for use in your queue tree:
- At the egress interface that has your queue tree set up, create a bridge that includes only that interface
- Add a bridge filter for chain 'output' that matches 'ingress priority' equal to the value that you had assigned on the endpoints (i.e. the experimental bit values)
- Set the action to 'mark packet'

The queue tree will now properly classify the MPLS packet in the queue and properly do QoS.
Hi, really interesting way of doing things. However I think this uses a bridge and adds processing overhead, how's the performance you have noticed using this method?

Hopefully someday MikroTik will allows us to process "natively" MPLS trafic with QoS

Enviado desde mi MotoE2(4G-LTE) mediante Tapatalk
Rafael Carvallo
Telecommunications Engineer

Need consultation?
Need a hotspot with facebook integration?
Send a PM!

Hablamos español, atendemos el mercado de latinoamérica visita nuestra página web:
http://www.tuproximosalto.com
 
mducharme
Trainer
Trainer
Topic Author
Posts: 1019
Joined: Tue Jul 19, 2016 6:45 pm

Re: RE: Re: MPLS/VPLS and HTB / EXP bits

Mon Aug 22, 2016 12:37 am

Hi, really interesting way of doing things. However I think this uses a bridge and adds processing overhead, how's the performance you have noticed using this method?

Hopefully someday MikroTik will allows us to process "natively" MPLS trafic with QoS
With 3 tunnels totaling 20Mbps and extensive queueing we are only seeing ~1% CPU usage on Routerboard 1100AHX2's in our lab. I'm sure the impact will be bigger on higher bandwidth links, but well within reason.
 
oscarif
just joined
Posts: 1
Joined: Wed Sep 12, 2018 6:42 pm

Re: MPLS/VPLS and HTB / EXP bits

Wed Sep 12, 2018 7:01 pm

Good morning Partners,

I have a test lab with 3 RB MIKROTIK with OSPF / MPLS - VPLS structure to connect a transparent LAN network but I can not apply to limit the MPLS-VPLS bandwidth. Could you help me.
 
mducharme
Trainer
Trainer
Topic Author
Posts: 1019
Joined: Tue Jul 19, 2016 6:45 pm

Re: MPLS/VPLS and HTB / EXP bits

Wed Sep 19, 2018 8:42 pm

Good morning Partners,

I have a test lab with 3 RB MIKROTIK with OSPF / MPLS - VPLS structure to connect a transparent LAN network but I can not apply to limit the MPLS-VPLS bandwidth. Could you help me.
To limit the VPLS bandwidth, all you need to do is create a queue tree on both ends of the VPLS tunnel, set to match no-mark, with the limit you want, and the parent set to the VPLS interface. The upload limit will be on one side and the download limit on the other.

Who is online

Users browsing this forum: No registered users and 5 guests