Implementing MPLS in The Service Provider Core: Multiprotocol Label Switching
Implementing MPLS in The Service Provider Core: Multiprotocol Label Switching
Provider Core
Multiprotocol Label Switching
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-1
Objectives
• Describe MPLS configuration difference in Cisco IOS XR vs Cisco
IOS/IOS XE
• Describe mandatory and optional MPLS configuration tasks
• Explain a basic MPLS configuration
• Describe the MTU requirements on a label switching router interface
• Explain the configuration used to increase the MPLS MTU size on a
label switching router interface
• Explain IP TTL Propagation
• Explain the configuration used to disable IP TTL Propagation
• Explain LDP Session Protection Configuration
• Explain LDP Graceful Restart and NSR Configuration
• Explain LDP IGP Synchronization Configuration
• Explain how to enable LDP Autoconfiguration
• Explain Label Advertisement Control Configuration
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-2
Objectives (Cont.)
• Describe the show commands used to monitor MPLS operations
• Describe the MPLS and LDP debug commands
• Describe the Classic Ping and Traceroute operations
• Describe the MPLS Ping and Traceroute operations
• Describe how to troubleshoot common MPLS issues
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-3
MPLS Configuration
• Cisco IOS XR Software:
- MPLS forwarding is enabled when you enable LDP on an interface under
MPLS LDP configuration mode.
- Cisco Express Forwarding is mandatory for Cisco IOS XR Software, and it
does not need to be enabled explicitly.
• Cisco IOS and IOS XE Software:
- MPLS forwarding is enabled when you enable MPLS on an interface under
interface configuration mode.
- Cisco Express Forwarding is enabled by default on most Cisco IOS and Cisco
IOS XE platforms, including the Cisco ASR 1000 Series Aggregation Services
Routers.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-4
MPLS Configuration Tasks
Mandatory:
• Enable LDP on an interface under MPLS LDP configuration mode (Cisco
IOS XR Software).
• Enable MPLS on an interface under interface configuration mode (Cisco
IOS and Cisco IOS XE Software).
Optional:
• Configure the MPLS Router ID.
• Configure MTU size for labeled packets.
• Configure IP TTL propagation.
• Configure conditional label advertising.
• Configure access lists to prevent customers from running LDP with PE
routers.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-5
Basic MPLS Configuration
IP
MPLS/IP
CE1 PE1 P1 P2 PE2 CE2
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/1
Gi0/0/0/1 Gi0/0/0/0 Gi0/0/0/0 Gi0/0
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-7
Label Switching MTU Configuration
IP
MPLS/IP
CE1 PE1 P1 P2 PE2 CE2
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/1
Gi0/0/0/1 Gi0/0/0/0 Gi0/0/0/0 Gi0/0
IOS XR IOS XE
interface GigabitEthernet0/0/0/0 interface GigabitEthernet0/0
mpls mtu 1512 mpls ip
! mpls mtu 1512
interface GigabitEthernet0/0/0/1
mpls mtu 1512 MPLS MTU is increased to 1512 on all
LAN interfaces to support 1500-byte IP
Increases MPLS MTU value packets and MPLS stacks up to 3
levels deep.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-8
IP TTL Propagation
• By default, IP TTL is copied into the MPLS label at label imposition,
and the MPLS label TTL is copied (back) into the IP TTL at label
removal.
• IP TTL and label TTL propagation can be disabled.
- TTL value of 255 is inserted into the label header.
• The TTL propagation must be disabled on ingress and egress edge
LSRs.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-9
IP TTL Propagation
IP
MPLS/IP
CE1 PE1 P1 P2 PE2 CE2
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/1
Gi0/0/0/1 Gi0/0/0/0 Gi0/0/0/0 Gi0/0
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-10
Disabling IP TTL Propagation
IP
MPLS/IP
CE1 PE1 P1 P2 PE2 CE2
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/1
Gi0/0/0/1 Gi0/0/0/0 Gi0/0/0/0 Gi0/0
Targeted
R1 R3
Traffic Hello
Primary Link
X
Link Hello
Session
IOS XR
Enables LDP
mpls ldp session protection
session protection
feature
• The LDP session protection feature keeps the LDP peer session up by means of
targeted discovery following the loss of link discovery with a peer.
• LDP initiates backup targeted hellos automatically for neighbors for which primary
link adjacencies already exist.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-12
LDP Graceful Restart and NSR Configuration
R1 R2
• Use the LDP graceful restart capability to achieve nonstop forwarding (NSF)
during an LDP control plane communication failure or restart.
• To configure graceful restart between two peers, enable LDP graceful restart on
both label switching routers.
• Graceful restart is a way to recover from signaling and control plane failures
without impacting forwarding.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-13
Configuring LDP IGP Synchronization
R1 R2
• Lack of synchronization between LDP and IGP can cause MPLS traffic loss.
• LDP IGP synchronization synchronizes LDP and IGP so that IGP advertises
links with regular metrics only when MPLS LDP is converged on that link:
- At least one LDP session is operating on the link; for this link, LDP has sent its
applicable label bindings and has received at least one label binding from the peer.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-14
Configuring LDP Autoconfiguration
R1 R2
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-15
Label Advertisement Control Configuration
Advertise only the label for Advertise only the label for
PE1 loopback IP address. PE2 loopback IP address.
IP
MPLS/IP
CE1 PE1 P1 P2 PE2 CE2
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/1
Gi0/0/0/1 Gi0/0/0/0 Gi0/0/0/0 Gi0/0
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-16
Label Advertisement Control Verification
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-17
Label Acceptance Control Configuration
Accept only the label for PE1 loopback
IP address from neighbor PE1.
IP
MPLS/IP
CE1 PE1 P1 P2 PE2 CE2
Gi0/0/0/0 Gi0/0/0/1 Gi0/0/0/1 Gi0/1
Gi0/0/0/1 Gi0/0/0/0 Gi0/0/0/0 Gi0/0
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-19
Display MPLS LDP Parameters
RP/0/RSP0/CPU0:PE1# show mpls ldp parameters
LDP Parameters:
Role: Active
Protocol Version: 1
Router ID: 10.7.1.1
Null Label: Implicit
Session:
Hold time: 180 sec
Keepalive interval: 60 sec
Backoff: Initial:15 sec, Maximum:120 sec
Global MD5 password: Disabled
Discovery:
Link Hellos: Holdtime:15 sec, Interval:5 sec
Targeted Hellos: Holdtime:90 sec, Interval:10 sec
Graceful Restart:
Disabled
NSR: Disabled, Not Sync-ed
Timeouts:
Local binding: 300 sec
Forwarding state in LSD: 15 sec
Max:
1050 interfaces (800 attached, 250 TE tunnel), 1000 peers
OOR state
Memory: Normal
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-20
Display MPLS Configured Interfaces
RP/0/RSP0/CPU0:PE1# show mpls interfaces
Tue Oct 18 12:35:17.016 UTC
Interface LDP Tunnel Enabled
-------------------------- -------- -------- --------
GigabitEthernet0/0/0/0 Yes No Yes
GigabitEthernet0/0/0/2 Yes No Yes
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-21
Display Status of LDP Discovery Process
RP/0/RSP0/CPU0:PE7# show mpls ldp discovery
Tue Oct 18 12:36:43.084 UTC
GigabitEthernet0/0/0/2 : xmit/recv
LDP Id: 10.0.1.1:0, Transport address: 10.0.1.1
Hold time: 10 sec (local:15 sec, peer:10 sec)
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-22
LDP Monitoring Commands
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-23
Display the Status of the LDP Session
RP/0/RSP0/CPU0:PE1# show mpls ldp neighbor
Tue Oct 18 12:37:15.213 UTC
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-24
Display the Detailed Status of the LDP Session
RP/0/RSP0/CPU0:PE1# show mpls ldp neighbor detail
Tue Oct 18 12:39:44.893 UTC
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-25
Display the Contents of the LIB Table
RP/0/RSP0/CPU0:P1# show mpls ldp bindings
Tue Oct 18 06:32:04.302 UTC
10.0.0.0/8, rev 67
Local binding: label: 16019
Remote bindings: (1 peers)
Peer Label
----------------- --------
10.0.2.1:0 16019
10.7.10.1/32, rev 85
Local binding: label: 16021
Remote bindings: (3 peers)
Peer Label
----------------- --------
10.0.2.1:0 16022
10.3.1.1:0 16025
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-26
Monitor Label Switching
show cef
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-27
Display the Contents of the LFIB Table
RP/0/RSP0/CPU0:PE1# show mpls forwarding
Wed Oct 19 11:00:43.683 UTC
Local Outgoing Prefix Outgoing Next Hop Bytes
Label Label or ID Interface Switched
------ ----------- ------------------ ------------ --------------- ------------
16000 Pop 10.0.1.1/32 Gi0/0/0/2 192.168.71.1 0
16001 16000 10.0.2.1/32 Gi0/0/0/2 192.168.71.1 31354
16002 16010 10.5.1.1/32 Gi0/0/0/2 192.168.71.1 0
16003 16011 10.6.1.1/32 Gi0/0/0/2 192.168.71.1 0
16021 16009 192.168.42.0/24 Gi0/0/0/2 192.168.71.1 0
16023 16018 10.4.1.1/32 Gi0/0/0/2 192.168.71.1 0
16024 16004 192.168.108.0/24 Gi0/0/0/2 192.168.71.1 0
16025 Unlabelled 10.7.10.1/32 Gi0/0/0/0 192.168.107.71 945410
16026 16023 10.8.1.1/32 Gi0/0/0/2 192.168.71.1 0
16027 16024 10.8.10.1/32 Gi0/0/0/2 192.168.71.1 0
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-28
Display the Contents of the FIB Table
RP/0/RSP0/CPU0:PE1# show cef
Wed Oct 19 11:34:31.879 UTC
• Use command show cef 192.168.42.0 to show details for specific prefix
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-29
Debugging MPLS and LDP
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-30
Classic Ping and Traceroute
P P
CE P P P CE
VPN A PE1 PE2 VPN A
P MPLS P
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-31
Classic Ping and Traceroute (Cont.)
Broken LSP
P P
52 IP 35 IP IP IP
CE P P P CE
VPN A PE1 PE2 VPN A
P MPLS P
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-33
MPLS Ping
• UDP request generated for selected LSP
• Uses two UDP (port 3503) messages
- MPLS echo request
- MPLS echo reply
• Labeled packet with IP (UDP) payload
- Source address: Routable address sender
- Destination address: Random from 127/8
- Destination port: 3503
- TTL: 255
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-34
MPLS Ping Example 1
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-35
MPLS Ping Example 2
RP/0/RSP0/CPU0:PE1# ping mpls ipv4 172.16.1.14 255.255.255.255 ttl 1 dsmap repeat 1
Sending 1, 100-byte MPLS Echos to 172.16.1.14/32,
timeout is 2 seconds, send interval is 0 msec:
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-37
Symptoms of Common MPLS Issues
• The LDP session does not start.
• Labels are not allocated.
• Labels are not distributed.
• Packets are not labeled, although the labels have been distributed.
• MPLS intermittently breaks after an interface failure.
• Large packets are not propagated across the network.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-38
LDP Session Startup Issues
• Symptom:
- LDP neighbors are not discovered.
- The show mpls ldp discovery command does not display the expected LDP
neighbors.
• Diagnosis:
- MPLS is not enabled on the adjacent router.
• Verification:
- Verify with the show mpls interface command on the adjacent router.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-39
LDP Session Startup Issues (Cont.)
• Symptom:
- LDP neighbors are discovered; the LDP session is not established.
- The show mpls ldp neighbor command does not display a neighbor in
operational state.
• Diagnosis:
- The connectivity between loopback interfaces is broken; the LDP session
is usually established between loopback interfaces of adjacent LSRs.
• Verification:
- Verify connectivity with the extended ping command.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-40
Label Distribution Issues
• Symptom:
- Labels are allocated, but not distributed.
- Using the show mpls ldp bindings command on the adjacent LSR does not
display labels from this LSR.
• Diagnosis:
- There are problems with conditional label distribution.
• Verification:
- Debug label distribution with the debug mpls ldp advertisements command.
- Examine the neighbor LDP router IP address with the show mpls ldp
discovery command.
- Verify that the neighbor LDP router IP address is matched by the access list
specified in the mpls ldp label advertise command.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-41
Intermittent MPLS Failures After Interface Failure
• Symptom:
- The overall MPLS connectivity in a router intermittently breaks after an
interface failure.
• Diagnosis:
- The IP address of a physical interface is used for the LDP identifier. Configure
a loopback interface on the router.
• Verification:
- Verify the local LDP identifier with the show mpls ldp neighbors command.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-42
Packet Propagation Issues
• Symptom:
- Large packets are not propagated across the network.
- Use of the extended ping command with varying packet sizes fails for packet
sizes almost to 1500 packets.
- In some cases, MPLS might work, but MPLS VPN will fail.
• Diagnosis:
- There are label MTU issues or switches that do not support jumbo frames in
the forwarding path.
• Verification:
- Issue the traceroute command through the forwarding path; identify all LAN
segments in the path.
- Verify the label MTU setting on routers attached to LAN segments.
- Check for low-end switches in the transit path.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-43
Summary
• On Cisco IOS XR platforms, MPLS is enabled by enabling LDP on
each interface. On Cisco IOS and IOS XE platforms, MPLS is
enabled on each interface.
• It is recommended to manually set the router ID.
• To enable MPLS on the Cisco IOS XR router, first enter MPLS LDP
configuration mode and then list the interfaces.
• Label switching increases the maximum MTU requirements on an
interface, because of the additional label header.
• To configure the maximum packet size or MTU size on an MPLS
interface, use the mpls mtu command in interface configuration
mode.
• By default, IP TTL is copied into the MPLS label at label imposition,
and the MPLS label TTL is copied into the IP TTL at label removal.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-44
Summary (Cont.)
• If TTL propagation is disabled, the TTL value is not copied into the
label header. Instead, the label TTL field is set to 255.
• When LDP session protection is configured, LDP initiates backup
targeted hellos automatically for neighbors for which primary link
adjacencies already exist.
• Graceful restart is a way to recover from signaling and control plane
failures without impacting forwarding.
• LDP IGP synchronization synchronizes LDP and IGP so that IGP
advertises links with regular metrics only when MPLS LDP is
converged on that link.
• To enable LDP on many interfaces, IGP autoconfiguration allows
you to automatically configure LDP on all interfaces that are
associated with a specified OSPF or IS-IS interface.
• LDP outbound label filtering performs outbound filtering for local
label advertisement, for one or more prefixes, to one or more peers.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-45
Summary (Cont.)
• You can use various show commands to monitor MPLS.
• When debugging MPLS and LDP in production environments, use
the debug commands with extreme cautions.
• Standard ping and traceroute tools can be used in MPLS
environments to test reachability.
• Special MPLS ping and MPLS traceroute were designed for
monitoring and troubleshooting MPLS LSPs.
• If an LDP session does not come up, verify if MPLS is enabled on
the neighboring router.
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-46
© 2012 Cisco and/or its affiliates. All rights reserved. SPCORE v1.01—1-47