cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
5128
Views
20
Helpful
12
Replies

NCS 55A2 XR 6.6 QoS

Seth Beauchamp
Level 1
Level 1

I am trying to do a simple shaper with a basic scheduler to prioritize EF traffic across a link. With the policy that I have tried, I get an error upon commit "!!% 'DNX_QOSEA' detected the 'warning' condition 'Invalid egress policy, Cannot have both queuing & marking in the same policy'"

 

The policy is:

 

interface TenGigE0/0/0/0.102
 service-policy output WAN_SHAPE_1Gbps

policy-map WAN_SHAPE_1Gbps
 class class-default
  service-policy WAN_TRAFFIC
  shape average 990 mbps 
 ! 
 end-policy-map


policy-map WAN_TRAFFIC
 class PRIORITY
  priority level 1 
  police rate percent 95 
  ! 
  ! 
 class class-default
 ! 
 end-policy-map

class-map match-any PRIORITY
 match qos-group 1 
 end-class-map

I also have an inbound policy on another interface which matches dscp EF and sets QoS group 1.

 

So the question is.. why does the error suggest this policy has both queuing and marking? 

 

Also should I be setting/matching traffic-class instead of Qos-Group? Whats the difference between the two?

1 Accepted Solution

Accepted Solutions

I found an example, you actually apply two policy-maps to the egress, one for marking and one for queuing. But yes what you have should work too.

 

Sample Ingress Policy-Map

policy-map ingress-classif
class cos2
set qos-group 1
set traffic-class 3
!
class cos3
set qos-group 2
set traffic-class 5
!
class cos4
set qos-group 3
set traffic-class 4
!
class class-default
set qos-group 7
set traffic-class 6
!
end-policy-map
!

class-map match-any cos2
match cos 2 
end-class-map

class-map match-any cos3
match cos 3 
end-class-map

class-map match-any cos4
match cos 4 
end-class-map

Sample Egress Marking Policy

policy-map egress-marking
class qos1
set cos 1
!
class qos2
set cos 2
set dei 1
!
class qos3
set cos 3
!
class class-default
set cos 7
!
end-policy-map
!

class-map match-any qos1
match qos-group 1 
end-class-map

class-map match-any qos2
match qos-group 2 
end-class-map

class-map match-any qos3
match qos-group 3 
end-class-map
!

Sample Egress Queuing Policy

policy-map egress-queuing
class tc3
shape average 2 mbps
!
class tc4
shape average 5 mbps
!
class tc5
shape average 7 mbps
!
class class-default
!
end-policy-map
!

class-map match-any tc3
match traffic-class 3
end-class-map
!
class-map match-any tc4
match traffic-class 4
end-class-map
!
class-map match-any tc5
match traffic-class 5
end-class-map
!

Attaching policy to a Interface

RP/0/RP0/CPU0:ios(config)#interface tenGigE 0/0/1/0/0 

RP/0/RP0/CPU0:ios(config-if)#service-policy input ingress-classif 

RP/0/RP0/CPU0:ios(config-if)#service-policy output egress-marking 

RP/0/RP0/CPU0:ios(config-if)#service-policy output egress-queuing 

 

RP/0/RP0/CPU0:ios(config-if)#commit 

RP/0/RP0/CPU0:ios#show running-config interface tenGigE 0/0/1/0/0 

interface TenGigE0/0/1/0/0

 service-policy input ingress-classif
 service-policy output egress-marking
 service-policy output egress-queuing
!
 
 
Sam

View solution in original post

12 Replies 12

smilstea
Cisco Employee
Cisco Employee

Hi Seth,

 

A few things, qos-group matching on egress counts as a marking action and queuing and marking are not supported at the same time. On NCS5500 we have to apply different service-policy statements on the interface for queuing and for remarking actions. This means separate policy-maps  have to be created for marking and queuing respectively.

 

NCS5500 implements a different concept for marking. It is based on traffic-class and qos-group. On egress we match on these two parameters to remark traffic and to select queues.Traffic-class determines priority through the fabric.

 

While “match traffic-class” has to be used for queuing features “match qos-group” can only be used for marking.

 

Another issue is that policing is only supported on ingress and shaping only supported on egress.

 

 

Thanks,

Sam

 

 

Thanks for the response. If I may ask a follow up...

 

 

What would be the simplest way to ensure EF traffic gets prioritized with a low latency queue on these devices? Essentially, I have the NCS 55A2 positioned as a P router and want to ensure EF traffic (or mpls exp 5) gets LLQ treatment outbound.

on the ingress ports, do I need a marking policy that sets sets traffic class using a class-map matching dscp ef and mpls exp 5? Then a policy on egress matching the traffic-class? Does the dscp EF and mpls exp 5 markings stay preserved after leaving NCS 55A2 with this method?

 

This for example?

 

class-map match-any ef
 match traffic-class 1 
 end-class-map
! 
class-map match-any tc1
 match dscp ef 
 match mpls experimental topmost 5 
 end-class-map
! 

policy-map egress
 class class-default
  service-policy priority
  shape average 990 mbps 
 ! 
 end-policy-map
! 
policy-map priority
 class ef
  priority level 1 
 ! 
 class class-default
 ! 
 end-policy-map
! 
policy-map ingress
 class tc1
  set traffic-class 1
 ! 
 class class-default
 ! 
 end-policy-map
! 

interface te0/0/0/0
 service-policy output egress

interface te0/0/0/1
 service-policy input ingress

The markings should stay preserved, for the sake of queuing we need to use traffic-class on ingress and egress. I seem to recall something about needing to use both qos-group and traffic-class on ingress but I can't find those details at the moment.

 

Sam

ok got it, so my last example should work, however I should also set qos-group 1 on ingress as well?

I found an example, you actually apply two policy-maps to the egress, one for marking and one for queuing. But yes what you have should work too.

 

Sample Ingress Policy-Map

policy-map ingress-classif
class cos2
set qos-group 1
set traffic-class 3
!
class cos3
set qos-group 2
set traffic-class 5
!
class cos4
set qos-group 3
set traffic-class 4
!
class class-default
set qos-group 7
set traffic-class 6
!
end-policy-map
!

class-map match-any cos2
match cos 2 
end-class-map

class-map match-any cos3
match cos 3 
end-class-map

class-map match-any cos4
match cos 4 
end-class-map

Sample Egress Marking Policy

policy-map egress-marking
class qos1
set cos 1
!
class qos2
set cos 2
set dei 1
!
class qos3
set cos 3
!
class class-default
set cos 7
!
end-policy-map
!

class-map match-any qos1
match qos-group 1 
end-class-map

class-map match-any qos2
match qos-group 2 
end-class-map

class-map match-any qos3
match qos-group 3 
end-class-map
!

Sample Egress Queuing Policy

policy-map egress-queuing
class tc3
shape average 2 mbps
!
class tc4
shape average 5 mbps
!
class tc5
shape average 7 mbps
!
class class-default
!
end-policy-map
!

class-map match-any tc3
match traffic-class 3
end-class-map
!
class-map match-any tc4
match traffic-class 4
end-class-map
!
class-map match-any tc5
match traffic-class 5
end-class-map
!

Attaching policy to a Interface

RP/0/RP0/CPU0:ios(config)#interface tenGigE 0/0/1/0/0 

RP/0/RP0/CPU0:ios(config-if)#service-policy input ingress-classif 

RP/0/RP0/CPU0:ios(config-if)#service-policy output egress-marking 

RP/0/RP0/CPU0:ios(config-if)#service-policy output egress-queuing 

 

RP/0/RP0/CPU0:ios(config-if)#commit 

RP/0/RP0/CPU0:ios#show running-config interface tenGigE 0/0/1/0/0 

interface TenGigE0/0/1/0/0

 service-policy input ingress-classif
 service-policy output egress-marking
 service-policy output egress-queuing
!
 
 
Sam

smailmilak
Level 4
Level 4

Hi, 

 

I have just started working with NCS. With A9K I didn't had any issues with this particular QoS policy-map.
All I need is to match an Exp bit or dscp and put in in queue (bandwidth percent or police e.g).

What ever I do I get the same error Cannot have both queuing & marking in the same policy.

 

This is my class map and pmap. What is the equivalent that is supported on NCS55A2 100GigE MPA?

I was reading the guide but it's not entirely clear. Do I really need to match e.g. MPLS EXP bit 4, and set traffic-class 4 or qos qroup 4 so that I can match traffic-class 4 or qos qroup 4 on the egress interface?

 

class VOICE

  police rate 3 gbps

  priority level 1

 !

 class CONTROL

  police rate 50 mbps

  priority level 2

 !

 class MANAGEMENT

  bandwidth 250 mbps

 

class-map match-any VOICE

 match mpls experimental topmost 3 5

 match dscp ef cs3

 

class-map match-any CONTROL

 match mpls experimental topmost 6

 match dscp cs6

 

class-map match-any MANAGEMENT

 match mpls experimental topmost 1

 match dscp cs1

hi xr-rules,

 

configure one QoS policy only for marking and another only for queuing. In that case you can apply both egress policies simultaneously to an interface.

 

/Aleksandar

Thanks Aleks,

 

the weird part is that I'm only matching, not marking (set exp bit 4 for example). I will receive already marked traffic on this PE (marked by the source i.e. voice GW).

So I should match for example exp bit 4 and set it in qos-group 4 or traffic-class 4?

This qos-group 4 or traffic-class 4 will be matched by the egrees PMAP and put in a queue? 

Is this the correct approach with NCS? I have to do it properly before putting the nodes in production.

In an egress QoS policy on DNX platforms (NCS540, NCS560, NCS5k, NCS5500) you cannot match on packet header fields. You can only match on internal scope traffic-class or qos-group. Traffic has to be classified into a given traffic-class or qos-group in an ingress QoS policy. Match on a traffic-class if the action you want to apply is queuing. Match on qos-group if the action you want to apply is egress marking. 

Hope this helps!

/Aleksandar

Ok, got it. I have noticed that same by using the examples in the config guide. The funny part is that for LLQ, shaping is used, and back in the old days this was a no go

 

https://www.cisco.com/c/en/us/td/docs/iosxr/ncs5500/qos/71x/b-qos-cg-ncs5500-71x/b-qos-cg-ncs5500-71x_chapter_0100.html#concept_8B00194217564346A11458F1B9E47260

 

It's getting clear now. Thanks Aleks, you are supportive as always.

 

 

Always a pleasure!

 

DNX platforms use merchant silicone, which has great benefits but does come with some restrictions. One of them is that policing is supported only on ingress, while and queueing actions (shape, BW, LLQ) are supported only on egress. Hence you will see that on DNX we always configure shaping with LLQ.

 

In case you didn't know, there is a lot of material on NCS5500 on https://xrdocs.io/ . The content there is authored by NCS5500 experts, you will find lots of useful info there. 

 

/Aleksandar

Thanks Aleks. I know about that site. It’s very useful.

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: