cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
5943
Views
0
Helpful
16
Replies

COS to EXP bits mapping

amitbatra
Level 1
Level 1

Hi Guys,

theoretically and practicaly the DSCP or IP prec values are copied to EXP bits of shim header.

Does that same applies to when Atom is configured ?? because in Atom the PE receives traffic from CE and that could be vlan tagged. PE imposes the MPLS tag received from egree PE and then imposes the tunnel tag and send it to the egress PE.

are the COS values copied to the appropriate EXP bits at this time ??

1 Accepted Solution

Accepted Solutions

Hi Amit!

Thanks. Can you please mark the question as solved if it did? or rate it accordingluy?

Regards,

Niranjan

View solution in original post

16 Replies 16

shivlu jain
Level 5
Level 5

exp bit only understands the dscp, so first yoou have to convert the cos to dscp and then bind the dscp to exp.

regards

shivlu

hi Shivlu!

I would like to counter your argument. It is not necessary to convert the cos to dscp first. The ip pre to exp mapping is the default. But you can use MQC to directly map from the cos bits recieved to the mpls exp bits. Following are the references :

"Note Mapping 802.1p CoS values to MPLS EXP bits is supported using EoMPLS only. " found in ...

http://www.cisco.com/en/US/docs/interfaces_modules/shared_port_adapters/configuration/6500series/76ovwsip.html

This is cat6500 / 7600 documentation.

Also from cisco press :

http://www.networkworld.com/subnets/cisco/042707-ch12-mpls.html?page=10

The Use of MPLS QoS for Ethernet over MPLS

So far in this chapter, the packet for which the QoS was set was an IP packet or a labeled packet. However, in the case of Ethernet over MPLS (EoMPLS), the forwarded packet is actually an Ethernet frame. If the frame is a non-VLAN Ethernet frame, it does not have QoS information embedded. If the frame is an 802.1Q frame, though, the Priority bits (P bits) in the 802.1Q header designate a QoS value. If a service provider carries the 802.1Q Ethernet frames over an MPLS network as in the case of point-to-point EoMPLS or VPLS, it would be nice if he could police the traffic and recolor it, if needed. You can do this in Cisco IOS. You can match the 802.1Q Priority bits in MQC by matching cos values in the class map. In Example 12-11, the EXP bits are set to 1 on the tunnel and VC label on the ingress PE, if the 802.1Q P bits are 1, 2, or 3.

Example 12-11 MPLS QoS for EoMPLS

interface Vlan50

no ip address

!

mpls l2transport route 1.1.1.1 100

service-policy input foo

!

class-map match-all foo-class

match cos 1 2 3

!

policy-map foo

class foo-class

set mpls experimental 1

class class-default

shape average 2000000 8000 8000

Amit, I hope this answers your question!

Cheers!

Niranjan

Hi Shivlu,

i really appreciate your efforts . but EXP bits used prec values. there are only 3 EXP bits where as you have 6 bits for DSCP .

EXP has trouble to cope up with DSCP.

Thats not true that you have to convert them to DSCP and then map to EXP

what niranjan is saying is right.

the reason i asked this question in this forum is , i wanted to confirm this from everybody here and get some more thoughts.

anyways

Thanks niranjan

Hi Amit!

Thanks. Can you please mark the question as solved if it did? or rate it accordingluy?

Regards,

Niranjan

hi niranjan

thanks for your reply because b4 that i really know this thing.

thanks 2 amit also for putting such type of question on forum.

regards

shivlu

Hi Niranjan,

Hope you don't mind for another case that we have facing.

Our CE is a 7606 WITHOUT the SIP so we are doing PFC QOS, the link between CE and PE is a GE with 802.1q encapsulation, so the voice traffic is taking priority queue with COS 5 to PE and PE is a 10K router with MQC QOS configured and matching EF and CS5 for the priority queue and mark to EXP 5 for the up-stream MPLS router.

The customer is seeing CS4 (DSCP 40) for the remote ingress voice traffic, where was doing wrong?

Here is the cos-dscp map from hub CE (COS5 mapped to EF):

njli2pece1#sh mls qos maps cos-dscp

Cos-dscp map:

cos: 0 1 2 3 4 5 6 7

------------------------------------

dscp: 0 10 18 26 34 46 48 56

njli2pece1#

The remote CE is seeing CS5 from their PE not EF:

mdhv113ce1#sh policy-map interface

Serial0/0/0:0

Service-policy input: Verify-Dscp

Class-map: check-voice (match-any)

149431 packets, 9923547 bytes

30 second offered rate 18000 bps

Match: ip dscp ef (46)

0 packets, 0 bytes

30 second rate 0 bps

Match: ip dscp cs5 (40)

104578 packets, 6970243 bytes

30 second rate 18000 bps

Is it true that the MPLS EXP is just a header appended to the IP frame and the DSCP value inside shouldn't be touched inside the MPLS cloud?

Hi!

First of all, it is true that the DSCP value shouldnt be touched inside the mpls cloud. All Qos will be done on the exp bits.

For your problem, Since you are using PFC based Qos even on the PE, I am assuming that you have a LAN card facing the CE.

What is the cos-dscp mapping on the ingress PE. I am seeing the mapping on the CE. This is the wrong place. Assuming that the PE is recieving the traffic with vlan tag with cos-5, you should set the cos-dscp map here. This works in the ingress and as I can see, probably you have set the mapping on the egress port of the CE.

Hope this will solve your issue.

If not, please give me more details on the interface configs on the CE1, PE1, PE2, and CE2.

Regards,

Niranjan

Thanks for the reply.

What is the command to see the cos-dscp mapping from a GSR 10k router, there is no mls qos command?

Here are the config:

Hub CE:

njli2pece1#sh run int gi3/24

!

interface GigabitEthernet3/24

no ip address

load-interval 30

wrr-queue bandwidth percent 30 20 50

wrr-queue queue-limit 40 30 15

wrr-queue random-detect min-threshold 1 60 80 100 100 100 100 100 100

wrr-queue random-detect min-threshold 2 60 80 99 99 100 100 100 100

wrr-queue random-detect min-threshold 3 99 100 100 100 100 100 100 100

wrr-queue random-detect max-threshold 1 80 100 100 100 100 100 100 100

wrr-queue random-detect max-threshold 2 80 100 100 100 100 100 100 100

wrr-queue cos-map 2 3 6

wrr-queue cos-map 2 4 7

wrr-queue cos-map 3 1 3

wrr-queue cos-map 3 2 4

mls qos trust dscp

no cdp enable

end

njli2pece1#sh run int gi3/24.112

!

interface GigabitEthernet3/24.112

encapsulation dot1Q 112

ip vrf forwarding r1-aiggs

ip address 68.139.194.194 255.255.255.252

ip flow ingress

ip flow egress

no cdp enable

end

!

Hub PE:

worge01>show config | b GigabitEthernet4/1.49659

interface GigabitEthernet4/1.49659

encapsulation dot1Q 112

ip vrf forwarding V127453:AmericanInternational

ip address 68.139.194.193 255.255.255.252

ip access-group 101 in

no ip redirects

no ip unreachables

no ip directed-broadcast

no ip proxy-arp

ip mtu 1500

plim qos input map cos 5 queue low-latency

service-policy input DSCP_CE-PE_ETM_G=5008K_R=300M

service-policy output DSCP_PE-CE_282000K_gsr_6Q !

!

worge01>show policy-map DSCP_CE-PE_ETM_G=5008K_R=300M

Policy Map DSCP_CE-PE_ETM_G=5008K_R=300M

Class class-default

police cir 300000000 bc 37500000 be 37500000

conform-action transmit

exceed-action drop

service-policy DSCP_CE-PE_ETM_G=5008000_gsr

!

worge01>show policy-map DSCP_CE-PE_ETM_G=5008000_gsr

Policy Map DSCP_CE-PE_ETM_G=5008000_gsr

Class dscp_EF_ipprec_5_5Qs

police cir 5008000 bc 626000 be 1252000

conform-action set-mpls-exp-imposition-transmit 5

exceed-action drop

Class dscp_AF4x_ipprec_4_5Qs

set mpls experimental 4

Class dscp_AF3x_ipprec_3_6_7_5Qs

set mpls experimental 3

Class dscp_AF2x_ipprec_2_5Qs

set mpls experimental 2

Class ip_best_effort_BE

set mpls experimental 0

!

worge01>sh config | b dscp_EF_ipprec_5_5Qs

class-map match-any dscp_EF_ipprec_5_5Qs

match ip dscp 40 46

!

Remote CE:

mdhv113ce1#sh run int s0/0/0:0

!

interface Serial0/0/0:0

no ip address

encapsulation frame-relay IETF

load-interval 30

service-policy input Verify-Dscp

service-policy output TypeB-Remote-QOS-Out

end

mdhv113ce1#sh run int s0/0/0:0.100

!

interface Serial0/0/0:0.100 point-to-point

ip address 159.24.187.178 255.255.255.252

ip flow ingress

ip flow egress

snmp trap link-status

frame-relay interface-dlci 100 IETF

end

!

Remote PE:

!

ptnes05>show config | b Serial8/0/2.1/28:1.20505

interface Serial8/0/2.1/28:1.20505 point-to-point

ip vrf forwarding V128431:AmericanInternational

ip address 159.24.187.177 255.255.255.252

ip access-group 101 in

no ip redirects

no ip unreachables

no ip proxy-arp

frame-relay interface-dlci 100

service-policy input DSCP_CE-PE_ETM_G=448000

service-policy output DSCP_PE-CE_1536K_6Q

!

ptnes05>show policy-map DSCP_PE-CE_1536K_6Q

Policy Map DSCP_PE-CE_1536K_6Q

Class class-default

shape 1536

service-policy DSCP_PE-CE_1344000_to_120M_6Q

!

ptnes05>show policy-map DSCP_PE-CE_1344000_to_120M_6Q

Policy Map DSCP_PE-CE_1344000_to_120M_6Q

Class dscp_EF_ipprec_5_5Qs

priority

police percent 50 25 ms 0 ms conform-action transmit exceed-action transmit violate-action drop

!

ptnes05>sh config | b dscp_EF_ipprec_5_5Qs

class-map match-any dscp_EF_ipprec_5_5Qs

match ip dscp cs5 ef

!

Hello Frank!

I am not very comfertable with the 10K configuration. But probably since it is a router and doesnot support mls qos commands on the interface, you will have to apply a policy map at the ingress to match based on cos and mark the dscp accordingly.

Also, on the PE ingress policy, under class-map match-any dscp_EF_ipprec_5_5Qs

match ip dscp 40 46 <<<<<<

Why do you have 40 and 46?

For the time being can you remove 40 from this, and check the output of the command

" sh policy-map interface Gi4/1.49659 " ??

If the counters are not increasing for this class, then it would confirm that the packets recieved from the hu-CE are not marked to DSCP EF.

So, if the DSCP is not set to EF by the CE ( as I am suspecting,) then the counters for the Class dscp_EF_ipprec_5_5Qs would not increase.

But that will not explain why the remote CE is getting traffic with DSCP40 , unless the original traffic being sent has dscp40 already set on it, or the non-pe-connected port has a default cos-map kick-in which might be setting the dscp to 40.

If tthis solution is not working , I could you please let me know the results of the above test? The stratagy would be to find out at which place the DSCP is failing ( not EF) .

Regards,

Niranjan

The PE was managed by our core group and I have asked them to separate two line instead of put 40 and 46 together but got rejected.

I have asked the customer to schedule a troubleshooting session to SPAN on the CE interface to see what DSCP is sending out and will go from there.

What is the default mapping from a PFC COS5 to MQC DSCP on ethernet .1q link between 7606 and 10k GSR?

Thanks,

Hi!

The mapping that you are talking about should depend on the incoming map/trust conditions on the ingress port of the CE. Is any trust / trust ip phone configured on the ingress port of the CE device?

Can you check applying the cos map on the ingress port ( the non-PE-connected port of the hub CE.)?

The current cosmap on the CE on the CE-PE link is not doing any dscp mapping and neither is the PE. So for the remote to get packets marked with dscp40, the only way is that some config trust/cos-map settings on the ingress of the CE is affecting.

Regards,

Niranjan

Regards,

Niranjan

There is no cos mapping on the link between CE and LAN switch, here is the config:

njli2pece1#sh run int gi4/1

!

interface GigabitEthernet4/1

description To RPUSNJLI2PE-1 GE4/1

switchport

switchport trunk encapsulation dot1q

switchport trunk native vlan 150

switchport trunk allowed vlan 150,151

switchport mode trunk

mls qos trust dscp

channel-group 1 mode desirable

end

As I understand the trunk port is doing FIFO and won't do anything even with cos-map, is it correct?

Which trunk port do you mean?

The incoming connected to LAN is doing FIFO and not applyng any cos-map as i see it.

The port connected to PE is doing the queuing but not applying cos map for the egress traffic.

The mls-qos trust on the lan connected port explains the dscp mappinp of CS4. Probably the traffic coming in is already marked with 4.

The solution for your issue can be :

1. to implement class-map at the ingress on the PE to map from cos to DSCP EF.

2. To verify the DSCP recieved on the CE from LAN and use DSCP-Mutation to map the traffic to EF.

3. Do nothing as the CS4 as well as EF traffic is getting the same treatment in the MPLS core as the class map on the PE matches either 40 or 46.

Regards,

Niranjan

hi!

Can you please rate the post if your issue is solved? Or do let me know if you are still facing any problems.

Regards,

Niranjan

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: