brkdcn-3346 - cisco live
TRANSCRIPT
#CLUS
Nemanja KamenicaTechnical Marketing Engineer
BRKDCN-3346
End-to-End QoS Implementation and Operation with Nexus
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Session Objectives
• Provide a refresh of QoS Basics
• Understand the basic switch architecture for the Nexus switch family
• Provide a detailed understanding of QoS on Nexus platforms
• Learn how to configure QOS on Nexus devices through real-world configuration examples
3BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Session Non-Objectives
• Data Centre QoS Methodology
• Nexus hardware architecture deep-dive
• Application Centric Infrastructure (ACI) QOS
4BRKDCN-3346
Questions? Use Cisco Webex Teams to chat with the speaker after the session
Find this session in the Cisco Live Mobile App
Click “Join the Discussion”
Install Webex Teams or go directly to the team space
Enter messages/questions in the team space
How
Webex Teams will be moderated by the speaker until June 16, 2019.
1
2
3
4
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Cisco Webex Teams
cs.co/ciscolivebot#
5
BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 6
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Congestion Happens Everyday!
7BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Why QoS in the Data Centre?
8BRKDCN-3346
Assign Colour to Traffic
MaximiseThroughput
ManageCongestion
Maximise Throughput and Manage Congestion!
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Can Traffic Control help …
9BRKDCN-3346
… or confuse
… or hurt
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 10
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
The QoS Toolset
11BRKDCN-3346
Classification
Identify and
Split Traffic
into Different
Classes
Queuing and
Scheduling
Prioritise,
Protect and
Isolate Traffic
Based on
Markings
Marking
Mark Traffic
According to
Behaviour
and Business
Policies
Policing
Discard
Misbehaving
Traffic to Maintain
Network Integrity
Shaping
Control
Bursts and
Conform
Traffic
25nd Anniversary
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Classification
• Traffic Categorisation based on traffic attributes
• Marking
• Assigning different/new attribute (priority) to traffic
• Policing
• Limit misbehaving flows
Traffic Management Tools
12BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Identify traffic
• DSCP
• IP PREC
• CoS
• ACLs
• Re-map Traffic
• Like to Like (i.e. CoS to CoS)
• Like to Unlike (i.e. DSCP to COS)
• Needs mapping tables
• Also called Mutation
Classification and Marking – Two sides of a coin
13BRKDCN-3346
VoIPVideo
p2p
App1HTTP
emailvmotion
mgmtlync
backup
Unclassified:
Uncontrolled Bandwidth
VoIP/Lync
Email/HTTP
SAP
Backup
Classified:
Controlled Bandwidth
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Single rate Two Color Policer
• Conform Action (permit)
• Exceed Action (drop)
• Two rate Three Color Policer
• Conform Action (permit)
• Exceed Action (markdown)
• Violate Action (drop)
Policing – Limit Misbehaving Traffic
14BRKDCN-3346
Policer
Tokens
Burst Limit
Conforming Traffic
Excess Traffic
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Buffering
• Storing packets in memory
• Queuing
• Buffering packets according to traffic class
• Scheduling
• Order of transmission of buffered packets
• Shaping
• Smooth burst traffic
Congestion Management Tools
15BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Many to One Conversations
• Client to Server
• Server to Storage
• Aggregation Points
• Speed Mismatch
• Client to WAN to Server
Buffering – Why do we need it?
16BRKDCN-3346
1 GE
1 GE
1 GE
1 GE
10 GE10 GE
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS 17BRKDCN-3346
• Matches most Service-Provider offerings
• Ready for No-Drop traffic like FCoE
• One Class left to place traffic above or below Best-Effort traffic priority
• Special Application which is drop sensitive (above Best-Effort -Critical)
• Non-Critical Bandwidth intensive application (below Best-Effort -Scavenger)
4 Class Queuing Model
Class CoS Queues
Priority 5-7 PQ
No-Drop 3 Q2
Better or Worse then Best-Effort
1,2,4 Q1
Best-Effort 0 Default-Q
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Matches often a Campus QoS concept
• DSCP to CoS derivation does NOT apply anymore
• (Topmost 3-Bit mapping from DSCP to CoS)
• No-Drop still with CoS3 (DSCP 24-30 are “unusable”)
• Valid but most complex Classification to Marking implementation as per regards to No-Drop
8 Class Queuing Model
BRKDCN-3346
Class DSCP Queues
Priority CS6 (CS7)PQ
Platinum EF
Gold AF41 Q7
Silver CS4 Q6
No-Drop CoS3 Q5
Bronze AF21 Q4
Management CS2 Q3
Scavenger AF11 Q2
Bulk Data CS1 Q1
Best-Effort 0 Default-Q
18
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Head of Line BlockingWhat is the Problem?
19BRKDCN-3346
Ingress Module Egress Module
Ingress Module Egress Module
Ingress Module Egress Module
Crossbar
Fabric
buffer
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Virtual Output QueuesAvoid Head of Line Blocking
20BRKDCN-3346
Ingress Module Egress Module
Ingress Module Egress Module
Ingress Module Egress Module
Crossbar
Fabric
IngressVOQ
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Virtual Output QueuesAvoid Head of Line Blocking
21BRKDCN-3346
Ingress Module Egress Module
Ingress Module Egress Module
Ingress Module Egress Module
Crossbar
Fabric
IngressVOQ
buffer
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS 22BRKDCN-3346
Buffering on Nexus Models compared
Ingress Egress
N portsN ports
VOQ
Virtual Output Queue
Input buffer for every egress port
NxN buffer size
Ingress Egress
N portsN ports
Output Queue Buffer
Shared buffer for N egress ports
N buffer size
Shared no-drop/
drop
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Defines Order of transmission
• The Priority-Queue always serviced first
• Normal Queues serviced only after Priority Queue empty
• Different Scheduling algorithms for normal queues
Scheduling – Who goes first?
23BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Deficit Weighted Round Robin
• Variable sized packets
• Uses a deficit counter
• Shaped Round Robin
• More even distributed ordering
• Weighted interleaving of flows
Common Scheduling Algorithms
24BRKDCN-3346
• Round Robin (RR)
• Simple and Easy to implement
• Starvation-free
• Weighted Round Robin (WRR)
• Serves n packets per non-empty queue
• Assumes a mean packet size
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Congestion Avoidance Tools
• Tail Drop (TD)
• Drop packets at tail of the queue
• Single threshold per queue
• Weighted Random Early Drop (WRED)
• One or more thresholds per queue
• Threshold associated with DSCP or COS
25BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Putting it all together!
26BRKDCN-3346
Egress Port
PQ1
Q2
Q3
Q-Default
Schedule
rD
WR
R
Drop Threshold 4
Drop Threshold 3
Drop Threshold 2
Drop Threshold 1
Normal Queue
Packet is placed in the Egress
Queue according to CoS/DSCP
value.
1
Normal Queues have
Threshold and drop
packet accordingly
4
Priority Queue always served first
2
Normal Queues served after PQ is
empty according to
Scheduler
3
data
L2CoS [3]
L3DSCP [24]
COS Queue
5, 6, 7 PQ1
3, 4 Q3
2 Q2
0, 1 Q-Default
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 27
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
3 Block Construct
Nexus uses Modular QOS CLI (MQC)
29BRKDCN-3346
What Traffic do we care about?• DSCP• CoS• IPPREC• ACLs
Class-Map
What actions do I take on the classes?
• Policing• Marking• Scheduling• Queueing
Policy-Map
Where do I apply this policy?• System Wide• VLAN• Interface• Port-channels
Service-Policy
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Three Different Types
30BRKDCN-3346
Network-QoS• Congestion-Control• Pause / MTU per VL
QoS• Marking• Policing• Mutation
Queuing• Buffering• Queuing• Scheduli
ng
Policy-map
QoS• CoS• DSCP• PREC• ACLs
Queuing• CoS• DSCP
Class-map Service-policy
QoS•Interfaces•Vlans•Port-channel•System-qos
Queuing•Interfaces•Port-channels•System-qos
Network-QoS• System-qos
Network-QoS• CoS• Protocol (FCoE)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Network-QoS Policy
31BRKDCN-3346
Switch 1 Switch 2 Switch 3
Network QoS policies should be applied consistently on all switches network wide
Fabric
IngressModule
IngressModule
IngressModule
EgressModule Fabric
IngressModule
IngressModule
IngressModule
EgressModule Fabric
IngressModule
IngressModule
IngressModule
EgressModule
• Define global queuing and scheduling parameters for all interfaces in switch
• Identify drop/no-drop classes, MTU and WRED/TD, etc.
• One network-QoS policy per system, applies to all ports
• Assumption is network-QoS policy defined/applied consistently network-wide
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• System based QoS Policy gets globally applied to all interfaces and VLAN
• System based QoS Policy is configured in System QoS
System based Policy attachment
32BRKDCN-3346
Nexus(config)# system qos
Nexus(config-sys-qos)# service-policy input myPolicy
Routed Port
Access Port
802.1q Trunk
Routed Port
Access Port
802.1q Trunk
VLAN
VLAN
QoSPolcies
Service Policy applied to the
VLAN Database
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• VLAN based QoS Policy is configured in VLAN Database
• No SVI (aka L3 VLAN Interface) required
VLAN based QoS Policy attachment
33BRKDCN-3346
Nexus(config)# vlan configuration <vlan-id>
Nexus(config-vlan)# service-policy input myPolicy
Routed Port
Access Port
802.1q Trunk
Routed Port
Access Port
802.1q Trunk
VLAN
VLANQoS
Polcies
Service Policy applied to the
VLAN Database
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Interface based QoS Policy takes precedence over VLAN
• Can also be attached to port-channel and applies to all member-ports
• No Egress QoS policies on L2 ports!
Interface based QoS Policy attachment
34BRKDCN-3346
Nexus(config)# interface ethernet 1/1
Nexus(config-if)# service-policy input myPolicy
Routed Port
Access Port
802.1q Trunk
Routed Port
Port-channel
QoSPolicies
Service policy applied to the
switchport
Service Policy applied to the Switchport …
… or the Routed Port
… or a port-channel
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Interface based QoS Policy takes precedence over VLAN
• Interface based QoS Policy is configured under the respective Interface
• Queuing Policy can be attached to port-channel also
Interface based Queuing Policy attachment
35BRKDCN-3346
Nexus(config)# interface ethernet 1/1
Nexus(config-if)# service-policy input myPolicy
Routed Port
Access Port
802.1q Trunk
Routed Port
QoSPolicies
Service policy applied to the
switchport
Service Policy applied to the Switchport …
… or the Routed Port
… or a port-channel
Port-Channel
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Priority Flow Control (802.1Qbb)
• Enables Lossless Ethernet using per traffic class pause
• During congestion, no-drop priority is paused
• No effect on other priority values
New QoS Capabilities
36BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• DCBXP (802.1Qaz)
• LLDP with new TLV Values
• Negotiates capabilities (like PFC) with other devices
• ECN (Explicit Congestion Notification)
• Congestion Notification without dropping packets
• Uses two LSB bits in DiffServ fieldIP header
DC QoS Capabilities
37BRKDCN-3346
ECN ECN Behavior
0x00 Non ECN Capable
0x10 ECN Capable Transport (0)
0x01 ECN Capable Transport (1)
0x11 Congestion Encountered
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Simplification of the infrastructure by using Ethernet for data and storage traffic
• FCoE
• Replaces Fibre Channel stack with Ethernet
• RoCE
• RoCE extends RDMA capabilities over Ethernet
Data Centre Converged Infrastructure
38BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Requirement for FCoE and RoCEv1:
• PFC
• ETS
• Requirement for RoCEv2
• PFC
• ETS
• ECN (optional)
RoCE vs RoCEv2 (non-drop) FC/FCoE
39BRKDCN-3346
RDMA API
IB Transport
IB Network
Ethernet
Applications
RoCE v1
RDMA API
IB Transport
UDP/IP
Ethernet
Applications
RoCE v2
FCP
FC Transport
FCOE
Ethernet
Applications
FCoE
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Data Centre architecture provides a new set of trust boundaries
• Virtual Switch extends the trust boundary into the Hypervisor
• Nexus Switches always trust CoS and DSCP
To Trust or Not To Trust?
40BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QoS
• Mapping between IP priorities to EXP on PE router
• Classification is done biased on COS, DSCP, IP precedence or ACL
• DiffServ Tunneling mode provides different QOS behavior in provider network
• Uniform mode delivers overlay priority
• Pipe mode extends underlay priority
MPLS network
42BRKDCN-3346
EXP COS DSCP IP pres
0 0 0 0
1 1 8 1
2 2 16 2
3 3 24 3
4 4 32 4
5 5 40 5
6 6 48 6
7 7 56 7
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QOSMPLS – Default Mode
43BRKDCN-3346
CE1 PE1 P1 P2 PE2 CE2
DSCP 24 DSCP 24
EXP 3
EXP 3
DSCP 24
EXP 3
EXP 3
DSCP 24
EXP 3
DSCP 24
MPLS Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QOSMPLS – Uniform Mode
44BRKDCN-3346
CE1 PE1 P1 P2 PE2 CE2
DSCP 24 DSCP 24
EXP 3
EXP 3
DSCP 24
EXP 3
EXP 2
DSCP 24
EXP 2
DSCP 16
MPLS Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QOSMPLS – Pipe Mode
45BRKDCN-3346
CE1 PE1 P1 P2 PE2 CE2
DSCP 24 DSCP 24
EXP 3
EXP 3
DSCP 24
EXP 3
EXP 5
DSCP 24
EXP 5
DSCP 24
MPLS Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QoSVXLAN EVPN – VXLAN Encapsulation
• Ingress L3 packet, original priority is mapped to outer header priority
• Ingress L2 frame, COS value will be mapped to outer priority
• VLAN header is not preserved in VXLAN tunnel
46BRKDCN-3346
COS DSCP
0 0
1 8
2 16
3 26
4 32
5 46
6 48
7 56
DSCP 26 COS 3
DSCP 26 DSCP 26
Original L3 Packet
VXLAN Encap. Packet
N/A COS 3
N/A DSCP 26
Original L2 Frame
VXLAN Encap. Packet
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QoS
• DSCP value is derived based on a priority mode for L3 traffic:
• Uniform mode: delivers overlay priority copying outer header to decapsulated frame
• Pipe mode: extends original priority copying inner header to decapsulated frame
• Marking can be configure on the egress VTEP mark decapsulated traffic with priority (COS, DSCP)
VXLAN EVPN – VXLAN Decapsulation
47BRKDCN-3346
DSCP 26 DSCP 26
DSCP 26 COS 0
DSCP 26 DSCP 26
DSCP 26 COS 0
Uniform Mode
Pipe Mode
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QoSVXLAN – Uniform Mode
48BRKDCN-3346
http
VXLAN EVPN
VTEP VTEP VTEP VTEP VTEP
Spine Spine
Baremetal
Host A
192.168.10.11
Baremetal
Host B
192.168.10.15
Baremetal
Host C
192.168.11.20
DSCP 26 COS 3
DSCP 26 DSCP 26 DSCP 26 DSCP 26
DSCP 26 COS 0
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Overlay QoSVXLAN – Pipe Mode
49BRKDCN-3346
http
VXLAN EVPN
VTEP VTEP VTEP VTEP VTEP
Spine Spine
Baremetal
Host A
192.168.10.11
Baremetal
Host B
192.168.10.15
Baremetal
Host C
192.168.11.20
DSCP 26 COS 3
DSCP 26 DSCP 26 DSCP 26 DSCP 26
DSCP 26 COS 0
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 50
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 9000 Overview
• Modular and Fixed chassis
• Optimized for high density 10G/25G/40G/100G
• Standalone and ACI Mode
• Built with Cisco Silicon
• Advanced QoS capabilities
52BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
LSE
• 1.8T chip – 2 slices of 9 x 100G each
• X9700-EX modular linecards; 9300-EX TORs
LS1800FX
• 1.8T chip – 1 slice of 18 x 100G with MACSEC
• X9700-FX modular linecards; 9300-FX TORs
S6400
• 6.4T chip – 4 slices of 16 x 100G each
• E2-series fabric modules; 9364C TOR
LS3600FX2
• 3.6T chip – 2 slices of 18 x 100G with MACSEC + CloudSec
• 9300-FX2 TORs
Nexus 9000 - Cloud Scale
53BRKDCN-3346
Slice 0
900G
Slice Interconnect
Slice 1
900G
LSE – 18 x 100G
Slice 0
1.6T
Slice Interconnect
Slice 1
1.6T
Slice 2
1.6T
Slice 3
1.6T
S6400 – 64 x 100G
Slice 0
1.8T
LS1800FX – 18 x 100G
Slice 0
1.8T
Slice Interconnect
Slice 1
1.8T
LS3600FX2 – 36 x 100G
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
What Is a “Slice”?
• Self-contained forwarding complex controlling subset of ports on single ASIC
• Separated into Ingress and Egress functions
• Ingress of each slice connected to egress of all slices
• Slice interconnect provides non-blocking any-to-any interconnection between slices
54BRKDCN-3346
SliceInterconnectIngress Slice 1
Egress Slice 1
Ingress Slice 2
Egress Slice 2
Ingress Slice n
Egress Slice n
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Cisco Nexus 9000 QoS Features
• Traffic classification
• DSCP, CoS, IP Precedence and ACL
• Packet marking
• DSCP, CoS, and ECN
• Strict Priority Queuing and DWRR
• Ingress and egress policing
• Tail Drop and WRED with ECN
• Shared buffer capability
• Egress Queuing55BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Buffering
56BRKDCN-3346
• Cloud Scale platforms implement shared-memory egress buffered architecture
• Each ASIC slice has dedicated buffer – only ports on that slice can use that buffer
• Dynamic Buffer Protection adjusts max thresholds based on class and buffer occupancy
• Intelligent buffer options maximise buffer efficiency
Slice 018.7MB
Slice Interconnect
Slice 118.7MB
LSE18.7MB/slice(37.4MB total)
Slice 010.2MB
Slice 110.2MB
Slice 210.2MB
Slice 310.2MB
S640010.2MB/slice(40.8MB total)
Slice 040.8MB
LS1800FX40.8MB/slice (40.8MB total)
Slice 020MB
Slice Interconnect
Slice 120MB
LS3600FX220MB/slice (40MB total)
Slice Interconnect
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Queuing and Scheduling
57BRKDCN-3346
• 8 user classes and 16 queues per output port (8 unicast, 8 multicast)
• QOS-group drives class; egress queuing policy defines class priority and weights
• Dedicated classes for CPU traffic and SPAN traffic
Best Effort
Configurable Weights / PriorityStrictPriority
Class 0 Class 1 Class 2 Class 3 Class 4 Class 5 Class 6 Class 7
Egress Port
UC0 MC0 UC1 MC1 UC2 MC2 UC3 MC3 UC4 MC4 UC5 MC5 UC6 MC6 UC7 MC7
CPU SPAN
Final Winner
50/50 DWRR
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Intelligent Buffering
• Dynamic Buffer Protection (DBP) – Controls buffer allocation for congested queues in shared-memory architecture
• Approximate Fair Drop (AFD) – Maintains buffer headroom per queue to maximize burst absorption
• Dynamic Packet Prioritization (DPP) – Prioritizes short-lived flows to expedite flow setup and completion
Innovative Buffer Management for Cloud Scale switches
58BRKDCN-3346
Miercom Report: Speeding Applications in Data Centre Networkshttp://miercom.com/cisco-systems-speeding-applications-in-data-center-networks/
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Dynamic Buffer Protection (DBP)
• Prevents any output queue from consuming more than its fair share of buffer in shared-memory architecture
• Defines dynamic max threshold for each queue
• If queue length exceeds threshold, packet is discarded
• Otherwise packet is admitted to queue and scheduled for transmission
• Threshold calculated by multiplying free memory by configurable, per-queue Alpha (α) value (weight)
• Alpha controls how aggressively DBP maintains free buffer pages during congestion events
59BRKDCN-3346
α
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Alpha Parameter Examples
60BRKDCN-3346
0
5
10
15
20
25
30
35
40
1 2 4 8 16 32 64
Buff
er
in M
B
Number of Congested Queues
Alpha (α) = 0.5
Buffer per queue (MB) Free buffer (MB)
0
5
10
15
20
25
30
35
40
1 2 4 8 16 32 64
Buff
er
in M
B
Number of Congested Queues
Alpha (α) = 14
Buffer per queue (MB) Free buffer (MB)
Default Alpha onCloud Scale switches
0
5
10
15
20
25
30
35
40
1 2 4 8 16 32 64
Buff
er
in M
B
Number of Congested Queues
Alpha (α) = 1
Buffer per queue (MB) Free buffer (MB)
Buffer per queue == free buffer
Buffer per queue == ½ free buffer Buffer per queue ==
14 x free buffer
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Buffering – Ideal versus Reality
61BRKDCN-3346
Sustained-bandwidth TCP flows consume all available buffer before
backing off
Sustained-bandwidth TCP flows back off before all buffer
consumed
Buffer available for burst absorption
Buffer consumed by sustained-bandwidth TCP flows
Ideal buffer state
Buffer available for burst absorption
Buffer consumed by sustained-bandwidth TCP flows
Actual buffer state
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Approximate Fair Drop (AFD)
62BRKDCN-3346
Maintain throughput while minimizing buffer consumption by elephant flows – keep buffer state as close to the ideal as possible
Distinguish elephant flows from other flows
Higher-bandwidth elephants – higher AFD drop probability
Lower-bandwidth elephants – lower AFD drop probability
Non-elephants – no AFD
Queue admission
Ideal depth exceeded?
AFD set?
N
Y
Y
N
Buffer
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Dynamic Packet Prioritization (DPP)
63BRKDCN-3346
• Prioritize initial packets of new / short-lived flows
• Up to first 1023 packets of each flow assigned to higher-priority qos-group
> 1023 packets
<= 1023 packets
Track per-flow packet count
Drive new, higher priority
Maintain original priority
SP queue
Q-default
Identify unique flows
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Ingress
set dscp
set qos-group
set prec
set cos
Selects queue
Markspacket
Ingress QOS policy Egress Queuing policy
queue-limitpriority
bandwidthAFD
shape Egress
• Default QOS behaviour:
• Trust received QOS markings
• All user data goes to q-default
• To select egress queue, use “set qos-group” in ingress QOS policy
Ingress QOS / Egress Queuing Policies
64BRKDCN-3346
• To set/change packet markings, use “set cos / precedence / dscp” in ingress QOS policy
• To change queuing behaviour, manipulate egress queuing policies
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Putting it all together
65BRKDCN-3346
class-map type qos class_foo
match cos 3-4
policy-map type qos pm1
class type qos class_foo
set qos-group 1
police cir 20 mbytes conform transmit violate drop
class type qos class-default
set qos-group 0
interface ethernet 1/1
service-policy type qos input pm1
class-map type queuing class-foo
match qos-group 1
policy-map type queuing policy-foo
class type queuing class-foo
bandwidth percent 20
class type queuing class-default
bandwidth percent 80
interface ethernet 1/3
service-policy type queuing output policy-foo
Create class-map type qos and
match on
cos/dscp/acls
Create policy-map
type qos and set
qos-group and/or
add policing rule
Attach policy-map
type qos as input to
an interface
Attach policy-map queuing to
interface
Create policy-map
type queuing and
create actions
Create class-map type queuing and
match on qos-
group
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• QoS is enabled by default and cannot be disabled
• CoS and DSCP are TRUSTED by default
• Use QoS-Groups to tie policies together
• Queuing and QoS policies are applied to a physical interface or at system level
Nexus 9000 QoS Golden Rules
66BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 67
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS BRKDCN-3346 68
LC
M-Series ModulesL2/L3/L4 with large forwarding tables and rich feature set
F-Series ModulesHigh performance, low latency with streamlined feature set
1G / 10G
M1
10G / 40G / 100G
M2
10GF1 F2/F2E 10G
F2E10G
F310G / 40G / 100G
F3
10G / 40G / 100G
F3 closes the
F/M feature gap!
M3
10G / 40G / 100G
M3 delivers best of M-
and F-series capabilities
LC
F4 increases
100G port density
F4
100G
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
F3/M3/F4 – Ingress Buffered
69BRKDCN-3346
Virtual
QueuingIngress
Buffer
q1
q2
q3
q4
e2/9…e1/25
Egress Buffer
DWRRSP
e2/9
Multistage Crossbar Fabric
Central Arbiter
Ingress buffer –
Buffers traffic for
congested egress
destinations (VQIs)
INGRESS QUEUING POLICY
Egress buffer – Receives frames
from fabric and schedules traffic
toward egress ports
EGRESS QUEUING POLICY
VOQ buffer
carved by source
and priority4/8 priority levels
per port (VQI)
Virtual queuing –
Congestion management
and local scheduling toward
egress destinations (VQIs)
NETWORK-QOS POLICY
Independent
scheduling for each
destination/priority
Ingress Buffering
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
F3/M3 I/O Module Buffering Capacity
70BRKDCN-3346
Module Total VOQ BufferPer Module
Ingress Queue Structure Ingress VOQ Buffer
M3 48-port 10G 1500MB 4q1t 31.25MB / port
F3 48-port 10G 72MB 4q1t 1.5MB / port
M3 24-port 40G 3000MB 4q1t 125MB / port
F3 24-port 40G 144MB 4q1t 6MB / port
Module Egress VOQ Structure Egress VOQ Buffer (Credited) Egress VOQ Buffer (Uncredited)
M3 48-port 10G 1p7q1t 512KB / port 4MB / 24 ports
F3 48-port 10G 1p7q1t 295KB / port 512KB / 8 ports
M3 24-port 40G 1p7q1t 2MB / port 4MB / 6 port
F3 24-port 40G 1p7q1t 1.1MB / port 512KB / 2 ports
Ingress
Egress
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Ingress Queuing – Template View
71BRKDCN-3346
CoS 0-4(Q-Default)
CoS 5-7(Q1)
8e Template
CoS 3(Q4)
CoS 5-7(Q1)
7e Template
CoS 0,1(Q-Default)
CoS 2,4(Q3)
CoS 0-2(Q-Default)
CoS 5-7(Q1)
6e Template
CoS 4(Q3)
CoS 3(Q4)
CoS 0(Q-Default)
CoS 5-7(Q1)
4e Template
CoS 4(Q3)
CoS 1-3(Q4)
High (Pause)
ThresholdLow (Resume)
Threshold
Legend:
Drop Queue
No-Drop Queue
Pause Active
8e-4q4q Template
CoS 3-4(Q3)
CoS 5-7(Q1)
CoS 2(Q4)
CoS 0-1(Q-Default)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Egress Queuing – Logical View
72BRKDCN-3346
Eg
ress P
ort Q2
PQ
1
Q3
Q-D
ef
default-4q-7e-out-policy
Q-Def.
(0,1)
PQ1
(5,6,7)
Q3
(2,4)
Q2
(3)
DWRR
Priority
DWRR
50% 50%
Eg
ress P
ort
PQ
2 (
H)
PQ
3 (
L)
PQ
1
Q-D
ef
default-4q-6e-out-policy
Q-Def.
(0-2)
PQ3
(3)
PQ1
(5,6,7)
PQ2.
(4)
DWRR
PrioPrio
DWRR
100%
Eg
ress P
ort
PQ
1 (
H)
Q-D
ef
PQ
2 (
L)
Q3
default-4q-4e-out-policy
Q3
(1,2,3)
Q-Def.
(0)
PQ2
(4)
PQ1
(5,6,7)
DWRR DWRR
PrioPrio
DWRR
100% 100%
Green indicates no-drop
Eg
ress P
ort
PQ
1
Q2
Q3
Q-D
ef
DWRR
default-4q-8e-out-policy
Q-Def.
(0,1)
Q2
(3,4)
Q3
(2)
PQ1
(5,6,7)
Priority
33%33%33%
Eg
ress P
ort
PQ
1
Q2
Q3
Q-D
ef
DWRR
default-4q4q-8e-out-policy
Q-Def.
(0,1)
Q2
(3,4)
Q3
(2)
PQ1
(5,6,7)
Priority
33%33%33%
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
DSCP to CoS / CoS to DSCP – Mapping Tables
73BRKDCN-3346
N7k# show table-map | grep -a 2 dscp-
cos-map
Table-map dscp-cos-map
default copy
N7k# show table-map | grep -a 2 cos-
dscp-map
Table-map cos-dscp-map
default copy
N7k# show system internal ipqos global-
defaults | grep -a 12 dscp-cos-map
table-map: dscp-cos-map (len: 12)
default copy
Bit array:
Values set:
0 0 0 0 0 0 0 0
1 1 1 1 1 1 1 1
2 2 2 2 2 2 2 2
3 3 3 3 3 3 3 3
4 4 4 4 4 4 4 4
5 5 5 5 5 5 5 5
6 6 6 6 6 6 6 6
7 7 7 7 7 7 7 7
N7k# show system internal ipqos global-
defaults | grep -a 12 cos-dscp-map
table-map: cos-dscp-map (len: 12)
default copy
Bit array:
Values set:
0 8 16 24 32 40 48 56
-- -- -- -- -- -- -- --
-- -- -- -- -- -- -- --
-- -- -- -- -- -- -- --
-- -- -- -- -- -- -- --
-- -- -- -- -- -- -- --
-- -- -- -- -- -- -- --
-- -- -- -- -- -- -- --
DSCP 24-31
mapped to
CoS 3CoS 2
mapped to
DSCP 16-23
Note: Output taken from Nexus 7000
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
CoS or DSCP to Queue Mapping
• Default CoS to Queue Mapping for Nexus 7000/7700 (F- and M-Series I/O Module)
• Ingress: CoS to Queue
• Egress: CoS to Queue
• DSCP to Queue Mapping for Nexus 7000/7700 (F- and M-Series I/O Module)
• Ingress: DSCP to Queue
• Egress: CoS to Queue
• Global Configuration (Admin/Default VDC) required to enable DSCP to Queue Mapping:
74BRKDCN-3346
N7k(config)# hardware qos dscp-to-queue ingress module type {all | f-series | m-series}
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
802.1q Trunk
Changing the Default Trust
75BRKDCN-3346
802.1q Trunk /
Access Port
Ingress Queues
Egress Queues
routed/bridged
CoS
CoS
q-1
q-n
Note: CoS is used for egress
queue selection, even if the
egress interface does NOT
carry CoS in the frame
q-default
Set CoS 0(will only set CoS to 0) data
L2CoS [0]
L3DSCP [24]
Set DSCP 0(will set DSCP + CoS to 0)
L3DSCP [0]
data
L2CoS [0]
L3DSCP [0]
data
L2CoS [2]
L3DSCP [24]
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Routed Traffic
• If CoS and DSCP is present• CoS is used for ingress queue selection
• DSCP is preserved and rewrites CoS (top most 3bit)
• CoS is used for egress queue selection
• If only DSCP is present• No CoS gets treated as CoS 0 on ingress
• DSCP is preserved and rewrites CoS (top most 3bit)
• CoS (derived from DSCP) drives egress queue selection
Default Rules Summary
76BRKDCN-3346
Bridged Traffic
• If CoS and DSCP is present• CoS is used for ingress queue selection
• CoS is preserved
• DSCP is unmodified
• CoS is used for egress queue selection
• If only DSCP is present• No CoS gets treated as CoS 0 on ingress
• CoS 0 is used for ingress and egress queue selection
• DSCP is unmodified
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 7000 QoS Golden Rules
• QoS is enabled by default and cannot be disabled
• CoS and DSCP are TRUSTED by default
• Default Queuing and QoS policies are applied to all physical interfaces across all VDCs
• For bridged traffic, CoS is preserved, DSCP is unmodified
• For routed traffic, DSCP is copied to CoS(first 3 bits)
• Ex: DSCP 40 (b101000) becomes CoS 5 (b101)
77BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 78
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 5000 Series Overview
79BRKDCN-3346
CU
ST
OM
ER
VA
LU
E
CIS
CO
INN
OV
AT
ION
Scalability (Large Buffers
and Tables)
Fabric Innovations
VXLAN
Density
Programmability
Network Visibility
LAN/SAN Convergence FabricPath
FEX Architecture
10G\40G
Nexus 5010/5020
Nexus 5500Flexibility
10G Uplinks
Nexus 5600High 10G Density
40G Flexibility100G UplinksUnified Ports
Buffers/Tables
20K+ Customers Over 5 Years
25M+ Ports Shipped
125K+Chassis Shipped
75%+ Market Share*
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Key Concepts – Common Points
• Nexus 5000/6000 and Nexus 7000 F-Series I/O Modules share the Ingress Buffer Model
• Ingress buffering and queuing occur at VOQ of each ingress port
• Egress scheduling enforced by egress port
• No Egress QOS Policies
Nexus 7000 compared to Nexus 5000 QoS
80BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Cisco Nexus 5600 QoS Features
• Traffic classification
• DSCP, CoS, IP Precedence and ACL
• Packet marking
• DSCP, CoS, and ECN
• Strict Priority Queuing and DWRR
• Priority Flow Control
• DCBX 802.1Qaz
• Ingress policing (No egress policing)
• Flexible buffer management
81BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
UPC 1
24xSFP+
Fabric
6xQSFP+ CPU
Supervisor
UPC-0
Cisco Nexus 5672UP Internal Architecture
82BRKDCN-3346
UPC 2 UPC 3 UPC 4 UPC 5 UPC 6
24xSFP+
FC PHY
Slot 1 Slot 2
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Packet Buffering
83BRKDCN-3346
• 25MB packet buffer is shared by every three 40 GE ports or twelve 10 GE ports.
• Buffer is 16MB at ingress and 9MB at egress.
• Unicast packet can be buffered at both ingress and egress.
• Multicast Buffered at egress only
448
Gbps224
Gbps
Ingress
UPCEgress UPC
Un
icast V
OQ
Mu
ltic
ast V
OQ
Unified
Crossbar
Fabric
16MB9MB
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Flexible Buffer Management
• Shared buffer is good for burst absorption.
• Dedicated buffer is good for predictable performance for each port.
• On by default, no configuration needed
• Long-distance FCoE, video editing (i.e., AVID), Big Data, and distributed storage
Ingress Buffer
84BRKDCN-3346
Port 1 Dedicated
Port 2 Dedicated
Port 3 Dedicated
Shared Packet Buffer
SPAN Control
UPC Ingress Buffer (16MB)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Default Ingress Buffer Allocation
• Each cell is 320 bytes.
• Total number of cells for ingress buffer is 48,840.
85BRKDCN-3346
Control traffic (per port) 64 KB 67.2 KB
SPAN (per port) 38.4 KB 153.6 KB
Class default (per port) 100 KB 100 KB
Shared buffer 13.2 MB 14.7 MB
Buffer Pool 10 GE Port 40 GE Port
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Tune Buffer Allocation at Ingress
• “queue-limit” under “network-qos” policy specifies the dedicated buffer for each port and each class. The dedicated buffer can be used by the port for only that class of service.
• Without “queue-limit” each class of service will get 100 KB of dedicated buffer.
• The size of dedicated buffer can be different for different classes of service. The policy applies to all ports in the chassis.
• Total ingress buffer minus the dedicated buffer and buffer for control and SPAN will be in the shared buffer pool.
• The following example sets the dedicated buffer for “class-default” to be 400 KB for all ports.
86BRKDCN-3346
switch(config)# policy-map type network-qos Policy-buffer
switch(config-pmap-nq)# class type network-qos class-default
switch(config-pmap-nq-c)# queue-limit 400000 bytes
switch(config-pmap-nq-c)# system qos
switch(config-sys-qos)# service-policy type network-qos Policy-buffer
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Flexible Buffer Management
• 9-MB packet buffer is shared among three 40 GE or twelve 10 GE.
• CLI is provided to allocate buffer from unicast to multicast.
• Unicast traffic can be buffered at egress and ingress.
• Multicast is buffered at egress in case of interface oversubscription.
Egress Buffer
87BRKDCN-3346
Multicast Buffer
UPC Egress Buffer (9MB)
Unicast Buffer
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Default Egress Buffer Allocation
• Software provides CLI to tune the egress buffer allocation.
• At egress, unicast buffer is allocated on a per-port basis. For multicast, the egress buffer is shared among all ports.
• Use ”hardware multicast-buffer-tune” to assign unicast buffer to multicast pool on egress
88BRKDCN-3346
Buffer pool 10GE Port 40GE Port
Unicast (per port) 363 KB650KB with 10G fabric mode635KB with 40G fabric mode
Multicast (per ASIC) 4.3 MB 6.6 MB
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Uses QOS-Groups to tie together QoS, Queuing and Network-QoS policies
• QoS-Group has no direct relation with priority values
• QoS-Groups defined (set) in policy-map type qos.
• QoS-groups referenced (match) in policy type queuing and policy-map type network-qos
Nexus 5600/6000 QoS Configuration Model
89BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Putting it all together
90BRKDCN-3346
class-map type qos class_foo
match cos 3-4
policy-map type qos pm1
class type qos class_foo
set qos-group 1
class type qos class-default
set qos-group 0
interface ethernet 1/1
service-policy type qos input pm1
class-map type queuing class-foo
match qos-group 1
policy-map type queuing policy-foo
class type queuing class-foo
bandwidth percent 20
class type queuing class-default
bandwidth percent 80
interface ethernet 1/3
service-policy type queuing input policy-foo
Create class-map type qos and
match on
cos/dscp/acls
Create policy-map
type qos and set
qos-group and/or
add policing rule
Attach policy-map
type qos as input to
an interface
Attach policy-map queuing to
interface
Create policy-map
type queuing and
create actions
Create class-map type queuing and
match on qos-
group
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Buffering Capacity
91BRKDCN-3346
Traffic Type Ingress Queue Structure 10 GE Port 40 GE Port
Control traffic (per port) 6q1t 64 KB 67 KB
Span Traffic (per Port)6q1t
38.4 KB 154 KB
Class Default (per Port)6q1t
100 KB 100 KB
Shared Buffer6q1t
13.2 MB 14.7 MB
Traffic Type Egress Queue Structure 10 GE Port 40 GE Port
Unicast 1p5q0t
363 KB650 KB with 10GB Fabric Mode635 KB with 40GB Fabric Mode
Multicast1p5q0t
4.3MB 6.6 MB
Ingress
Egress
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 5600 QoS Golden Rules
• WRED is enabled by default and cannot be disabled
• CoS and DSCP are TRUSTED by default
• Use QoS-Groups to tie policies together
• No Egress QOS policies
92BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 93
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS 94BRKDCN-3346
Nexus 3000 Series Switches
• Programmable pipeline
• Support for P4-INT
• Enable custom use cases
• Includes Tofino and Teralynx ASICs
Nexus 3400
• Ultra Low Latency
• Financial/HFT workloads
• Based on Cisco Monticello ASICs
Nexus 3500
• Deep Buffer
• High route scale
• Video and Drop sensitive deployments
• Based on Jericho ASIC family
Nexus 3600
• Fixed High Density
• High throughput and performance
• Flexible connectivity options
• Based on Tomahawk ASIC family
Nexus 3200
• ToR Leaf
• Full-featured DC access
• Broad switch portfolio
• Based on Trident ASIC family
Nexus 3100
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Cisco Nexus 3000 QoS Features
• Traffic classification
• DSCP, CoS, IP Precedence and ACL
• Packet marking
• DSCP, CoS, and ECN
• Strict Priority Queuing and DWRR
• Tail Drop and WRED with ECN
• Shared buffer capability
• Egress Queuing
• 3-level hierarchical scheduling95BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Hardware Scheduler Implementation
• 3 level scheduling hierarchy
96BRKDCN-3346
S1S2S3
UC0
UC1
UC7
MC0
MC3
Control
traffic
UC winner
MC winner
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Dynamic Buffer Protection
• Buffer is shared dynamically any queue can use shared buffer
• Dynamic Buffer Protection prevents any queue unfair use shared buffer
• The basic algorithm uses dynamic queue length threshold, and account for usage of unicast and multicast
97BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• QoS is enabled by default and cannot be disabled
• CoS and DSCP are TRUSTED by default
• Use QoS-Groups to tie policies together
• Queuing and QoS policies are applied to a physical interface or at system level
Nexus 3000 QoS Golden Rules
98BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 99
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Scalable and Extensible Fabric
• Single point of management
• Homogeneous and consistent policies
FEX Overview
100BRKDCN-3346
By Author listed as "U.S. Air Force photo" [Public domain], via Wikimedia Commons
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• Traffic classification
• DSCP, CoS
• ACL classification (FEX offload) onNexus 5600/6000
• Strict Priority Queuing and DWRR
• Priority Flow Control
• Queue-limit Carving
Cisco Nexus 2000 QoS Features
101BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
FEX Policy Offload (Nexus 5600/6000 only)
• TCAM resources on a FEX to perform ACL-based classification
• The feature is disabled by default
• By default, a FEX classifies packets on CoS value
• Both system level and interface level policies are offloaded to the FEX
102BRKDCN-3346
switch# configure terminal
fex chassis_ID
hardware card-type qos-policy-offload
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
FEX Policy with Nexus 9000 as parent
• The FEX QoS policy is applied to the hardware resources of the fabric port associated with the FEX HIF port
• Classification is based on the COS value.
• System level input queueing for DWRR and Strict priority scheduling for HIF to NIF traffic and for NIF to HIF traffic
• Queuing:
• 4 queues are present on the FEX
• The scheduling is done per port and each port has its own scheduler.
103BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
FEX Queuing Policies – Nexus 7000
• On Nexus 7000 with FEX + M-Series parent modules, network-qos and F-series ingress queuing class-maps drive FEX queuing configuration
• Ingress queuing class-maps drive:
• Both ingress and egress COS/DSCP-to-queue mapping
• Enabling DSCP-to-queue on parent switch enables DSCP-to-queue on FEX
• DSCP-to-queue only active in the HIF→NIF direction
• NIF→HIF direction always uses COS-to-queue mapping, based on COS transmitted by parent switch to FEX
104BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
FEX Queue-Limit – Nexus 7000
• Provides FEX queue-limit configuration option
• Manages buffer thresholds on FEX based on platform capabilities
• Default has queue-limit enabled
• Configuration applied per-VDC (on Nexus 7000/7700)
• Different FEX models have different capabilities
105BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 2000 QoS Golden Rules
• FEX QOS classification on COS or DSCP unless FEX offload enabled
• FEX queuing driven implicitly by parent switch queuing configuration
• No support for per-queue shaping, policing or marking
• Drop thresholds are tail-drop only, no WRED support
106BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 107
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
What do we want to achieve?Company XYZ’s Business Goals
108BRKDCN-3346
• Make sure no disruption in network services
• Put control traffic in priority queue
• Video/voice hosting also an business objective
• Put voice traffic in priority queue
• Dedicated bandwidth to video traffic
• Flexibility in moving applications across servers
• Dedicated bandwidth to vmotion/mobility
• Everything else best-effort
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Translating to the language of QoS
109BRKDCN-3346
Application CoSQueuing
(Scheduling)Queue-Limit
(Buffer)Character
Best Effort 0, 1BW remaining
50%60%
High Volume /Less Important
vMotion / LiveMigration
2BW remaining
20%10%
Medium Volume / Important
Multimedia 3, 4BW remaining
30%20%
Medium VolumeVery Important
Strict Priority 5
Priority Queue 10%
Low Volume / Important /
Delay Sensitive
Network Control 6,7Low Volume / Very important
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Topology
110BRKDCN-3346
Nexus 7000 Nexus 7000
Nexus 9000 Nexus 9000 Nexus 5000Nexus 5000 Nexus 9000 Nexus 9000
Nexus 2000 Nexus 2000 Nexus 2000 Nexus 2000 Nexus 2000 Nexus 2000
M3 cards facing
core and M3/F3
cards facing
access
VPC from
access to
aggregation
Host VPC,
Straight-through
FEX
Enhanced VPC
(evPC)
Straight-through
FEX, No VPC
vpc peer-link
Core
vpc peer-linkvpc peer-link vpc peer-link
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Classification, Marking and Trust on Nexus 5000/7000/9000
111BRKDCN-3346
Between the different Tiers,
all ports are TRUSTED
Mark Traffic from Core(policy-map type qos)or just TRUST (default)
Mark Traffic from Servers(policy-map
type qos)or just TRUST
(default)
Type:QoS
vpc peer-link
Core
vpc peer-linkvpc peer-link vpc peer-link
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
ip access-list ACL_QOS_LOWPRIO
10 permit …
ip access-list ACL_QOS_VMOTION
10 permit …
ip access-list ACL_QOS_MULTIMEDIA
10 permit …
ip access-list ACL_QOS_STRICTPRIO
10 permit …
!
class-map type qos match-any CM_QOS_LOWPRIO_COS1
match access-group name ACL_QOS_LOWPRIO
!
class-map type qos match-any CM_QOS_VMOTION_COS2
match access-group name ACL_QOS_VMOTION
!
class-map type qos match-any CM_QOS_MULTIMEDIA_COS4
match access-group name ACL_QOS_MULTIMEDIA
!
class-map type qos match-any CM_QOS_STRICTPRIO_COS5
match access-group name ACL_QOS_STRICTPRIO
Classification and Marking: Nexus 7000
112BRKDCN-3346
policy-map type qos PM_QOS_MARK_COS_IN
class CM_QOS_STRICTPRIO_COS5
set cos 5
class CM_QOS_MULTIMEDIA_COS4
set cos 4
class CM_QOS_VMOTION_COS2
set cos 2
class CM_QOS_LOWPRIO_COS1
set cos 1
!
interface Ethernet1/1
service-policy type qos input PM_QOS_MARK_COS_IN
!
vlan configuration 100
service-policy input PM_QOS_MARK_COS_IN
Type:QoS
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
ip access-list ACL_QOS_LOWPRIO
10 permit …
ip access-list ACL_QOS_VMOTION
10 permit …
ip access-list ACL_QOS_MULTIMEDIA
10 permit …
!
class-map type qos match-any CM_QOS_LOWPRIO_COS1
match access-group name ACL_QOS_LOWPRIO
!
class-map type qos match-any CM_QOS_VMOTION_COS2
match access-group name ACL_QOS_VMOTION
!
class-map type qos match-any CM_QOS_MULTIMEDIA_COS4
match access-group name ACL_QOS_MULTIMEDIA
!
class-map type qos match-any CM_QOS_STRICTPRIO_COS5
match cos 5
Classification and Marking: Nexus 5600 (1)
113BRKDCN-3346
policy-map type qos PM_QOS_MARK_COS_IN
class CM_QOS_STRICTPRIO_COS5
set qos-group 5
class CM_QOS_MULTIMEDIA_COS4
set qos-group 4
class CM_QOS_VMOTION_COS2
set qos-group 3
class CM_QOS_LOWPRIO_COS1
set qos-group 2
!
system qos
service-policy type qos input PM_QOS_MARK_COS_IN
QoS-Group # is mapping between Slide 1 and Slide 2
Type:QoS
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
class-map type network-qos CM_N-QOS_MATCH_QG2_COS1
match qos-group 2
class-map type network-qos CM_N-QOS_MATCH_QG3_COS2
match qos-group 3
class-map type network-qos CM_N-QOS_MATCH_QG4_COS4
match qos-group 4
class-map type network-qos CM_N-QOS_MATCH_QG5_COS5
match qos-group 5
Classification and Marking: Nexus 5600 (2)
114BRKDCN-3346
policy-map type network-qos PM_N-QOS_SYSTEM
class type network-qos CM_N-QOS_MATCH_QG2_COS1
set cos 1
class type network-qos CM_N-QOS_MATCH_QG3_COS2
set cos 2
class type network-qos CM_N-QOS_MATCH_QG4_COS4
set cos 4
class type network-qos CM_N-QOS_MATCH_QG5_COS5
set cos 5
queue-limit 20480 bytes
!
system qos
service-policy type network-qos PM_N-QOS_SYSTEM
QoS-Group # is mapping between Slide 1 and Slide 2
Type:Networ-QoS
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
ip access-list ACL_QOS_LOWPRIO
10 permit …
ip access-list ACL_QOS_VMOTION
10 permit …
ip access-list ACL_QOS_MULTIMEDIA
10 permit …
!
class-map type qos match-any CM_QOS_LOWPRIO_COS1
match access-group name ACL_QOS_LOWPRIO
!
class-map type qos match-any CM_QOS_VMOTION_COS2
match access-group name ACL_QOS_VMOTION
!
class-map type qos match-any CM_QOS_MULTIMEDIA_COS4
match access-group name ACL_QOS_MULTIMEDIA
!
class-map type qos match-any CM_QOS_STRICTPRIO_COS5
match cos 5
Classification and Marking: Nexus 9000
115BRKDCN-3346
policy-map type qos PM_QOS_MARK_COS_IN
class CM_QOS_STRICTPRIO_COS5
set qos-group 5
set cos 5
class CM_QOS_MULTIMEDIA_COS4
set qos-group 4
set cos 4
class CM_QOS_VMOTION_COS2
set qos-group 3
set cos 2
class CM_QOS_LOWPRIO_COS1
set qos-group 2
set cos 1
!
system qos
service-policy type qos input PM_QOS_MARK_COS_IN
Type:QoS
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Network-QoS Configuration on M3/F3-Series
116BRKDCN-3346
Use the network-qos policy for 8e-
4q4q i.e 4 ingress queues
vpc peer-link
Core
vpc peer-linkvpc peer-link vpc peer-link
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Network-QoS Configuration –M3/F3 cardsExample (Admin- / Default-VDC)
117BRKDCN-3346
vpc peer-link
vpc peer-link
Core
system qos
service-policy type network-qos default-nq-8e-4q4q-policy
policy-map type network-qos default-nq-8e-4q4q-policy template 8e-4q4q
class type network-qos c-nq-8e-4q4q
match cos 0-7
congestion-control tail-drop
mtu 1500
Admin-
VDC
Admin-
VDC
Changes apply to ALL ports of specified type in ALL VDCsChanges are traffic disruptive for ports of specified type
Type:Network-QoS
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Queuing (M3/F3 cards)
118BRKDCN-3346
Modify CoS to Queue mapping in Admin-
/Default-VDC
Assign a ingress policy-map for buffer allocation, no
ingress scheduling
Assign a egress policy-map to each interface with
priority, bandwidth and queue-limit to alter default
queuing policy
Type:Queuing
vpc peer-link
Core
vpc peer-linkvpc peer-link vpc peer-link
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
CoS to Queue Mapping – M3/F3 I/O ModuleExample
119BRKDCN-3346
Application CoSQueuing
(Scheduling)-egress
Queue-Limit(Buffer)-ingress
Queue(Ingress/Egress)
Character
Best Effort 0,1 BW remaining
50%50%
4q1t-8e-4q4q-in-q-default / 1p3q1t-8e-4q4q-out-q-
default
High Volume /Less Important
vMotion / LiveMigration
2BW remaining
20%10%
4q1t-8e-4q4q-in-q4 /1p3q1t-8e-4q4q-out-q3
Medium Volume / Important
Multimedia 3, 4BW remaining
30%30%
4q1t-8e-4q4q-in-q3 /1p3q1t-8e-4q4q-out-q2
Medium VolumeVery Important
Strict Priority 5
Priority Queue 10%4q1t-8e-4q4q-in-q1 /
1p3q1t-8e-4q4q-out-pq1
Low Volume / Important /
Delay Sensitive
Network Control 6/7Low Volume / Very important
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
CoS to Queue Configuration –M3/F3 slidesExample (Admin- / Default-VDC)
120BRKDCN-3346
vpc peer-link
vpc peer-link
Coreclass-map type queuing match-any 4q1t-8e-4q4q-in-q1
match cos 5-7
class-map type queuing match-any 4q1t-8e-4q4q-in-q-default
match cos 0-1
class-map type queuing match-any 4q1t-8e-4q4q-in-q3
match cos 3-4
class-map type queuing match-any 4q1t-8e-4q4q-in-q4
match cos 2
class-map type queuing match-any 1p3q1t-8e-4q4q-out-pq1
match cos 5-7
class-map type queuing match-any 1p3q1t-8e-4q4q-out-q2
match cos 3-4
class-map type queuing match-any 1p3q1t-8e-4q4q-out-q3
match cos 2
class-map type queuing match-any 1p3q1t-8e-4q4q-out-q-default
match cos 0-1
Admin-
VDC
Admin-
VDC
Changes apply to ALL ports of specified type in ALL VDCsChanges are traffic disruptive for ports of specified type
Type:Queuing
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Ingress Queuing Configuration for M3/F3 cardsExample (Payload-VDC)
121BRKDCN-3346
qos copy policy-map type queuing default-8e-4q4q-in-policy prefix
Custom-
policy-map type queuing Custom-8e-4q4q-in
class type queuing 4q1t-8e-4q4q-in-q1
queue-limit percent 10
bandwidth percent 25
class type queuing 4q1t-8e-4q4q-in-q-default
queue-limit percent 50
bandwidth percent 25
class type queuing 4q1t-8e-4q4q-in-q3
queue-limit percent 30
bandwidth percent 25
class type queuing 4q1t-8e-4q4q-in-q4
queue-limit percent 10
bandwidth percent 25
interface Ethernet1/1
service-policy type queuing input Custom-8e-4q4q-in
All Policy-Map and Service-Policy are done in relevant Payload-VDC and only affect the interface to which they get applied
Type:Queuing
vpc peer-link
vpc peer-link
Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Egress Queuing Configuration for M3/F3 cards Example (Payload-VDC)
122BRKDCN-3346
qos copy policy-map type queuing default-8e-4q4q-out-policy prefix
Custom-
policy-map type queuing Custom-8e-4q4q-out
class type queuing 1p3q1t-8e-4q4q-out-pq1
priority level 1
class type queuing 1p3q1t-8e-4q4q-out-q2
bandwidth remaining percent 30
class type queuing 1p3q1t-8e-4q4q-out-q3
bandwidth remaining percent 20
class type queuing 1p3q1t-8e-4q4q-out-q-default
bandwidth remaining percent 50
!
interface Ethernet1/1
service-policy type queuing output Custom-8e-4q4q-out
All Policy-Map and Service-Policy are done in relevant Payload-VDC and only affect the interface to which they get applied
Type:Queuing
vpc peer-link
vpc peer-link
Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
CoS to Queue Mapping - Nexus 9000Example
123BRKDCN-3346
Application CoSQueuing
(Scheduling)Queue limit
(Alpha)Queue
(6q1t / 1p6q0t)Character
Best Effort 0,1BW percent
40%Default (9) qos-group 0 (default)
High Volume /Less Important
vMotion / LiveMigration
2,3BW percent
20%Default (9) qos-group 3
Medium Volume / Important
Multimedia 4BW percent
30%Default (9) qos-group 4
Medium VolumeVery Important
Strict Priority 5BW percent
10%Default (9) qos-group5 / priority
Low Volume / Important /
Delay Sensitive
Network Control 6,7Low Volume / Very important
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Egress Queuing Configuration: Nexus9000Example
124BRKDCN-3346
class-map type queuing CM_Q_MATCH_QG3_COS2
match qos-group 3
class-map type queuing CM_Q_MATCH_QG4_COS4
match qos-group 4
class-map type queuing CM_Q_MATCH_QG5_COS5
match qos-group 5
!
policy-map type queuing PM_QUEUING_SYSTEM_OUT
class type queuing CM_Q_MATCH_QG3_COS2
bandwidth percent 20
class type queuing CM_Q_MATCH_QG4_COS4
bandwidth percent 30
class type queuing CM_Q_MATCH_QG5_COS5
priority
class type queuing class-default
bandwidth percent 50
Type:Queuing
vpc peer-link
vpc peer-link
Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Queuing Nexus 2000
125BRKDCN-3346
Type:Queuing
Queuing on NIF
controlled by Fabric Interface INPUT policy
Queuing on NIF (multiple
no-drop queues) only
available with CoS
based marking on
HIF
vpc peer-link
Core
vpc peer-linkvpc peer-link vpc peer-link
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Queuing Configuration (Nexus 2000)Example
126BRKDCN-3346
class-map type queuing CM_Q_MATCH_QG3_COS2
match qos-group 3
class-map type queuing CM_Q_MATCH_QG4_COS4
match qos-group 4
class-map type queuing CM_Q_MATCH_QG5_COS5
match qos-group 5
!
policy-map type queuing PM_QUEUING_SYSTEM_N2K
class type queuing CM_Q_MATCH_QG3_COS2
bandwidth percent 20
class type queuing CM_Q_MATCH_QG4_COS4
bandwidth percent 30
class type queuing CM_Q_MATCH_QG5_COS5
priority
class type queuing class-default
bandwidth percent 40
Amount of Queues depend on FEX (Nexus 2000) Model
Type:Queuing
vpc peer-link
vpc peer-link
Core
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Agenda
• Introduction
• QoS and Queuing Basics
• QoS Implementation on Nexus
• Nexus 9000 QoS
• Nexus 7000/7700 QoS
• Nexus 5600 QoS
• Nexus 3000 QoS
• Nexus 2000 QoS
• Real World Configuration Examples
• Conclusion
BRKDCN-3346 127
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Why QoS in the Data Centre?
128BRKDCN-3346
Assign Colour to Traffic
MaximiseThroughput
ManageCongestion
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Maximise Throughput and Manage Congestion!
129BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
• End-to-End QoS Network Design: Quality of Service for Rich-Media and Cloud Networks, 2nd Edition
• Tim Szigeti
• Christina Hattingh
• Robert Barton
• Kenneth Briley
• ISBN-10: 1-58714-369-0
• ISBN-13: 978-1-58714-369-4
Recommended Reading
130BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
With some help of my friends
I would like to thank all the people, who started the QoS journey and contributed to it:
• Lukas Krattiger, Principal Engineer
• Tim Stevenson, Distinguished Technical Marketing Engineer
• Matthias Wessendorf, Technical Marketing Engineer
131BRKDCN-3346
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Fex QoS Policy Configuration Example
134BRKDCN-3346
policy-map type qos fex-qos
class fex-qos-class-1
set dscp 10
class fex-qos-class-2
set dscp 18
class fex-qos-class-3
set dscp 26
!
interface Ethernet101/1/1
service-policy type qos input fex-qos
Marking policy
Policy applied on ingress of FEX HIF
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 7000 Network-QoS Configuration Example #1
135BRKDCN-3346
• Applying 8e-4q4q template to enable 4 ingress/egress queues on FEX with COS to queue mapping (also enables 4 ingress queues on F-series modules, if present)
system qos
service-policy type network-qos default-nq-8e-4q4q-policy
• FEX output (“show queuing interface”):Queuing:
queue qos-group cos priority bandwidth mtu
--------+------------+--------------+---------+---------+----
ctrl-hi n/a 7 PRI 0 2400
ctrl-lo n/a 7 PRI 0 2400
2 0 0 1 WRR 30 1600
3 1 2 WRR 30 1600
4 2 5 6 WRR 10 1600
5 3 3 4 WRR 30 1600
Default 8e-4q4q template applied to
“system qos” target
8e4q4q configuration (4 data traffic queues)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Nexus 7000 Network-QoS Configuration Example #2
136BRKDCN-3346
• Applying custom 8e-4q4q-based template with new MTUpolicy-map type network-qos custom-nq-8e-4q4q template 8e-4q4q
class type network-qos c-nq-8e-4q4q
congestion-control tail-drop
mtu 9216
system qos
service-policy type network-qos custom-nq-8e-4q4q
• FEX output (“show queuing interface”) after MTU change:Queuing:
queue qos-group cos priority bandwidth mtu
--------+------------+--------------+---------+---------+----
ctrl-hi n/a 7 PRI 0 2400
ctrl-lo n/a 7 PRI 0 2400
2 0 0 1 WRR 30 9280
3 1 2 WRR 30 9280
4 2 5 6 WRR 10 9280
5 3 3 4 WRR 30 9280
Custom network-qos policy with new MTU
Custom template applied to“system qos” target
MTU increased on data traffic queues
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying CoS- or DSCP-to-Queue Mappings
137BRKDCN-3346
• Changing CoS- or DSCP-to-queue mappings in parent switch F-type ingress queuing class-maps modifies mappings on FEX
• Queuing class-maps modified only in default/admin VDC (apply to entire system)
class-map type queuing match-any 4q1t-8e-4q4q-in-q1
match cos 1-3
match dscp 8-31
class-map type queuing match-any 4q1t-8e-4q4q-in-q-default
match cos 0
match dscp 0-7
class-map type queuing match-any 4q1t-8e-4q4q-in-q3
match cos 4-5
match dscp 32-47
class-map type queuing match-any 4q1t-8e-4q4q-in-q4
match cos 6-7
match dscp 48-63
Queuing:
queue qos-group cos priority bandwidth mtu
--------+------------+--------------+---------+---------+----
ctrl-hi n/a 7 PRI 0 2400
ctrl-lo n/a 7 PRI 0 2400
2 0 0 WRR 30 1600
3 1 6 WRR 30 1600
4 2 1 2 3 WRR 10 1600
5 3 4 5 WRR 30 1600
<…>
queue DSCPs
----- -----
02 0-7,
04 8-31,
03 48-63,
05 32-47,
Non-default F-series
ingress queuing
class-maps (COS and
DSCP match statements
modified)
FEX queue mappings
reflect changes
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Enabling FEX Queue Limits
138BRKDCN-3346
• Example #1 – N2K-C2248TP-1GEfex 101
hardware N2248T queue-limit 50000
• Example #2 – N2K-C2232TM-E-10GEfex 102
hardware N2232TM-E queue-limit 50000
• FEX output (“show queuing interface”) before:Queue limit: Disabled
• FEX output (“show queuing interface”) after (configured queue-limit rounded to nearest hardware supported value):
Queue limit: 51200 bytes
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Egress SOCIngress SOC
Ingress Buffer
F3 10G Buffering Model
140BRKDCN-3346
FA
BR
IC
Egress Buffer
VQI 8
10G Port 1
10G Port 8DW
RR
SP
10G Port 1
10G Port 8
8 priority
levels
1.5MB
4 ingress queues
per port
Virtual Queuing
8K VOQs
(1K Dest + 8 priority levels)
Ingress Buffer – Manages congestion toward
egress destinations
Buffering / queuing
INGRESS QUEUING POLICIES
Egress Scheduling
Central Arbiter
Virtual Queuing / Egress Buffer – Receives
frames from fabric; Schedules frame transmission
Scheduling
EGRESS QUEUING POLICIES
…
VQI 1DW
RR
SP
…
1.5MB
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Egress SOCIngress SOC
Ingress Buffer
F3 40G Buffering Model
141BRKDCN-3346
FA
BR
IC
Egress Buffer
VQI 1
VQI 2
40G Port 1
40G Port 2
DW
RR
SP
DW
RR
SP
40G Port 1
40G Port 2
8 priority
levels4 ingress queues
per port
Virtual Queuing
8K VOQs
(1K VQIs + 8 priority levels)
Ingress Buffer – Manages congestion toward
egress destinations (VQIs)
Buffering / queuing
INGRESS QUEUING POLICIES
Egress Scheduling
Central Arbiter
Virtual Queuing / Egress Buffer – Receives
frames from fabric; Schedules frame transmission
Scheduling
EGRESS QUEUING POLICIES
6MB
6MB
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Egress SOCIngress SOC
Ingress Buffer
F3 100G Buffering Model
142BRKDCN-3346
FA
BR
IC
Egress Buffer
VQI 1 100G Port 1DW
RR
SP100G Port 1
8 priority
levels
12MB
4 ingress queues
per port
Virtual Queuing
8K VOQs
(1K VQIs + 8 priority levels)
Ingress Buffer – Manages congestion toward
egress destinations (VQIs)
Buffering / queuing
INGRESS QUEUING POLICIESEgress Scheduling
Central Arbiter
Virtual Queuing / Egress Buffer – Receives
frames from fabric; Schedules frame transmission
Scheduling
EGRESS QUEUING POLICIES
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
N7k# show policy-map type queuing | beg default 4q-8e
policy-map type queuing default-4q-8e-in-policy
class type queuing 2q4t-8e-in-q1
queue-limit percent 10
bandwidth percent 50
class type queuing 2q4t-8e-in-q-default
queue-limit percent 90
bandwidth percent 50
policy-map type queuing default-4q-8e-out-policy
class type queuing 1p3q1t-8e-out-pq1
priority level 1
class type queuing 1p3q1t-8e-out-q2
bandwidth remaining percent 33
class type queuing 1p3q1t-8e-out-q3
bandwidth remaining percent 33
class type queuing 1p3q1t-8e-out-q-default
bandwidth remaining percent 33
Network-QoS and Default Queuing (global)
143BRKDCN-3346
• default-nq-8e-policy is default network-qos policy and attached to system qosin Admin-/Default-VDC
• The system queuing policy applied by default can be overridden on a per port basis.
Note: show policy-map system does display similar output
2 ingress queues
with buffer ratio
1:9 and DWRR
wieights 1:1
4 egress queues
with one priority
queue and DWRR
wieights 1:1:1
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing and Scheduling Behaviour on F3 Modules
144BRKDCN-3346
I want to… Steps to follow
…remap COS/DSCP values from one queue to another queue without activating additional queues
1. Modify the type queuing class-map(s) for the desired queue(s)
…change queuing behaviour without changing COS-or DSCP-to-queue mapping
1. Define new type queuing policy-map (you cannot modify thedefault policies)
2. Modify class-map parameters3. Apply new policy-map to interfaces
…activate additional queues and remap COS/DSCP values
1. Define new type queuing policy-map2. Modify COS-to-queue mapping for target port type3. Apply new policy-map to interfaces
…shape the SP queue 1. (Optional) Clone the default egress queuing policy2. Shape the SP queue in the new (cloned) policy3. Apply the new queuing policy to the target interfaces
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourRemap Some COS/DSCP Values from One Queue to Another Queue without Activating Additional Queues
145BRKDCN-3346
Important: changing COS- or DSCP-to-queue mapping takes effect immediately and is disruptiveto all ports
Modify “type queuing” class-map(s) for desired
queue(s)
Remap COS- or DSCP-to-queue mapping for given queue(s)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourRemap Some COS/DSCP Values from One Queue to Another Queue without Activating Additional Queues
146BRKDCN-3346
Example: remap COS 4 and DSCP 32-39 to ingress queue “q1”:n77# show class-map type queuing 8q2t-in-q1
Type queuing class-maps
========================
class-map type queuing match-any 8q2t-in-q1
Description: Classifier for ingress queue 1 of type 8q2t
match cos 5-7
match dscp 40-63
n77# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
n77(config)# ! Modify ingress queue q1
n77(config)# class-map type queuing match-any 8q2t-in-q1
n77(config-cmap-que)# ! Change COS- and DSCP-to-queue mapping for this queue
n77(config-cmap-que)# match cos 4
n77(config-cmap-que)# match dscp 32-39
n77(config-cmap-que)# show class-map type queuing 8q2t-in-q1
Type queuing class-maps
========================
class-map type queuing match-any 8q2t-in-q1
Description: Classifier for ingress queue 1 of type 8q2t
match cos 4-7
match dscp 32-63
n77(config-cmap-que)#
Show current
mapping
Show new
mapping
Configure new
mapping
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourChanging Default Queuing Behaviour without Changing COS- or DSCP-to-Queue
147BRKDCN-3346
Define new “type queuing” policy-map for port
type
Create new policy
Modify class-map parameters
Define behaviour of each queue
Important: applying new queuing policy takes effect immediately and is disruptive to any ports to which the policy is applied
Apply “type queuing” service-policy to
interface(s)
Apply new queuing policy to interface(s)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourChanging Default Queuing Behaviour without Changing COS- or DSCP-to-Queue
148BRKDCN-3346
Example: Resize ingress queues without modifying COS- or DSCP-to-queue mapping
n77# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
n77(config)# ! Define new "type queuing" policy
n77(config)# policy-map type queuing new-f3-ingress
n77(config-pmap-que)# ! Define behavior for F3 ingress q-default
n77(config-pmap-que)# class type queuing 8e-4q8q-in-q-default
n77(config-pmap-c-que)# ! Resize this queue
n77(config-pmap-c-que)# queue-limit percent 74
n77(config-pmap-c-que)# ! Define behavior for F3 ingress queue 1
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q1
n77(config-pmap-c-que)# ! Resize this queue
n77(config-pmap-c-que)# queue-limit percent 24
n77(config-pmap-c-que)# ! Policy must include all queues (even inactive)
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q3
n77(config-pmap-c-que)# ! Must give at least 1% to inactive queues
n77(config-pmap-c-que)# queue-limit percent 1
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q4
n77(config-pmap-c-que)# queue-limit percent 1
n77(config-pmap-c-que)# interface e 2/1-48
n77(config-if-range)# ! Apply the new policy to F3 interfaces
n77(config-if-range)# service-policy type queuing input new-f3-ingress
n77(config-if-range)#
Create new
queuing policy
Modify class-map
parameters (resize queues)
Apply policy to
interface(s)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourActivate Additional Queues and Remap COS/DSCP Values
149BRKDCN-3346
Important: changing COS/DSCP-to-queue mapping and takes effect immediately and is disruptive to all ports; applying new queuing policy takes effect immediately and is disruptive to any ports to which the policy is applied
Define new “type queuing” policy-map for port
type
Create new policy
Modify class-map parameters
Define behaviour of each queue
Apply “type queuing” service-policy to
interface(s)
Apply new queuing policy to interface(s)
Modify “type queuing” class-map(s) for desired
queue(s)
Remap COS- or DSCP-to-queue mapping to additional queue(s)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourActivate Additional Queues and Remap COS/DSCP ValuesExample: Enable one additional ingress queue and map COS/DSCP values to all active queues
n77# configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
n77(config)# ! Modify ingress queue q3
n77(config)# class-map type queuing match-any 8q2t-in-q3
n77(config-cmap-que)# ! Map COS and DSCP values to this queue
n77(config-cmap-que)# match cos 3-4
n77(config-cmap-que)# match dscp 24-39
n77(config-cmap-que)# ! Define new "type queuing" policy
n77(config-cmap-que)# policy-map type queuing new-f3-ingress
n77(config-pmap-que)# ! Define behavior for F3 ingress q-default
n77(config-pmap-que)# class type queuing 8e-4q8q-in-q-default
n77(config-pmap-c-que)# ! Resize this queue
n77(config-pmap-c-que)# queue-limit percent 60
n77(config-pmap-c-que)# ! Define behavior for F3 ingress queue 1
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q1
n77(config-pmap-c-que)# ! Resize this queue
n77(config-pmap-c-que)# queue-limit percent 25
n77(config-pmap-c-que)# ! Define behavior for F3 ingress queue 3
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q3
n77(config-pmap-c-que)# ! Resize this queue
n77(config-pmap-c-que)# queue-limit percent 14
n77(config-pmap-c-que)# ! Policy must include all queues (even inactive)
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q4
n77(config-pmap-c-que)# queue-limit percent 1
n77(config-pmap-c-que)# int e 2/1-48
n77(config-if-range)# ! Apply the new policy to F3 interfaces
n77(config-if-range)# service-policy type queuing input new-f3-ingress150BRKDCN-3346
Map COS/DSCP values to
inactive queue
Modify class-map
parameters (resize queues)
Apply policy to
interface(s)
Create new
queuing policy
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Important!
151BRKDCN-3346
• If you change the COS- or DSCP-to-queue mapping for a port type, make sure all ports of that type in all VDCs have a queuing policy applied that defines behaviour for all queues with COS/DSCP values mapped
• For example, if you do THIS…
n77(config)# class-map type queuing match-any 8e-4q8q-in-q-default
n77(config-cmap-que)# match cos 0-1
n77(config-cmap-que)# match dscp 0-15
n77(config-cmap-que)# class-map type queuing match-any 8e-4q8q-in-q4
n77(config-cmap-que)# match cos 2-4
n77(config-cmap-que)# match dscp 16-39
n77(config-cmap-que)# class-map type queuing match-any 8e-4q8q-in-q3
n77(config-cmap-que)# match cos 6-7
n77(config-cmap-que)# match dscp 48-63
n77(config-cmap-que)# class-map type queuing match-any 8e-4q8q-in-q1
n77(config-cmap-que)# match cos 5
n77(config-cmap-que)# match dscp 40-47
Changes the default COS/
DSCP-to-queue mapping
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Important!
152BRKDCN-3346
• … then make sure you do THIS…
n77(config)# policy-map type queuing new-f3-ingress
n77(config-pmap-que)# class type queuing 8e-4q8q-in-q-default
n77(config-pmap-c-que)# queue-limit percent 50
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q1
n77(config-pmap-c-que)# queue-limit percent 20
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q3
n77(config-pmap-c-que)# queue-limit percent 20
n77(config-pmap-c-que)# class type queuing 8e-4q8q-in-q4
n77(config-pmap-c-que)# queue-limit percent 10
n77(config-pmap-c-que)#
Defines a new queuing policy that defines
behaviour of all queues that COS/DSCP
values have been mapped to
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Important!
153BRKDCN-3346
• … and then do THIS:
n77(config)# int e 2/1-48
n77(config-if-range)# service-policy type queuing input new-f3-ingress
n77(config-if-range)#
• If you DON’T, traffic arriving on ports with default policy (i.e., without all queues activated that have COS/DSCP values mapped) will suffer – packet drops, poor performance, etc.
• Of course, you can have different non-default policies on different sets of interfaces, but all interfaces in the system must use some policy that defines all activated queues!
Maps the new policy to ALL interfaces in the
system (do this on ALL ports in EVERY VDC!!)
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourShape the SP Queue
154BRKDCN-3346
(Optional) Clone a default egress “type
queuing” policy-map
Create a copy of a default egress queuing policy
Shape SP queue in new (cloned) “type
queuing” policy
Limit SP queue bandwidth consumption
Apply new “type queuing” policy to target
interface(s)
Apply new queuing policy to interfaces
Important: applying new queuing policy takes effect immediately and is disruptive to any ports to which the policy is applied
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Modifying Queuing BehaviourShape the SP Queue
155BRKDCN-3346
Example: Shape the SP queue to 2Gbps on a 10G interface, using a queuing policy cloned from the default “8e4q4q” egress queuing policy
n77# ! Clone the 8E egress queuing policy
n77# qos copy policy-map type queuing default-8e-4q8q-out-policy prefix new-
n77# conf
Enter configuration commands, one per line. End with CNTL/Z.
n77(config)# ! Modify new queuing policy
n77(config)# policy-map type queuing new-8e-4q8q-out
n77(config-pmap-que)# ! Modify egress queue q1
n77(config-pmap-que)# class type queuing 8e-4q8q-out-q1
n77(config-pmap-c-que)# ! Make this queue strict priority
n77(config-pmap-c-que)# priority level 1
n77(config-pmap-c-que)# ! Shape the queue to 20% (2G on 10G port)
n77(config-pmap-c-que)# shape percent 20
n77(config-pmap-c-que)# int e 2/1-48
n77(config-if-range)# ! Apply the new policy to target interfaces
n77(config-if-range)# service-policy type queuing output new-8e-4q8q-out
n77(config-if-range)#
n77#
Clone the default egress
queuing policy
Modify the cloned policy
Make q1 Strict Priority and
shape to 20% (2G)
Apply new policy to target
interfaces
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Changing The Default Trust (M-Series I/O Module)
156BRKDCN-3346
• You can make an interface untrusted (CoS and DSCP)
• CoS for bridged traffic
• DSCP for routed traffic
• You need two Policies
• A "type queuing" policy
to set the CoS to 0
• A "type qos" policy
to set the DSCP to 0
Set DSCP will set the CoS
value for Bridged traffic as well.
policy-map type queuing Reset-CoS
class type queuing 8q2t-in-q-default
set cos 0
bandwidth percent 100
queue-limit percent 100
!
policy-map type qos Reset-DSCP
class class-default
set dscp 0
!
! Tie to an interface:
interface Ethernet1/1
service-policy type queuing input Reset-CoS
service-policy type qos input Reset-DSCP
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Changing The Default Trust (F-Series I/O Module)
157BRKDCN-3346
qos copy policy-map type queuing default-4q-8e-in-policy prefix UNTRUSTED-
!
policy-map type queuing untrusted-4q-8e-in
class type queuing 2q4t-8e-in-q1
queue-limit percent 1
class type queuing 2q4t-8e-in-q-default
queue-limit percent 99
set cos 0
!
policy-map type qos UNTRUSTED
class class-default
set dscp 0
!
! Tie to an interface:
interface Ethernet1/1
service-policy type queuing input untrusted-4q-8e-in
service-policy type qos input UNTRUSTED
Complete your online session evaluation
• Please complete your session survey after each session. Your feedback is very important.
• Complete a minimum of 4 session surveys and the Overall Conference survey (starting on Thursday) to receive your Cisco Live water bottle.
• All surveys can be taken in the Cisco Live Mobile App or by logging in to the Session Catalog on ciscolive.cisco.com/us.
Cisco Live sessions will be available for viewing on demand after the event at ciscolive.cisco.com.
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS BRKDCN-3346 158
© 2019 Cisco and/or its affiliates. All rights reserved. Cisco Public#CLUS
Continue your education
159BRKDCN-3346
Related sessions
Walk-in labsDemos in the Cisco campus
Meet the engineer 1:1 meetings