vOQ NCS
vOQ NCS
vOQ NCS
BRKSPG-2165
Cisco Webex Teams
Questions?
Use Cisco Webex Teams to chat
with the speaker after the session
How
1 Find this session in the Cisco Events Mobile App
2 Click “Join the Discussion”
3 Install Webex Teams or go directly to the team space
4 Enter messages/questions in the team space
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 3
Agenda
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 4
Unicast forwarding troubleshooting
Network topology and legend
ISIS access ISIS access
AG1 P1 P3 A-PE3
192.168.1.11 192.168.0.1 192.168.0.3 192.168.2.21
SID 5 SID 1 SID 3 SID 8
Te0/0/0/22 BE2
CE1
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 6
How to find the device which is dropping the traffic?
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 7
Using ACLs to match the unlabeled traffic
• ACLs are one of the methods to confirm that unlabeled traffic is reaching the node
• With the hardware keyword in the command syntax we can check if traffic is matching ACL line
• By default on NCS5500 we provide only statistics for the dropped packets, to enable statistics
on the permitted traffic, we need to configure following command (LC reload is required)
hw-module profile stats acl-permit
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 8
Using Netflow to match the traffic
• Another option which will help us to check if the traffic has reached the node is Netflow
• We don’t need external collector, we only need a local cache
• With the Netflow we can capture IPv4/IPv6 and MPLS traffic
• Thanks to the MPLS Netflow, we can capture imposed label stack and ingress/egress interface:
OutputInterface ForwardStatus FirstSwitched LastSwitched ByteCount PacketCount Dir SamplerID IPV4SrcAddr IPV4DstAddr IPV4TOS
BE1 Fwd 03 23:55:41:368 03 23:55:56:223 1065674 2534 Ing 1 192.168.1.64 192.168.2.64 0x60
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 9
Interface drop counters
RP/0/RP0/CPU0:A-PE4#show int HundredGigE0/0/2/2
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 10
Controller drop counters
RP/0/RP0/CPU0:A-PE4#show controllers HundredGigE 0/0/2/2 Egress:
stats Output total bytes = 92730300788456
Output good bytes = 92730300788456
Statistics for interface HundredGigE0/0/2/2 (cached values):
Output total packets = 249802525333
Ingress: Output 802.1Q frames = 0
… Output pause frames = 0
Output pkts 64 bytes = 32766
Input drop overrun = 0 Output pkts 65-127 bytes = 145720161036
Input drop abort = 0 Output pkts 128-255 bytes = 73005
Input drop invalid VLAN = 0 Output pkts 256-511 bytes = 5
Input drop invalid DMAC = 0 Output pkts 512-1023 bytes = 83265928020
Input drop invalid encap = 0 Output pkts 1024-1518 bytes = 0
Input drop other = 0 Output pkts 1519-Max bytes = 20816293892
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 11
Reminder on VOQ-only Architecture
Fabric Card 0
VoQs Fabric Card 1 Egress
Interface
Ingress Net FMQs Fab Fabric Card 2 Fab Queues Net Egress
Interface Fabric Card 3
Interface
Ingress Fabric Card 4 Egress
Scheduler Scheduler
Fabric Card 5
Network Interface
Network Interface
Fabric Interface
Ingress Ingress Egress Egress
(segmentation)
(reassembly)
Ingress Egress
Receive Transmit Receive Transmit
Traffic Traffic
Packet Packet Packet Packet
Manager Manager
Processor Processor Processor Processor
1 lookup → VoQ Sch poll → VoQ Sch grant → spray cells → reassemble packet → transmit
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 12
Virtual Output Queues (VOQ) - reminder
Ingress VOQ
Ingress VOQ Scheduler
Scheduler Fabric Card 2
LC0
0/7/0/0.2 Queue0
0/7/0/0.2 Queue1
0/7/0/0.2 VOQ0 0/7/0/x VOQ0
0/7/0/0.2 VOQ1 0/7/0/x VOQ1 Fabric Card 3 0/7/0/0.2 Queue2
0/7/0/0.2 Queue3
0/7/0/0.2 VOQ2 0/7/0/x VOQ2
0/7/0/0.2 Queue4
0/7/0/0.2 VOQ3 0/7/0/x VOQ3
0/7/0/0.2 Queue5
0/7/0/0.2 VOQ4 0/7/0/x VOQ4
Ingress 0/7/0/0.2 VOQ5 0/7/0/x VOQ5
0/7/0/0.2 Queue6
Egress
Net Fabric Card 4 0/7/0/0.2 Queue7 Net
Interface
0/7/0/0.2 VOQ6 0/7/0/x VOQ6
0/7/0/0.2 VOQ7 0/7/0/x VOQ7 Egress Port Queues Interface
VOQ Hu0/7/0/0.2
Ingress VOQ Fabric Card 5 Egress VOQ
Scheduler Scheduler
LC1 LC7
More details:
BRKSPG-2900 Deepdive in the Merchant Silicon High-end SP Routers
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 13
Virtual Output Queues (VOQ) mapping
-------------------------------------------------------------------
LC 0/0 point of view
Node ID: 0/0/CPU0
Intf Intf NPU NPU PP Sys VOQ Flow VOQ Port
name handle # core Port Port base base port speed
(hex) type (Gbps)
----------------------------------------------------------------------
Hu0/3/0/5 1800100 0 0 1 1537 1072 10280 remote 100 VOQ number
Hu0/0/0/26 200 4 1 17 273 1424 4136 local 100
Hu0/3/0/6 1800108 1 1 21 1621 1080 1064 remote 100
Local for LC 0/0
Hu0/0/0/27 208 4 0 9 265 1432 5416 local 100
Hu0/3/0/7 1800110 1 1 13 1613 1088 2344 remote 100
Hu0/0/0/28 210 4 0 5 261 1440 7208 local 100
Hu0/3/0/8 1800118 1 1 17 1617 1096 4136 remote 100 Remote for LC 0/0
Hu0/0/0/29 218 4 0 1 257 1448 8488 local 100
Hu0/3/0/9 1800120 1 0 9 1609 1104 5416 remote 100
Hu0/0/0/30 220 5 1 21 341 1456 2344 local 100
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 14
VOQ Stats
RP/0/RP0/CPU0:A-PE4#show controllers npu stats voq ingress interface TenGigE 0/0/0/22
Ingress instance 0 location 0/0/CPU0
NPU#
Interface Name = Te0/0/0/22 Egress Interface
Interface Handle = 1e8
Asic Instance = 0
VOQ Base = 1176
Port Speed(kbps) = 10000000
Local Port = local
ReceivedPkts ReceivedBytes DroppedPkts DroppedBytes
-------------------------------------------------------------------
TC_0 = 413562254 153169145866 0 0
TC_1 = 0 0 0 0
TC_2 = 0 0 0 0
Stats per TC_3 = 0 0 0 0
Traffic Class TC_4 = 0 0 0 0
TC_5 = 0 0 0 0
TC_6 = 0 0 0 0
TC_7 = 8386 1400986 0 0
RP/0/RP0/CPU0:A-PE4#
RP/0/RP0/CPU0:ios#show controllers npu stats voq base <voq> instance <npu> location <location>
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 15
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 16
Port Mapping
• Mapping Physical ports to NPU, NPU core, PP port and source system port
• PP port: Port Termination ID
• Flow base ID: connector ID linking VOQ to egress scheduling elements
-------------------------------------------------------------------
Node ID: 0/0/CPU0
Intf Intf NPU NPU PP Sys VOQ Flow VOQ Port
name handle # core Port Port base base port speed
(hex) type
----------------------------------------------------------------------
Te0/0/0/22 1e8 0 1 48 48 1176 5456 local 10G
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 17
NCS5500 Last packet dump
NPU number LC
Core 0:
Last packet information: is_valid=1 tm_port=17
pp_port=17 src_syst_port=49152 port_header_type=eth packet_size=118
Packet start, offset in bytes:
00: 00bc6047 b0dc008a 96cc50da 884707d1 41fb4500 00640f11 0000ff01 2834c0a8
20: 0101c0a8 02020800 243138e9 0f11cafe cafecafe cafecafe cafecafe cafecafe
40: cafecafe cafecafe cafecafe cafecafe cafecafe cafecafe cafecafe cafecafe Decoded packet
60: cafecafe cafecafe cafecafe cafecafe cafecafe cafe0000 00000000 00000000
Core 1:
Last packet information: is_valid=1 tm_port=48
pp_port=48 src_syst_port=48 port_header_type=eth packet_size=118
Packet start, offset in bytes:
00: 00bc6047 b0160000 00598a95 810001f4 08004500 00645e70 00004001 97d5c0a8
20: 0202c0a8 01010000 2c3038e9 0f12cafe cafecafe cafecafe cafecafe cafecafe
40: cafecafe cafecafe cafecafe cafecafe cafecafe cafecafe cafecafe cafecafe
60: cafecafe cafecafe cafecafe cafecafe cafecafe cafe0000 00000000 00000000
:
RP/0/RP0/CPU0:ios#
pp_port will help to identify ingress interface under show controllers npu voq-usage interface command output.
Make sure that to check on the right NPU # & NPU core.
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 18
NCS5500 Last packet dump - hack
• Generate ICMP traffic with the pattern on the remote node
RP/0/RP0/CPU0:remote#ping 192.168.0.1 repeat 1000000 pattern cafe
• Use describe command to get shell syntax for the npu diag last with the pattern
RP/0/RP0/CPU0:ios#describe show controllers npu diag last instance 1 location 0/0/CPU0 | inc cafe
The command is defined in parsercmds.parser
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 19
Parsing Info for the last packet
RP/0/RP0/CPU0:A-PE4#show controllers npu diag pp ParsingInfo Core 1:
instance all loc 0/0/CPU0 hdr_type IPv4oETH
Core 0: header[0]:
hdr_type IPv4oMPLSx1oETH hdr_type eth hdr_offset: 0 bytes
encap_type eth2 tag_fromat:outer_tpid tpid2 inner_tpid none
header[0]: is_outer_prio: 0
hdr_type eth hdr_offset: 0 bytes vlan_tags:
encap_type eth2 tag_fromat:outer_tpid none inner_tpid none vlan_tag[0]:tpid: 00008100 vid: 500
is_outer_prio: 0 vlan_tag[1]:tpid: 00000000 vid: 0
vlan_tags: vlan_tag_format: 8 ( Unknown)
vlan_tag[0]:tpid: 00000000 vid: 0 next_prtcl ipv4
vlan_tag[1]:tpid: 00000000 vid: 0
vlan_tag_format: 0 (none) header[1]:
next_prtcl mpls hdr_type ipv4 hdr_offset: 18 bytes
next_prtcl icmp is_mc: 0
header[1]: is_fragmented: 0
hdr_type mpls hdr_offset: 14 bytes hdr_err: 0
bos: 1
initial_vid 500
header[2]: :
hdr_type ipv4 hdr_offset: 18 bytes
next_prtcl icmp is_mc: 0
is_fragmented: 0
hdr_err: 0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 20
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 21
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 22
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
• Forwarding lookup
• Depending on the forwarding header different lookup action (using different database: LEM, TCAM, KAPS, ...)
• If external memory is present, ROP (record over packet) is generated and sent to the external device.
• OAM classification
• The result will be a destination and editing information
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 23
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 24
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 25
Pipeline Forwarding ASIC DRAM
IRPP
IHP Block IHB Block ITM ITPP
Network Interface
Header
Fabric Interface
Editor
Tunnel
Port Link VLAN FEC Header
Parser Service Fwd PMF
Term Layer Trans Res TM Editor
Term
Action
Res
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 26
Pipeline Forwarding ASIC
Fabric Interface
MC
Link
Prog. Encap Fwd Term Protocols Res
Layer Parser PMF Parser
Editor Editor Editor Editor Filter &
Editor
Port Map
Internal
Buffer
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 27
Pipeline Forwarding ASIC
Fabric Interface
MC
Link
Prog. Encap Fwd Term Protocols Res
Layer Parser PMF Parser
Editor Editor Editor Editor Filter &
Editor
Port Map
Internal
Buffer
• Egress PMF capable of doing internal TCAM lookup for egress ACL
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 28
Pipeline Forwarding ASIC
Fabric Interface
MC
Link
Prog. Encap Fwd Term Protocols Res
Layer Parser PMF Parser
Editor Editor Editor Editor Filter &
Editor
Port Map
Internal
Buffer
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 29
Pipeline Forwarding ASIC
Fabric Interface
MC
Link
Prog. Encap Fwd Term Protocols Res
Layer Parser PMF Parser
Editor Editor Editor Editor Filter &
Editor
Port Map
Internal
Buffer
• Forwarding Editor
• where we update the forwarding header. Remark TTL, TOS, EXP etc
• In case of MPLS, we can encapsulate/manipulate (swap) one MPLS header
• Encapsulation Editor
• where we build tunnels (GRE, MPLS up to 2 labels) if needed (based on encapsulation database info)
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 30
Encapsulation Info for the last packet
RP/0/RP0/CPU0:A-PE4# show controllers npu diag pp ll_vsi: 1598
EncapsulationInfo instance all location 0/0/CPU0 out_ac: 8192
pp_port: 17
Core 0: tm_port: 17
eep[0]: 49170 OutLIF Profile
encap_info[0]:MPLS Encapsulation: ==============
tunnel 1: Bit 0 : Split Horizon Orientation
tunnel_label: 32010 MPLS encapsulation Bit 1 : Split Horizon Orientation
push_profile: 3 with the labels Bit 2 : Unreserved
tunnel 2: Bit 3 : Mpls encapsulation extended label
tunnel_label: 16007 Bit 4 : DSCP remark preserve
push_profile: 3 Bit 5 : EVPN
nof_tunnels: 2
orientation NA
out_vsi: 0
oam_lif_set: 0
outlif_profile: 0x11 RP/0/RP0/CPU0:A-PE4#show controllers npu voq-usage interface all
instance all location 0/0/CPU0
eep[1]: 24582
encap_info[1]:LL Encapsulation: ------------------------------------------------------------------
dest_mac:00:8a:96:cc:50:da Node ID: 0/0/CPU0
out_vid_valid: 1 ETH encapsulation Intf Intf NPU NPU PP Sys VOQ Flow VOQ Port
out_vid: 1598 with the NH mac address name handle # core Port Port base base port speed
pcp_dei_valid: 0 (hex) type
pcp_dei: 0 --------------------------------------------------------------------
tpid_index: 0 <…>
ll_remark_profile: 0 Hu0/0/2/2 388 0 0 17 17 1456 5584 local 100G
out_ac_valid: 0 <…>
out_ac_lsb: 0
oam_lif_set: 0
outlif_profile: 0x10
is native: 0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 31
Pipeline Forwarding ASIC
Fabric Interface
MC
Link
Prog. Encap Fwd Term Protocols Res
Layer Parser PMF Parser
Editor Editor Editor Editor Filter &
Editor
Port Map
Internal
Buffer
• Programmable Editor
• allows to reconstruct or change any header and offers a bit more flexibility than the other configurable blocks
of the pipe
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 32
For Reference
Ingress:
Network Int. counters Network buffer and Interlaken block
NBI RX:
RX_TOTAL_BYTE_COUNTER = 0 It manages the RX buffers for the interface.
RX_TOTAL_PKT_COUNTER = 0
IRPP counters Ingress Receive Editor
IRE:
CPU_PACKET_COUNTER = 0 Receives the packet segments from the packet interface.
NIF_PACKET_COUNTER = 0
OAMP_PACKET_COUNTER = 47
OLP_PACKET_COUNTER = 0
RCY_PACKET_COUNTER = 0
IRE_FDT_INTRFACE_CNT = 128 Ingress DRAM Assembly
IDR: Reassembles the data segments into full packets to be
MMU_IDR_PACKET_COUNTER = 32 sent to DRAM or to OCB.
IDR_OCB_PACKET_COUNTER = 1
ITM counters Ingress Queue Manager
IQM:
ENQUEUE_PKT_CNT = 47 Handles en-queue and de-queue commands from IRR
DEQUEUE_PKT_CNT = 47
DELETED_PKT_CNT = 0
(Ingress Replicator) and IPS (Ingress Packet Scheduler).
ENQ_DISCARDED_PACKET_COUNTER = 0
ITPP counters Ingress Packet Transmit
IPT:
EGQ_PKT_CNT = 47 Receives packet context from IQM.
ENQ_PKT_CNT = 47
FDT_PKT_CNT = 0
CFG_EVENT_CNT = 47
CFG_BYTE_CNT = 3611
Fabric Int. counters Fabric Data transmit
FDT:
IPT_DESC_CELL_COUNTER = 0 Receives data packets from IPT and TDM packets from IRE.
IRE_DESC_CELL_COUNTER = 0
TRANSMITTED_DATA_CELLS_COUNTER = 0
Egress:
FDR:
Fabric Int. counters Fabric Data Receive
P1_CELL_IN_CNT = 0 Receives data packets from IPT and FDT and data cells
P2_CELL_IN_CNT = 0
P3_CELL_IN_CNT = 0 from fabric. Maps cells to one of the cores of EGQ (egress
CELL_IN_CNT_TOTAL = 0 queue).
FDA:
CELLS_IN_CNT_P1 = 0
CELLS_IN_CNT_P2 = 0
CELLS_IN_CNT_P3 = 0
CELLS_IN_TDM_CNT = 0
CELLS_IN_MESHMC_CNT = 0
CELLS_IN_IPT_CNT = 47
CELLS_OUT_CNT_P1 = 0
CELLS_OUT_CNT_P2 = 0
CELLS_OUT_CNT_P3 = 0
CELLS_OUT_TDM_CNT = 0
CELLS_OUT_MESHMC_CNT = 0
CELLS_OUT_IPT_CNT = 47
EGQ_DROP_CNT = 0
EGQ_MESHMC_DROP_CNT = 0
ERPP / ETM counters Egress Queue
EGQ:
FQP_PACKET_COUNTER = 47 Includes the ERPP and ETM logic (packet reassembly,
PQP_UNICAST_PKT_CNT = 47
PQP_DSCRD_UC_PKT_CNT = 0
egress acl’s, scheduling, etc).
PQP_UC_BYTES_CNT = 3611
PQP_MC_PKT_CNT = 0
PQP_DSCRD_MC_PKT_CNT = 0
PQP_MC_BYTES_CNT = 0
EHP_UNICAST_PKT_CNT = 47
EHP_MC_HIGH_PKT_CNT = 0
EHP_MC_LOW_PKT_CNT = 0
DELETED_PKT_CNT = 0
EHP_MC_HIGH_DSCRD_CNT = 0
EHP_MC_LOW_DSCRD_CNT = 0
ERPP_LAG_PRUNING_DSCRD_CNT = 0
ERPP_PMF_DISCARDS_CNT = 0
ERPP_VLAN_MBR_DSCRD_CNT = 0
ETPP counters Egress process network interface
EPNI:
EPE_BYTES_COUNTER = 4363 Manages all packet editing.
EPE_PKT_COUNTER = 47
EPE_DSCRD_PKT_CNT = 0
Network Int. counters Network buffer and Interlaken block
NBI TX:
TX_TOTAL_BYTE_COUNTER = 0 It manages the TX buffers for the interface.
TX_TOTAL_PKT_COUNTER = 0
* DropCisco
© 2020 Cisco and/or its affiliates. All rights reserved. counters
Public in red.
For Reference
+-------------------------------------------+-------------------------------------------+-------------------------------------------+-------------------------------------------+
| | FDA |
| | CELLS_IN_CNT_P1 = 0 | CELLS_OUT_CNT_P1 = 0 |
| | CELLS_IN_CNT_P2 = 0 | CELLS_OUT_CNT_P2 = 0 |
+-------------------------------------------+-------------------------------------------| CELLS_IN_CNT_P3 = 0 | CELLS_OUT_CNT_P3 = 0 |
| IPT | CELLS_IN_TDM_CNT = 0 | CELLS_OUT_TDM_CNT = 0 |
| CORE 0 ------------+------------ CORE 1 | CELLS_IN_MESHMC_CNT = 0 | CELLS_OUT_MESHMC_CNT = 0 |
| -> CELLS_IN_IPT_CNT = 0 | CELLS_OUT_IPT_CNT = 0 |
| ENQ_PKT_CNT = 0 | ENQ_PKT_CNT = 0 | EGQ_DROP_CNT = 0 | |
| FDT_PKT_CNT = 0 | FDT_PKT_CNT = 0 | EGQ_MESHMC_DROP_CNT = 0 | |
| CRC_ERROR_CNT = 0 | | EGQ_TDM_OVF_DROP_CNT = 0 | |
| CFG_EVENT_CNT = 0 | | |
| CFG_BYTE_CNT = 0 | | |
+-------------------------------------------+-------------------------------------------+-------------------------------------------+-------------------------------------------+
| FDT | FDR |
| IPT_DESC_CELL_COUNTER = 0 | P1_CELL_IN_CNT = 0 |
| IRE_DESC_CELL_COUNTER = 0 | P2_CELL_IN_CNT = 0 |
| | P3_CELL_IN_CNT = 0 |
| TRANSMITTED_DATA_CELLS_COUNTER = 0 | CELL_IN_CNT_TOTAL = 0 |
+-------------------------------------------+-------------------------------------------+-------------------------------------------+-------------------------------------------+
| /|\
| J E R I C H O F A B R I C I N T E R F A C E |
\|/ |
RP/0/RP0/CPU0:ios#
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 37
Special Packet Handling
Traps - Non-zero counters example
• Traps are used to punt the traffic to the LC CPU over LPTS
RP/0/RP0/CPU0:PE4#show controller npu stats traps-all instance 0 loc 0/0/CPU0 | exc "0 0"
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 38
Special Packet Handling
Fragmentation example
Policer id
• Default policer rate can be verified with the following command
RP/0/RP0/CPU0:PE4#attach location 0/0/CPU0
#dpa_show puntpolicer
Def CIR Rate Conf CIR Rate CIR Burst ID
...
22 - 0: 1000 0 100 32022
1: 1000 0 100 32022
-------------------------------------------------------------
Node 0/0/CPU0:
-------------------------------------------------------------
FlowType Policer Type Cur. Rate Burst npu
---------------------- ------- ------- --------- --------- ---------
Fragment 32102 np 1000 100 0
Fragment 32102 np 1000 100 1
Fragment 32102 np 1000 100 2
Fragment 32102 np 1000 100 3
• Default policer rate is 1000 PPS and can be configured via cli:
RP/0/RP0/CPU0:PE4(config)#lpts punt police location 0/x/CPU0 exception ipv4 fragment rate ?
<0-4294967295> Packets Per Second
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 40
SPP (Software Packet Path)
RP/0/RP0/CPU0:PE1#show spp node-counters location
• SPP block directly interface with the Linux 0/0/CPU0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 41
SPP packet capture
tcpdump: verbose output suppressed, use -v or -vv for full protocol decode
listening on eth-vf2, link-type EN10MB (Ethernet), capture size 262144 bytes
14:17:15.734437 4e:41:50:00:00:11 (oui Unknown) > 4e:41:50:00:00:01 (oui
Unknown), ethertype Unknown (0x876f), length 1696:
0x0000: 4e41 5000 0001 4e41 5000 0011 876f 1a50
0x0010: 8000 7e82 1180 5801 0018 8157 170b 0000
Internal headers
0x0020: 0040 0000 003b 0000 0800 0019 dc60 0120
0x0030: 8204 00c8 79c0 00c1 4125 2600 18a8 062a
Src MAC 0x0040: 03e8 9010 fe00 0000 0000 008a 9671 60da
0x0050: 008a 96ea f8dc 8847 03e8 90fe 07d0 61ff
MPLS ethertype 0x0060: 4500 0640 0004 0000 ff01 3165 c0a8 0101
Dst MAC 0x0070: c0a8 0202 0800 4d3f 6871 0004 cafe cafe
0x0080: cafe cafe cafe cafe cafe cafe cafe cafe
0x0090: cafe cafe cafe cafe cafe cafe cafe cafe
0x00a0: cafe cafe cafe cafe cafe cafe cafe cafe
0x00b0: cafe cafe cafe cafe cafe cafe cafe cafe
0x00c0: cafe cafe cafe cafe cafe cafe cafe cafe
0x00d0: cafe cafe cafe cafe cafe cafe cafe cafe
0x00e0: cafe cafe cafe cafe cafe cafe cafe cafe
0x00f0: cafe cafe cafe cafe cafe cafe cafe cafe
0x0100: cafe cafe cafe cafe cafe cafe cafe cafe
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 42
Packets dropped in HW
• Packets dropped in hardware can be captured with the following command:
show captured packets[ingress|egress] location <>
RP/0/RP0/CPU0:PE3#show captured packets ingress hex location 0/0/CPU0
-------------------------------------------------------
packets dropped in hardware in the ingress direction
buffer overflow pkt drops:219717, current: 200, maximum: 200
-------------------------------------------------------
Wrapping entries
-------------------------------------------------------
[1] Dec 28 20:54:42.146, len: 78, hits: 1, buffhdr type: 1
i/p i/f: HundredGigE0/0/0/4 Interface
punt reason: DROP_PACKET
Ingress Headers: Punt reason
port_ifh: 0xf0, sub_ifh: 0x0, bundle_ifh: 0x800001c
logical_port: 0x5, pd_pkt_type: 3
punt_reason: DROP_PACKET (0)
payload_offset: 29, l3_offset: 29
FTMH:
pkt_size: 0x6d, tc: 0, tm_act_type: 0, ssp: 0xc000
PPH:
pph_fwd_code: CPU Trap (7), fwd_hdr_offset: 0
inlif: 0x0, vrf: 0x0, rif: 0x0 Trap code from the show controllers npu stats trap-all
FHEI:
trap_code: FLP_USER_DEFINE1 (SR_Unknown_Label) (150), trap_qual: 0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 43
For Reference
Commands summary
show controllers npu stats counters-all instance <> loc <> show controllers npu stats counters-all instance <> loc <>
show controllers np diag counters graphical cdsp instance <> loc <> show controllers np diag counters graphical cdsp instance <> loc <>
show controllers npu stats traps-all instance <> loc <> show controllers npu stats traps-all instance <> loc <>
show interfaces <> accounting show interfaces <> accounting
show captured packets ingress loc <> show captured packets egress loc <>
show access-lists <> hardware ingress interface <> loc <> show controllers npu diag pp EncapsulationInfo instance <> loc <>
show flow monitor <> cache match <> loc <>
Ingress Interface
Egress Interface
Fabric Interface
(segmentation)
(reassembly)
Ingress NPU Egress NPU
VOQ
show controllers npu voq-usage inteface <egr-interface> instance all loc <>
show controllers npu stats voq ingress <egr-interface> instance all loc <>
show controllers npu stats voq base <voq-base> instance <> loc <>
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 44
For Reference
Netio
LC CPU
show spp node-counters location <>
SPP NF
attach location <> Netflow producer interfaces
tcpdump -xxxi ps-inb.1538 attach location <>
tcpdump -xxxi eth-vf2 (SoC) tcpdump -xxxi ps-inb.1282 etc.
ps-inb tcpdump –xxxi ps-inb0.1282 etc. (SoC)
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 45
Unicast forwarding troubleshooting demo
Network topology and legend
ISIS access ISIS access
AG1 PE1 PE3 A-PE3
192.168.1.11 192.168.0.1 192.168.0.3 192.168.2.21
SID 5 SID 1 SID 3 SID 8
Te0/0/0/22 BE2
CE1
Source:
192.168.1.10 BE2 BE2.10 BE2.11 BE2.11 BE2.10 BE2 BE200
BGP AS 65000
https://youtu.be/0aSTriVj86I
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 47
Reported issue
• End customer reported an issue with L3VPN between CE1 & CE2
• 192.168.1.0/24 subnet is connected on CE1
• 192.168.2.0/24 subnet is connected on CE2
• As per end customer, RTP traffic for the 192.168.1.10 -> 192.168.2.10 IP pair is
dropped, all other flows are working fine.
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 48
For Reference
Troubleshooting flow
1. Divide & conquer – find the device which is dropping the packets
• Check on the destination device (CE) if traffic is arriving from the source, if not, we will need to troubleshoot sender to the
receiver path, if traffic arrives, then we will need to troubleshoot reverse path
2. Generate ICMP traffic with the pattern or match already flowing traffic
• Use Ingress ACL’s (for unlabeled traffic) or Ingress Netflow to check if traffic is arriving on the node
• show controllers npu diag last command might be helpful here as well
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 49
Multicast forwarding troubleshooting
Multicast in NCS 5500
• Multicast support introduced in IOS XR 6.1.2
• Initially limited to Source Specific Protocols and IPv4 only (IGMPv3 and PIM SSM)
• (S,G) information for v4/v6 stored in LPM
Network Interface
Fabric Interface
Ingress
(segmentation)
(reassembly)
Ingress Egress Egress
Receive Ingress Egress
Transmit Receive Transmit
Packet Traffic Traffic
Packet Packet Packet
Processor Manager Manager
Processor Processor Processor
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 51
Multicast in NCS 5500
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 52
NCS 5500 Multicast
Control Plane
• IGMP and PIM joins are punted to RP CPU process (igmp/pim)
• Packets are using EPC internal network to reach the process executed on RP LXC
RP CPU
IGMP/PIM
process
LC1
Hu0/1/0/0 NIF
NPU-0
Hu0/1/0/5
NIF
Hu0/1/0/7 NPU-1
LC2
Hu0/2/0/3
NIF
NPU-0
Hu0/2/0/4
IGMP/PIM Join
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 53
NCS 5500 Multicast
Control Plane
• If it’s a new group, the process (MRIB or L2FIB) will allocation a Multicast ID (MCID)
• If a MCID is already allocated, information will be updated based on join/leave
MRIB
RP CPU
or MCID 16288
L2FIB
LC1
Hu0/1/0/0 NIF
NPU-0
Hu0/1/0/5
NIF
Hu0/1/0/7 NPU-1
LC2
Hu0/2/0/3
NIF
NPU-0
Hu0/2/0/4
IGMP/PIM Join
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 54
NCS 5500 Multicast
Control Plane: Identifying MCID
(192.168.10.1,239.255.1.1) Ver: 0x823c RPF nbr: 192.168.4.13 Flags: RPF, FGID: 16288, Statistics enabled: FALSE
Up: 00:39:02
Incoming Interface List Incoming interface list
Bundle-Ether2.11 Flags: A, Up: 00:39:02
Outgoing Interface List
Bundle-Ether3 (0/0/0) Flags: F NS, Up: 00:39:02 Outgoing interface list
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 55
NCS 5500 Multicast
Control Plane Tables
• The process running on RP CPU will dynamically compute two tables for each MCID
• MCID mapping is a 128 bitmap mask where Ones represent the NPUs who received a join and
who expect a copy of the packet from the fabric
• MCID-DB associates ports where a MRIB MCID 16288
RP CPU
replication is expected or
L2FIB
LC1
Hu0/1/0/0
NIF
NPU-0
Hu0/1/0/5
MCID-Mapping MCID-DB
NIF
NPU-0
Hu0/2/0/4 0001010011..001
LC2 Int-3
NPU0 Int-4
IGMP/PIM Join
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 56
NCS 5500 Multicast
MCID Bitmap – fabric side (admin mode)
• Each LC has 6 bits corresponding to its 6 NPUs. The bit which is set will tell us the LC and the
NPU to which the FGID belongs. The same thing is also displayed using the show mrib fgid info
<fgid number> command in the hex format.
sysadmin-vm:0_RP0# show controller fabric fgid information id 16288 detail
FGID Binary bitmap: First bit is set, which means LC0/0 NPU #0
0000000000000000000000000000000000000000000000000000000000000001-0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000-0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000-0000000000000000000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000000000000000000-0000000000000000000000000000000000000000000000000000000000000000
<…>
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 57
NCS 5500 Multicast
MCID Bitmap
RP/0/RP0/CPU0:PE4#show mrib fgid info 16288
FGID information
----------------
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 58
NCS 5500 Multicast
What is the command to see MCID-DB per NPU mapping?
• From IOS-XR 6.6.3 following command will show MCID-BD per NPU
RP/0/RP0/CPU0:ios#show mfib hardware egress mcid <FGID> npu all location all
• Example output:
RP/0/RP0/CPU0:PE4#show mfib hardware egress mcid 16288 npu all location all
RP/0/RP0/CPU0:PE4#show controllers npu voq-usage interface HundredGigE0/0/0/3 instance all loc 0/0/CPU0
-------------------------------------------------------------------
Node ID: 0/0/CPU0
Intf Intf NPU NPU PP Sys VOQ Flow VOQ Port
name handle # core Port Port base base port speed
(hex) type
----------------------------------------------------------------------
Hu0/0/0/3 f8 0 0 9 9 1064 5416 local 100G
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 59
NCS 5500 Multicast
Ecap ID programming verification
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 60
For Reference
pp_port
in hex
RP/0/RP0/CPU0:PE4#show controllers npu voq-usage interface HundredGigE0/0/0/3 instance all loc 0/0/CPU0
-------------------------------------------------------------------
Node ID: 0/0/CPU0
Intf Intf NPU NPU PP Sys VOQ Flow VOQ Port
name handle # core Port Port base base port speed
(hex) type
----------------------------------------------------------------------
Hu0/0/0/3 f8 0 0 9 9 1064 5416 local 100G
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 61
NCS 5500 Multicast
Data Plane
• Multicast Packet is received on ingress interface
• Lookup provides a FEC-ID itself pointing to MCID
• In LPM for L3 packets (we will use it as an example)
• In iTCAM for L2 packets (future plans to move them to LPM too)
LC1
Forwarding FEC Resolution Fabric NPU-0 Hu0/1/0/0
NIF
Interface egress Hu0/1/0/5
NIF
NIF
Hu0/1/0/7
egress
(VRF, S, G) LC2
Lookup RPF check Hu0/2/0/3
NPU-0
NIF
Ingress Pipeline Fabric Cards egress Hu0/2/0/4
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 62
NCS 5500 Multicast
Data Plane
• Internal Header has been marked with MCID
• Packet is passed to the fabric interface and split in cells
• Based on MCID-Mapping bitmap, the cells are replicated in the
fabric to the NPUs where they are re-assembled by fabric interfaces
MCID-Mapping
NIF
Interface egress Hu0/1/0/5
NIF
NIF
Hu0/1/0/7
egress
(VRF, S, G) LC2
Lookup RPF check Hu0/2/0/3
NPU-0
NIF
Ingress Pipeline Fabric Cards egress Hu0/2/0/4
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 63
NCS 5500 Multicast
Data Plane
MCID-DB
• Re-assembled packets 16288 LC1 NPU0 Int-0
LC1
NIF
egress
MCID-DB information Hu0/1/0/5
LC1
ingress Hu0/1/0/7
NIF
egress
MCID-DB
LC2
NPU-0
NIF
egress
Fabric Cards Hu0/2/0/4
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 64
FMQ Definition
• Mcast packets are not classified in VOQs, but in 4 Fabric Multicast Queues
• FMQ0 to FMQ2 will be Low Priority
• FMQ3 is treated as High Priority in the Egress port queues
Fabric Card 0
Fabric Card 3
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 65
VOQ Credit Mechanism for multicast
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 66
FMQ statistics
• Example output:
RP/0/RP0/CPU0:A-PE4#show controllers npu stats voq base 0 instance all location all
Asic Instance = 0
VOQ Base = 0
ReceivedPkts ReceivedBytes DroppedPkts DroppedBytes
-------------------------------------------------------------------
TC_0 = 7772735752 10850739109792 6427314 2384335486
TC_1 = 0 0 0 0
TC_2 = 0 0 0 0
TC_3 = 0 0 0 0
TC_4 = 0 0 0 0
TC_5 = 0 0 0 0
TC_6 = 0 0 0 0
TC_7 = 0 0 0 0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 67
NCS 5500 Multicast
MFIB global counters
• Following command will show all global mcast drop counters on the LC
RP/0/RP0/CPU0:PE4#show mfib ipv4 counter location 0/0/CPU0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 68
NCS 5500 Multicast
HW multicast route statistics
• To enable them, we need to create an ACL to match (S,G) routes and in the next step,
enable route-stats for l3mcast
RP0/0/RP0/CPU0:PE4# configure
/* Configure an ACL matching the (S,G) routes for which statistics have to be captured:*/
RP0/0/RP0/CPU0:router(config)# ipv4 access-list mcast-counter
RP0/0/RP0/CPU0:router(config-acl)# 10 permit ipv4 host 192.168.10.1 239.255.1.0/24
RP0/0/RP0/CPU0:router(config-acl)#commit
RP0/0/RP0/CPU0:router(config-acl)#exit
/* Enable multicast route statistics for the configured ACL on the default VRF. */
RP0/0/RP0/CPU0:router(config)# hw-module route-stats l3mcast vrf default ipv4 mcast-counter
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 69
NCS 5500 Multicast
HW multicast route statistics
(192.168.10.1,239.255.1.1), Flags:
Up: 00:57:50
Last Used: 00:42:32
SW Forwarding Counts: 56/0/0 Mcast traffic handled
SW Replication Counts: 56/0/0 by software switching
SW Failure Counts: 2/0/0/0/0
HW Forwarding Counts: 2418250/N/A /N/A
HW Replication Counts: 2418250/N/A /N/A
HW Drop Counts: 0/N/A Mcast traffic handled
HW Forwarding Rates: N/A /N/A /N/A /N/A in hardware
Bundle-Ether3 Flags: NS EG, Up:00:57:50
Bundle-Ether2.11 Flags: A, Up:00:57:50
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 70
NCS 5500 Multicast
HW multicast route statistics
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 71
Life of a Multicast Packet in Chassis
• Multicast packet is received on LC1
• And replicated to three ports:
• On 2 different line cards / NPUs
(including the receiving NPU)
•
OCB LineCard2
Fabric ERPP ETM ETPP
Interface
Network
IRPP ITM ITPP
Network Interface
Interface
Network
LineCard1 OCB
or
External Buffer LineCard1
OCB
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 72
Life of a Multicast Packet in Chassis
Ingress Receive Packet Processor
• Lookup performed in LPM/KAPS, gives a FEC-ID
• 2 info: RFP-checked (interface) and FGID added in FMTH
Interface
Network
128B
IRPP ITM ITPP
Network Interface
IP IP IP
Ether Ether Ether
PPH
FTMH
ERPP ETM ETPP
Interface
Network
OCB
or
External Buffer
OCB
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 73
Life of a Multicast Packet in Chassis
Ingress Traffic Manager
• No scheduling
• The credits are generated locally
OCB
Interface
Network
IRPP ITM ITPP
Network Interface
Interface
Network
OCB
or
External Buffer
OCB
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 74
Life of a Multicast Packet in Chassis
Ingress Transmit Packet Process
• Packets are going to fabric even for local routing
• In the SoC case, no fabric
• Packets are still split in cells, passed to ERPP, OCB
then re-assembled
Fabric ERPP ETM ETPP
Interface
Network
IRPP ITM ITPP
Network Interface
IP
eth
PPH
ERPP ETM ETPP
FMTH
Interface
Network
OCB
or
External Buffer
OCB
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 75
Life of a Multicast Packet in Chassis
Egress Receive Packet Processor
• First replication level based on FGID
• Packets are replicated to different line cards or NPUs
• Bundle with members on different line cards: packets are OCB
replicated to all NPU participating then NPUs will prune
all the packets except one
Fabric ERPP ETM ETPP
Interface
Network
IRPP ITM ITPP
Network Interface
IP IP
eth eth
PPH PPH
FMTH FMTH
Interface
Network
IP IP
eth eth
PPH PPH
FMTH FMTH
OCB
or
External Buffer
OCB
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 76
Life of a Multicast Packet in Chassis
Egress Traffic Manager
• Packets are briefly stored in the egress buffer
• Second replication if multiple interfaces
• Based on MCID-DB OCB
IP
eth
IP
eth
PPH PPH
• Maximum 256 replications per MC-ID FMTH FMTH
Interface
Network
IRPP ITM ITPP
Network Interface
Interface
Network
OCB
or
External Buffer
IP
OCB PPH
eth
FMTH
© 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public
Life of a Multicast Packet in Chassis
Egress Transmit Packet Processor
Interface
Network
IRPP ITM ITPP
Network Interface
Interface
Network
IP IP
eth
OCB
or
External Buffer
OCB
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 78
For Reference
Commands summary
show controllers npu stats counters-all instance <> loc <> show controllers npu stats counters-all instance <> loc <>
show controllers np diag counters graphical cdsp instance <> loc <> show controllers np diag counters graphical cdsp instance <> loc <>
show controllers npu stats traps-all instance <> loc <> show controllers npu stats traps-all instance <> loc <>
show interfaces <> accounting show interfaces <> accounting
show captured packets ingress loc <> show captured packets egress loc <>
show access-lists <> hardware ingress interface <> loc <> show controllers npu diag pp EncapsulationInfo instance <> loc <>
show flow monitor <> cache match <> loc <>
Ingress Interface
Egress Interface
Fabric Interface
(segmentation)
(reassembly)
show interfaces <interface> show interfaces <interface>
show interfaces <interface> accounting show interfaces <interface> acc
show controllers <interface> stats Ingress NPU Egress NPU show controllers <interface> stats
show controllers <interface> phy show controllers <interface> phy
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 79
Multicast forwarding troubleshooting demo
Network topology and legend
ISIS access ISIS access
AG1 PE1 PE3 A-PE3
192.168.1.11 192.168.0.1 192.168.0.3 192.168.2.21
SID 5 SID 1 SID 3 SID 8
Te0/0/0/22 BE2
CE1
Mcast Source
192.168.10.1 BE2 BE2.10 BE2.11 BE2.11 BE2.10 BE2 BE200
BGP AS 65000
https://youtu.be/yi3CnldRODk
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 81
Reported issue
• Administrator enabled a new mcast group in the network – 239.255.1.10, however
for some reason it’s not working on CE2 router
• There is also another receiver connected on PE4, and on this one there is no issue
• All other groups (239.255.1.1 -> 239.255.1.9) are working fine on CE2
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 82
Troubleshooting Flow
• Following info should be determined when you start troubleshooting:
• Number of S,G flows expected on your router.
• Expected Incoming and Outgoing interfaces for an (S,G).
• RPF addresses
• Integrity of the routing table and any changes that may have occurred that could have impacted RPF or Source
• Know the interfaces that have QoS configs
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 83
Netflow troubleshooting on NCS 5500
Netflow Principles
• Netflow Architecture Basics
IPV4SrcAddr
IPV4DstAddr
L4SrcPort
L4DestPort
BGPDstOrigAS
Flow Table BGPSrcOrigAS
BGPNextHopV4
Flow1 Flow2 Flow3 Flow x IPV4DstPrfxLen
EPC LC …
IPV4SrcPrfxLen
IPV4Prot
Pkt2
NF Collector
Sampling-interval 1:x
NF packet
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 85
For Reference
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 86
VLANs used in Line Cards and NCS 5502
sysadmin-vm:0_RP0# show controller switch vlan information location 0/LC0/LC-SW sysadmin-vm:0_RP0# show controller switch vlan info
SDR SDR
Identifier SDR Name VLAN VLAN Use Identifier SDR Name VLAN VLAN Use
------------------------------------------------------------------------ ------------------------------------------------------------------------
1 sysadmin-vm 1 (0x001) Platform EMON 1 sysadmin-vm 1 (0x001) Platform EMON
17 (0x011) Platform HOST 2 default-sdr 1282 (0x502) SDR 2 Platform Netflow 1
3073 (0xC01) Calvados IPC 1298 (0x512) SDR 2 Platform Netflow 2
2 default-sdr 1282 (0x502) SDR 2 Platform Netflow 1 1314 (0x522) SDR 2 Platform Netflow 3
1298 (0x512) SDR 2 Platform Netflow 2 1330 (0x532) SDR 2 Platform Netflow 4
1314 (0x522) SDR 2 Platform Netflow 3 1346 (0x542) SDR 2 Platform Netflow 5
1330 (0x532) SDR 2 Platform Netflow 4 1362 (0x552) SDR 2 Platform Netflow 6
1346 (0x542) SDR 2 Platform Netflow 5 1378 (0x562) SDR 2 Platform Netflow 7
1362 (0x552) SDR 2 Platform Netflow 6 1394 (0x572) SDR 2 Platform Netflow 8
1538 (0x602) SDR 2 Platform SPP 1538 (0x602) SDR 2 Platform SPP
1554 (0x612) SDR 2 Platform BFD 1554 (0x612) SDR 2 Platform BFD
1570 (0x622) SDR 2 Platform MAC learning 1794 (0x702) SDR 2 Third Party Applications
1794 (0x702) SDR 2 Third Party Applications
3074 (0xC02) SDR 2 IPC
#ifconfig | grep ps
ps-inb0.1282 Link encap:Ethernet HWaddr 4e:41:50:00:00:01
ps-inb1.1298 Link encap:Ethernet HWaddr 4e:41:50:00:00:01
ps-inb2.1314 Link encap:Ethernet HWaddr 4e:41:50:00:00:01
ps-inb3.1330 Link encap:Ethernet HWaddr 4e:41:50:00:00:01
#ifconfig ps-inb1.1298
ps-inb1.1298 Link encap:Ethernet HWaddr 4e:41:50:00:00:01
inet6 addr: fe80::4c41:50ff:fe00:1/64 Scope:Link
UP BROADCAST RUNNING MULTICAST MTU:9702 Metric:1
RX packets:257081718 errors:0 dropped:0 overruns:0 frame:0
TX packets:8 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:112222067076 (104.5 GiB) TX bytes:648 (648.0 B) …
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 88
Netflow packet capture
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 89
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
(nfma) (nfmgr) Commands
NetFlow MA
(nfma)
Data ring
in shared
memory
NetFlow Producer
(nf_producer)
NetFlow queue
Program ASIC Export packets to
HW
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 90
Processes Involved in Netflow Operation
RP/0/RP0/CPU0:P1#sh processes cpu location 0/rp0/cpu0 | i " nf"
4666 0% 0% 0% nfmgr
4769 0% 0% 0% nfma
4488 0% 0% 0% nfma
14343 0% 0% 0% nfea
14348 0% 0% 0% nfsvr
14358 0% 0% 0% nf_producer
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 91
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
(nfma) (nfmgr) Commands
NetFlow MA
(nfma)
Data ring
in shared Rate-Limiter
memory A mechanism limits the number
of sampled packets sent to the
NetFlow Producer LC Switch and LC CPU
(nf_producer)
NetFlow queue
Program ASIC Export packets to
HW
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 92
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
(nfma) (nfmgr) Commands
NetFlow MA
(nfma)
Data ring
NetFlow Producer in shared
Receives NF packets from ASIC memory
and adds them to the shared
memory data ring for passing data NetFlow Producer
to the NetFlow Server process (nf_producer)
NetFlow queue
Program ASIC Export packets to
HW
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 93
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
(nfma) (nfmgr) Commands
NetFlow MA
(nfma)
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 94
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
(nfma) (nfmgr) NetFlow Manager
Commands (nfmgr)
Accepts configuration and maintains
global objects .i.e. sampler, flow
NetFlow MA
monitor, and flow exporter
(nfma)
Data ring
in shared
memory
NetFlow Producer
(nf_producer)
NetFlow queue
Program ASIC Export packets to
HW
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 95
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
(nfma) (nfmgr) Commands
NetFlow MA (nfma)
Accepts the interface level
NetFlow MA configuration
(nfma)
Data ring
in shared
memory
NetFlow Producer
(nf_producer)
NetFlow queue
Program ASIC Export packets to
HW
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 96
Processes Involved in Netflow Operation
NetFlow MA NetFlow Manager Show/Clear
RP
NetFlow
(nfma)EA (nfea) (nfmgr) Commands
Sends config to NF Server
and ASIC
NetFlow MA
(nfma)
Data ring
in shared
memory
NetFlow Producer
(nf_producer)
NetFlow queue
Program ASIC Export packets to
HW
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 97
Netflow Configuration Example
flow exporter-map export1
version v9
options interface-table
options sampler-table
! exporter-map config
transport udp 9951
source Loopback0
destination 192.168.0.3
!
flow monitor-map monitor1
record mpls ipv4-fields
exporter export1
cache entries 1000000 monitor-map config
cache timeout active 15
cache timeout inactive 2
cache timeout rate-limit 2000
!
sampler-map sampler1
sampler-map config
random 1 out-of 500
!
interface Bundle-Ether3
flow mpls monitor monitor1 sampler sampler1 ingress
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 98
Show Commands
RP/0/RP0/CPU0:P1#show flow monitor-map monitor1
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 99
Show Commands
RP/0/RP0/CPU0:P1#show flow platform producer statistics location 0/0/cpu0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 100
Show Commands
RP/0/RP0/CPU0:P1#show flow monitor monitor1 cache summary location 0/0/CPU0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 101
Show Commands
RP/0/RP0/CPU0:P1#show flow monitor monitor1 cache brie loc 0/0/cpu0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 102
Show Commands
RP/0/RP0/CPU0:P1#show flow exporter export1 location 0/0/cpu0
Status: Normal
Transport: UDP
Destination: 192.168.0.3 (9951) VRF default
Source: 192.168.0.1 (10743)
Flows exported: 189011 (14175825 bytes)
Flows dropped: 0 (0 bytes)
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 103
Netflow Performance
• Three bottlenecks could impact the performance:
• 133 Mbps or 200 Mbps shaper (not configurable)
• Flow table size (up to 1M per monitor-map, configurable)
• Export rate-limiter (default 2000 records / sec, configurable)
Pkt2
NF Collector
Sampling-interval 1:x
NF packet
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 104
For Reference
36x 100G MACSEC w/o eTCAM 6 133 Mbps Min 115x6= 692Kpps
• Example output:
RP/0/RP0/CPU0:PE3#show flow platform pse policer-rate location 0/0/CPU0
Npu id :0
Netflow Platform Pse Policer Rate:
Ingress Policer Rate: 199 Mbps
Npu id :1
Netflow Platform Pse Policer Rate:
Ingress Policer Rate: 199 Mbps
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 106
Netflow Shaper Per NPU
Asic Instance = 0
VOQ Base = 32
ReceivedPkts ReceivedBytes DroppedPkts DroppedBytes
-------------------------------------------------------------------
TC_0 = 878025 228648068 0 0
TC_1 = 0 0 0 0
TC_2 = 0 0 0 0
TC_3 = 244205 27635546 0 0
TC_4 = 666393 4520523722 0 0
TC_5 = 0 0 0 0
TC_6 = 0 0 0 0
TC_7 = 0 0 0 0
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 107
Sampling-interval ?
• There is always discussion about sampling rate
• Multi-parameter equation
• Number of ports per NPU
• Sampling-interval
• Each sample is 128B long, we add internal headers and we transport 144B
• 133Mbps / 144B = 115KPPS per NPU
• It’s possible to predict the BW of sampled traffic between NPU and EPC switch
• Some packets may be smaller than 128B but let’s consider the worst-case scenario
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 108
Sampling-interval ?
• Sampled packet size: 144 Bytes (128 + headers)
• Example 1:
• Number of ports per NPU: 6 x100G ports
• Average bandwidth per link: 100G line rate
• Average packet size: 350B (it’s a worst case, since some packets sampled will be smaller than 128B, they will
use less
• Sampling-rate: 1:4000
• 600,000,000,000 bps / (350 x 8) / 4000 x (144 x 8) = 61.7Mbps < 133Mbps
• Example 2:
• Same parameters with sampling-rate: 1:1000
• 600,000,000,000 bps / (350 x 8) / 1000 x (144 x 8) = 246.8Mbps > 133Mbps
https://xrdocs.io/ncs5500/tutorials/2018-02-19-netflow-sampling-interval-and-the-mythical-internet-packet-size/
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 109
Netflow support in 6.5.x
• In 6.5.x, we support:
• Ingress Netflow on L3 interfaces (Physical or Bundled)
• Ingress Netflow on L3 sub-interfaces
• Ingress Netflow on L2 interfaces (Physical or Bundled)
• Ingress Netflow on L2 sub-interfaces
Note: it needs to be IPv4 / IPv6 / MPLS traffic over L2 interfaces. Pure L2 traffic is not captured.
• IPFIX
• We DON’T support:
• Egress Netflow (in roadmap)
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 110
Increasing NF Records Rate-limiter
• We may would like to extend the number of records generated
• Default of 2000 pps is not satisfactory
• Misconception:
• Cache timeout RL is driving the speed the cache is emptied and not the opposite
• If the RL is not fast enough, active/inactive entries may stay longer than their timer
• It could lead to a cache table full, reflected by the ”Flow dropped” counter
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 111
Increasing NF Records Rate-limiter
• Impact on system
• Process nf_producer and nfser executed in Line Card CPU will be more solicited
• Example below shows nfsvr at 12% CPU load with 50.000 records per second
…
14348 12% 12% 12% nfsvr
…
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 112
Netflow Full Packet Capture
• Starting from XR release 7.0 we can capture full packet
• This feature captures the exact packet size of the ingress Netflow packet
• Usually Netflow only reports MPLS packets with IPv4 and IPv6 payloads. Netflow will not report
the MPLS packets with L2 payload (e.g. L2VPN packets). When a MPLS packet with underlying
L2 payload and a payload destination MAC address starting with the number 6 or 4 is received
without any control word, the packet can get wrongly decoded as MPLS + IP packet, and
inaccurate packet size can get reported to the collector.
• When this feature is enabled, the MPLS packets with all payload types will be reported to the
collector, though only the IP payload be decoded. The packet size will be reported correctly in
all cases. The use of control word is still recommended to avoid misclassifying L2 payload as
IPv4 or IPv6 payload.
• Caveat: There may a netflow performance impact due to this feature.
• In order to use this feature, the command “hw-module profile netflow fpc-enable location
<loc>” has to be applied to the LC and card must be reloaded.
hw-module profile netflow fpc-enable location <location>
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 113
For Reference
RP
(nfma) (nfmgr) Commands show flow trace ea <option> location <loc>
show flow trace ma <option> location <loc>
show flow trace mgr <option> location <loc>
show flow trace all <option> location <loc>
NetFlow MA
(nfma) show flow monitor <name> cache summary location <loc>
show flow monitor <name> cache <option> location <loc>
Data ring
show flow exporter <name> location <loc>
in shared
show processes cpu location <lc loc> memory
show flow platform producer statistics location <>
NetFlow Producer
(nf_producer)
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 114
Netflow troubleshooting demo
Network topology and legend
ISIS access ISIS access
AG1 PE1 PE3 A-PE3
192.168.1.11 192.168.0.1 192.168.0.3 192.168.2.21
SID 5 SID 1 SID 3 SID 8
NF applied
BE3 BE1 BE3 BE1 BE1 BE3 BE1
Te0/0/0/22 BE2
CE1
Source:
192.168.100.1 BE2 BE2.10 BE2.11 BE2.11 BE2.10 BE2 BE200
VLAN 100
BE1 BE3 BE1 BE1 BE3 BE1
BE3
Te0/0/0/22
CE2
AG2 PE2 PE4 A-PE4 Destination:
192.168.1.12 192.168.0.2 192.168.0.4 192.168.2.22
192.168.100.2
SID 6 SID 2 SID 4 SID 9
VLAN 100
BGP AS 65000
https://youtu.be/plS-Q-NsZlE
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 116
Reported issue
• There is L2 traffic with IPv4 payload being sent from source to the receiver and,
hence L2VPN configured between A-PE1 and A-PE4. Netflow is configured in
ingress direction on interface BE3 on P1 to record mpls ipv4-field. There is NF
collector in the network reachable over IPv4 address 192.168.0.3. However, there is
no single entry for the L2 traffic from CE1 towards CE2 we suppose to account for.
• We must troubleshoot this issue and find out the root cause of the issue and provide
solution.
• We must isolate if the issue related to Netflow collector, router P1 configuration, the
network itself or anything else.
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 117
Summary
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 118
Please remember:
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 119
Complete your
online session
survey • 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 t-shirt.
• All surveys can be taken in the Cisco Events
Mobile App or by logging in to the Content
Catalog on ciscolive.com/emea.
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 120
Continue your education
Demos in the
Walk-In Labs
Cisco Showcase
BRKSPG-2165 © 2020 Cisco and/or its affiliates. All rights reserved. Cisco Public 121
Thank you