Vous êtes sur la page 1sur 0

2009 Cisco Systems, Inc. All rights reserved.

1
MPLS
2009 Cisco Systems, Inc. All rights reserved. 2
Legal Notice
THE SPECIFICATIONS AND INFORMATION REGARDING THE PRODUCTS IN THIS DOCUMENT ARE SUBJ ECT TO CHANGE WITHOUT
NOTICE. ALL STATEMENTS, INFORMATION, AND RECOMMENDATIONS IN THIS MANUAL ARE BELIEVED TO BE ACCURATE BUT ARE
PRESENTED WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED. USERS MUST TAKE FULL RESPONSIBILITY FOR THEIR
APPLICATION OF ANY PRODUCTS.
THE SOFTWARE LICENSE AND LIMITED WARRANTY FOR THE ACCOMPANYING PRODUCT ARE SET FORTH IN THE INFORMATION
PACKET THAT SHIPPED WITH THE PRODUCT AND ARE INCORPORATED HEREIN BY THIS REFERENCE. IF YOU ARE UNABLE TO
LOCATE THE SOFTWARE LICENSE OR LIMITED WARRANTY, CONTACT YOUR CISCO REPRESENTATIVE FOR A COPY.
The Cisco implementation of TCP header compression is an adaptation of a program developed by the University of California, Berkeley (UCB)
as part of UCBs public domain version of the UNIX operating system. All rights reserved. Copyright 1981, Regents of the University of
California.
NOTWITHSTANDING ANY OTHER WARRANTY HEREIN, ALL DOCUMENT FILES AND SOFTWARE OF THESE SUPPLIERS ARE
PROVIDED AS IS WITH ALL FAULTS. CISCO AND THE ABOVE-NAMED SUPPLIERS DISCLAIM ALL WARRANTIES, EXPRESSED OR
IMPLIED, INCLUDING, WITHOUT LIMITATION, THOSE OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT OR ARISING FROM A COURSE OF DEALING, USAGE, OR TRADE PRACTICE.
IN NO EVENT SHALL CISCO OR ITS SUPPLIERS BE LIABLE FOR ANY INDIRECT, SPECIAL,
CONSEQUENTIAL, OR INCIDENTAL DAMAGES, INCLUDING, WITHOUT LIMITATION, LOST PROFITS OR LOSS OR DAMAGE TO DATA
ARISING OUT OF THE USE OR INABILITY TO USE THIS MANUAL, EVEN IF CISCO OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE
POSSIBILITY OF SUCH DAMAGES.
CCDE, CCENT, CCSI, Cisco Eos, Cisco HealthPresence, the Cisco logo, Cisco Lumin, Cisco Nexus, Cisco Nurse Connect, Cisco Stackpower,
Cisco StadiumVision, Cisco TelePresence, Cisco WebEx, DCE, and Welcome to the Human Network are trademarks; Changing the Way We
Work, Live, Play, and Learn and Cisco Store are service marks; and Access Registrar, Aironet, AsyncOS, Bringing the Meeting To You,
Catalyst, CCDA, CCDP, CCIE, CCIP, CCNA, CCNP, CCSP, CCVP, Cisco, the Cisco Certified Internetwork Expert logo, Cisco IOS, Cisco
Press, Cisco Systems, Cisco Systems Capital, the Cisco Systems logo, Cisco Unity, Collaboration Without Limitation, EtherFast, EtherSwitch,
Event Center, Fast Step, Follow Me Browsing, FormShare, GigaDrive, HomeLink, Internet Quotient, IOS, iPhone, iQuick Study, IronPort, the
IronPort logo, LightStream, Linksys, MediaTone, MeetingPlace, MeetingPlace Chime Sound, MGX, Networkers, Networking Academy, Network
Registrar, PCNow, PIX, PowerPanels, ProConnect, ScriptShare, SenderBase, SMARTnet, Spectrum Expert, StackWise, The Fastest Way to
Increase Your Internet Quotient, TransPath, WebEx, and the WebEx logo are registered trademarks of Cisco Systems, Inc. and/or its affiliates in
the United States and certain other countries.
All other trademarks mentioned in this document or website are the property of their respective owners. The use of the word partner does not
imply a partnership relationship between Cisco and any other company.
Copyright 2009 Cisco Systems, Inc. All rights reserved.
2009 Cisco Systems, Inc. All rights reserved. 3
Agenda
MPLS Concepts
MPLS Label Distribution Protocol
MPLS Forwarding
MPLS Configuration
2009 Cisco Systems, Inc. All rights reserved. 4
MPLS Concepts
2009 Cisco Systems, Inc. All rights reserved. 5
What Is MPLS?
Multi Protocol Label Switching
MPLS is an efficient encapsulation mechanism
Uses Labels appended to packets
(IP packets, AAL5 frames) for transport of data
MPLS packets can run on other Layer 2 technologies such as ATM,
FR, PPP, POS, Ethernet
Other Layer 2 technologies can be run over an
MPLS network
MPLS is a technology for delivery of IP Services
2009 Cisco Systems, Inc. All rights reserved. 6
MPLS Standard
MPLS is the standardized version of Ciscos proprietary tag
switching
MPLS and tag switching are identical except for the mechanisms
used for label distribution
Tag switching uses the proprietary Tag Distribution Protocol (TDP)
MPLS uses the IETF standard Label Distribution Protocol (LDP)
TDP and LDP are not compatible but can coexist
2009 Cisco Systems, Inc. All rights reserved. 7
Control Plane
Every MPLS node must run an IGP
Class flows into FEC (Forwarding Equivalent Class)
Group of packets with the same forwarding treatment
Each FEC corresponds to an IP destination prefix (default)
Associate Labels to FEC (label bindings)
Labels mapping is distributed via LDP (label distribution protocol)
Data Plane
forwarding of packets based on labels
uses a label forwarding database LFIB
CEF is the switching mecanism
MPLS Switching structure
2009 Cisco Systems, Inc. All rights reserved. 8
Unit Components
Edge Label Switching Routers
label previously unlabeled packets
- at the beginning of a Label Switched Path
strip labels from labeled packets
- at the end of a Label Switched Path
Label Switching Routers
forward labeled packets based on the information carried by labels - not IP
addresses
2009 Cisco Systems, Inc. All rights reserved. 9
Label Switching Devices
Label Switching Routers
Edge Label Switching
Routers
2009 Cisco Systems, Inc. All rights reserved. 10
Forwarding Components
Label Forwarding Information Base (LFIB)
- each entry consists of incoming label, outgoing label, outgoing
interface, outgoing MAC address
- LFIB requires CEF to be enabled globally within the router (ip cef
global command)
Forwarding algorithm:
- extract label from a packet
- find an entry in the LFIB with the incoming label equal to the label in
the packet
- replace the label in the packet with the outgoing label (from the
found entry)
- send the packet on the outgoing interface (from the found entry)
Carrying label information:
- as part of the MAC header
- via a shim between the MAC and the Network Layer header
2009 Cisco Systems, Inc. All rights reserved. 11
MPLS: Forwarding
2009 Cisco Systems, Inc. All rights reserved. 12
MPLS: Forwarding
1. Existing routing protocols (e.g. OSPF, IGRP) establish
routes.
2009 Cisco Systems, Inc. All rights reserved. 13
MPLS: Forwarding
2a. Label Distribution Protocol (e.g.,
LDP) establishes label to routes
mappings
1. Existing routing protocols (e.g. OSPF, IGRP) establish
routes.
2009 Cisco Systems, Inc. All rights reserved. 14
MPLS: Forwarding
2a. Label Distribution Protocol (e.g.,
LDP) establishes label to routes
mappings
2b. Label Distribution
Protocol (e.g., LDP)
creates LFIB entries on
LSRs
1. Existing routing protocols (e.g. OSPF, IGRP) establish
routes.
2009 Cisco Systems, Inc. All rights reserved. 15
MPLS: Forwarding
2a. Label Distribution Protocol (e.g.,
LDP) establishes label to routes
mappings
3. Ingress edge LSR receives
packet, performs Layer 3 value-
added services, and label
packets
2b. Label Distribution
Protocol (e.g., LDP)
creates LFIB entries on
LSRs
1. Existing routing protocols (e.g. OSPF, IGRP) establish
routes.
2009 Cisco Systems, Inc. All rights reserved. 16
MPLS: Forwarding
2a. Label Distribution Protocol (e.g.,
LDP) establishes label to routes
mappings
4. LSRs forward
labelled packets
using label swapping
3. Ingress edge LSR receives
packet, performs Layer 3 value-
added services, and label
packets
2b. Label
Distribution Protocol
(e.g., LDP) creates LFIB
entries on LSRs
1. Existing routing protocols (e.g. OSPF, IGRP) establish
routes.
2009 Cisco Systems, Inc. All rights reserved. 17
MPLS: Forwarding
5. Edge LSR at
egress removes
label and delivers
packet
2a. Label Distribution Protocol (e.g.,
LDP) establishes label to routes
mappings
4. LSRs forward
labelled packets
using label swapping
3. Ingress edge LSR receives
packet, performs Layer 3 value-
added services, and label
packets
2b. Label
Distribution Protocol
(e.g., LDP) creates LFIB
entries on LSRs
1. Existing routing protocols (e.g. OSPF, IGRP) establish
routes.
2009 Cisco Systems, Inc. All rights reserved. 18
RIB/FIB/LIB/LFIB
RIB is the Routing Information Base that is analogous to the ip
routing table
FIB aka CEF is Forwarding information base that is derived from
the ip routing table
LIB is Label Information Base that contains all the label bindings
learned via LDP
LFIB is Label Forwarding Information Base that is derived from FIB
entries and corresponding LIB entries
Lets go through the pictorial view
2009 Cisco Systems, Inc. All rights reserved. 19
Control-plane to Data-plane
Data plane in a node
IP Routing Protocol
IP Routing Table
Router
IGP
Routing information
exchange with
other routers
IP FIB
Incoming IP
packets
Outgoing IP
packets
2009 Cisco Systems, Inc. All rights reserved. 20
Control-plane to Data-plane
MPLS / LSR
Data plane in a node
IP Routing Protocol
IP Routing Table
LSR
Label
Switch
Router
Incoming labelled
packets
Outgoing labelled
packets
MPLS LFIB
MPLS LIB
IGP
Routing information
exchange with
other routers
(Link-state
recommended)
Label Distribution
Protocol
Label binding
exchange with other
routers
2009 Cisco Systems, Inc. All rights reserved. 21
Control-plane to Data-plane
MPLS / E-LSR
Data plane in a node
IP Routing Protocol
IP Routing Table
MPLS LIB
MPLS LFIB
E-LSR
Edge
Label
Switch
Router
IGP
Routing information
exchange with
other routers
(Link-state
recommended)
Label Distribution
Protocol
Label binding
exchange with other
routers
Incoming labelled
packets
Outgoing IP
packets
Outgoing labelled
packets
Incoming IP
packets
IP FIB
2009 Cisco Systems, Inc. All rights reserved. 22
Summary of Packet-mode MPLS Label
Allocation and Distribution
Label allocation and distribution in packet mode MPLS environment follows
these steps:
IP routing protocols build the IP routing table.
Each LSR assigns a label to every destination in the IP routing table
independently.
Labels are assigned once per LSR (per-platform).
LSRs announce their assigned labels to all its neighbor LSRs.
Every LSR builds its LIB, LFIB and FIB data structures based on received
labels.
Every LSR stores all advertised labels in the LIB.
Labels received from next-hop LSRs are used to populate label information in
FIB and the outgoing label in LFIB.
2009 Cisco Systems, Inc. All rights reserved. 23
10.89
172.69
1
0
1
0
You can reach 172.69
through me
You can reach 10.89 and
172.69 through me
Routing Updates
(OSPF, EIGRP, )
You can reach 10.89
through me
Address
Prefix
10.89
172.69
...
Out
Iface
0
1
...
Address
Prefix
10.89
172.69
...
Out
Iface
1
1
...
Address
Prefix
10.89
...
Out
Iface
0
...
MPLS switching :
Routing Information
2009 Cisco Systems, Inc. All rights reserved. 24
1
0
1
0
Use label 7 for 172.69
Use label 4 for 10.89 and
Use label 5 for 172.69
Label Distribution
Protocol
Use label 9 for 10.89
10.89
172.69
In
Lbl
Address
Prefix
10.89
172.69
...
Out
Iface
0
1
...
Out
Lbl
In
Lbl
Address
Prefix
10.89
172.69
...
Out
Iface
1
1
...
Out
Lbl
In
Lbl
Address
Prefix
10.89
...
Out
Iface
0
...
Out
Lbl
-
-
4
5
4
5
9
7
9 -
MPLS switching:
Assigning Labels
2009 Cisco Systems, Inc. All rights reserved. 25
10.89
172.69
1
0
1
Data 10.89.25.4 4 10.89.25.4 Data
10.89.25.4 Data
10.89.25.4 Data 9
0
Label Switch Forwards
Based on Label
In
Lbl
Address
Prefix
10.89
172.69
...
Out
Iface
0
1
...
Out
Lbl
In
Lbl
Address
Prefix
172.69
...
Out
Iface
1
1
...
Out
Lbl
In
Lbl
Address
Prefix
10.89
...
Out
Iface
0
...
-
-
4
5 5 7
-
4 9 10.89
Out
Lbl
9
MPLS switching :
Forwarding Packets
2009 Cisco Systems, Inc. All rights reserved. 26
MPLS Forwarding Plane: Ethertype
Ethertype 0x0800 refers to IP
Ethertype 0x8847 refers to MPLS
Based on the Ethertype, the packet is handed over to
the appropriate processing engine in the router
2009 Cisco Systems, Inc. All rights reserved. 27
What Is a Label
A LABEL is 4 bytes identifier, which is carried by the packet and
used to identify a prefix
Label = Actual Label, = 20 bits
EXP/QoS = Experimental bits, = 3 bits
S = End of Stack, = 1 bit
TTL = Time to Live, = 8 bits
0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7 0 1 2 3 4 5 6 7
Label EXP S TTL
2009 Cisco Systems, Inc. All rights reserved. 28
Packet-over-SONET/SDH
Ethernet: similar
Frame Relay PVCs: similar
Label over ATM PVCs
PPP Header Label Layer 3 Header Data
Ethernet Hdr Label Layer 3 Header Data
Frame Rly Hdr Label Layer 3 Header Data
ATM Header Label Layer 3 Header Data
ATM Header Data
(subsequent cells)
Label Encapsulation
2009 Cisco Systems, Inc. All rights reserved. 29
172.68.10/24
Rtr-A
Next-Hop
In
Lab
5
...
Address
Prefix
172.68.10
...
Out
I/F
1
...
Out
Lab
7
...
In
I/F
0
...
IP packet
D=172.68.10.12
Label = 5
Label = 21
IP packet
D=172.68.10.12
Label = 7
Label = 21
Rtr-A forwards the labelled packet based on the label at the top of
the label stack
The Label Stack
MPLS is recursive
2009 Cisco Systems, Inc. All rights reserved. 30
London Brussels Paris
192.26.15.1/32
In Label FEC Out Label
- 192.26.15.1/32 28
In Label FEC Out Label
28 192.26.15.1/32 POP
In Label FEC Out Label
- 192.26.15.1/32 -
Use label 28 for destination
192.26.15.1/32
Use label implicit-null for
destination 192.26.15.1/32
Penultimate Hop Popping
May be disabled using explicit-null option
(Usefull to maintain end-to-end label for QoS classification)
2009 Cisco Systems, Inc. All rights reserved. 31
Label Distribution
Protocol
2009 Cisco Systems, Inc. All rights reserved. 32
Cisco IOS implements two label binding protocols for destination-based unicast
routing
TDP (Tag Distribution Protocol)
proprietary protocol - TCP port 711
LDP (Label Distribution Protocol)
IETF standards based protocol - TCP port 646
Both protocols are functionally equivalent and can be used concurrently
Labels are exchanged between adjacent LSRs
Applications may require non-adjacent neighbors
- LDP/TDP Directed Peers
- AToM
Label Distribution Protocols
2009 Cisco Systems, Inc. All rights reserved. 33
MPLS Control Plane: LDP vs. TDP
LDP is quite similar to TDP
LDP is standardized by IETF
LDP has more features such as abort,
MD5 authentication, notification,
backoff logic, etc.
TDP is the default on Cisco routers
LDP is the default with this global config
mpls label protocol ldp
2009 Cisco Systems, Inc. All rights reserved. 34
MPLS Control Plane: LDP/TDP
LDP/TDP operates in three steps
Neighbor Discovery
Session establishment
Label Distribution/exchange
Once labels are exchanged, LIB is built
LIB and FIB together helps to build LFIB
2009 Cisco Systems, Inc. All rights reserved. 35
MPLS Control Plane: TDP
TDP Neighbors are discovered via TDP Hellos (like
most of the routing protocols)
TDP Hellos are sent to 255.255.255.255
TDP hellos are sent to UDP port = 711
TDP hellos are sent only after mpls ip is configured on
an interface
PE1 PE2
Tx Hello (PE1:0)
Rx Hello (PE2:0)
2009 Cisco Systems, Inc. All rights reserved. 36
MPLS Control Plane: LDP
LDP Neighbors are discovered via LDP Hellos (like
most of the routing protocols)
LDP Hellos are sent to 224.0.0.2
LDP hellos are sent to UDP port = 646
LDP hellos are sent only after both mpls ip and mpls
label protocol ldp are configured on an interface **
LDP_ID should be hardcoded via mpls ldp router-ID
<interface>
** If LDP is the global default, then interface-level LDP is not needed.
PE1 PE2
Tx Hello (PE1:0)
Rx Hello (PE2:0)
2009 Cisco Systems, Inc. All rights reserved. 37
MPLS Control Plane: LDP (1)
Use the same Loopback0 as the router-ID for LDP,
IGP, BGP, etc.
Assign an IP address to the Loopback0 from the
separate IP address subnet (or space)
Avoid the IGP summarization of prefixes that
correspond to the router-ids
2009 Cisco Systems, Inc. All rights reserved. 38
MPLS Control Plane: LDP (1)
sh mpls ldp discovery [detail]
Must show xmit/recv on LDP enabled interface
PE1#sh mpls ldp discovery
Local LDP Identifier:
10.13.1.61:0
Discovery Sources:
Interfaces:
Ethernet0/0 (ldp): xmit/recv
LDP Id: 10.13.1.101:0
Ethernet1/0 (ldp): xmit/recv
LDP Id: 10.13.1.101:0
PE1#
debug mpls ldp transport connections
Should give information regarding whether the HELLOS are
advertised/received
Local LDP_ID
Discovered Neighbors
LDP_ID
Xmited and Recvd Hellos
on that interface
Eth0/0 is
configured
with LDP
2009 Cisco Systems, Inc. All rights reserved. 39
MPLS Control Plane: LDP (2)
LDP session is a TCP session (port = 646)
Multiple links between two routers still mean single LDP session
PE1#sh mpls ldp neighbor
Peer LDP Ident: 10.13.1.101:0; Local LDP Ident 10.13.1.61:0
TCP connection: 10.13.1.101.11031 - 10.13.1.61.646
State: Oper; Msgs sent/rcvd: 58/60; Downstream
Up time: 00:39:27
LDP discovery sources:
Ethernet0/0, Src IP addr: 10.13.1.5
Ethernet1/0, Src IP addr: 10.13.1.9
Addresses bound to peer LDP Ident:
10.13.1.9 10.13.1.5 10.13.2.5 10.13.1.101
PE1#
LDP_ID
Unsolicited Label
Distribution*
Interfaces on Which
Peer Is Discovered
Peers
Connected Int
PE1#sh tcp brief| i 646
43ABB020 10.13.1.101.11031 10.13.1.61.646 ESTAB
PE1#
* Unsolicited downstream label Distribution mode is the default in Frame-mode MPLS. In cell-mode MPLS,
distribution on demand (DoD) is the default distribution mode. They are not configurable.
2009 Cisco Systems, Inc. All rights reserved. 40
MPLS Control Plane: LDP (3)
LIB entry can be verified with the following
PE1#sh mpls ip bindings 10.13.1.62 32
10.13.1.62/32
in label: 20
out label: 2001 lsr: 10.13.1.101:0
PE1#
PE1 P1
10.13.1.61/32 10.13.1.101/32
E0/0
E0/1
10.13.1.62/32
Ok. I hear you 10.13.1.101:0.
I have the binding from you in
my LIB now
This is 10.13.1.101:0.
Use label 2001 to reach 10.13.1.62/32
PE1#sh mpls forwarding 10.13.1.62
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
20 2001 10.13.1.62/32 0 Et0/0 10.13.1.5
2001 10.13.1.62/32 0 Et1/0 10.13.1.9
PE1#
But whether I use
your binding or not
will be dictated by
RIB entry
Oh ok. Per RIB,
10.13.1.101 is the
next-hop for
10.13.1.62/32.
I have to use
label 2001 in
LFIB.
Local binding
Remote binding
2009 Cisco Systems, Inc. All rights reserved. 41
MPLS Control Plane: LDP (4)
sh mpls ldp neighbor [neighbor]
Shows LDP neighbor and relevant info
sh mpls ldp neighbor [interface]
LDP neighbors discovered over this interface
Debug mpls ldp session io|state
Useful when the session doesnt come up
Debug mpls ldp messages sent|receive
Shows all the LDP messages sent or received
Relevant LDP Session Commands/Debugs:
2009 Cisco Systems, Inc. All rights reserved. 42
MPLS Control Plane: LDP (5)
sh mpls ip binding detail
Lists all prefixes with labels and LDP neighbors
sh mpls ip binding <prefix> <mask> det
Lists ACLs (if any), prefix bindings, and LDP neighbors Notice
Advertised to: field
sh mpls ip binding advertisement-acls
Lists LDP filter, if there is any, on the first line. Prefixes followed
by Advert acl(s): are advertised via LDP, others are not
2009 Cisco Systems, Inc. All rights reserved. 43
MPLS Forwarding
2009 Cisco Systems, Inc. All rights reserved. 44
RSP-PE-SOUTH-5#sh mpls forwarding 10.13.1.11
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
59 46 10.13.1.11/32 0 Se10/0/0 point2point
RSP-PE-SOUTH-5#
MPLS Forwarding Plane: Outgoing
Labels
Outgoing label also conveys what treatment the packet is going to
get; it could also be
Pop Pops the topmost label
Untagged Untag the incoming MPLS packet
Aggregate Untag and then do a FIB lookup
0 Nullify the top label (first 20bits)
Label values 0-15 are reserved
2009 Cisco Systems, Inc. All rights reserved. 45
MPLS Forwarding Plane: Outgoing
Labels
Untagged
Convert the incoming MPLS packet to an IP packet and forward it
Pop
Pop the top label from the label stack present in an incoming MPLS packet
and forward it as an MPLS packet.; if there was only one label in the stack,
then forward it as an IP packet; SAME as imp-null label
Aggregate
Convert the incoming MPLS packet to an IP packet and then do a FIB
lookup for it to find out the outgoing interface
0 (zero)
Same as exp-null label; simplify fills 0 in the first 20 bits of label; helps to
preserve the EXP value of the top label
2009 Cisco Systems, Inc. All rights reserved. 46
MPLS Forwarding Plane: Outgoing Labels
PE1#sh mpls forwarding-table
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
16 2002 10.13.1.22/32 0 Et0/0 10.13.1.5
2002 10.13.1.22/32 0 Et1/0 10.13.1.9
17 2001 10.13.1.62/32 0 Et0/0 10.13.1.5
2001 10.13.1.62/32 0 Et1/0 10.13.1.9
18 Pop tag 10.13.1.101/32 0 Et1/0 10.13.1.9
Pop tag 10.13.1.101/32 0 Et0/0 10.13.1.5
19 Pop tag 10.13.2.4/30 0 Et1/0 10.13.1.9
Pop tag 10.13.2.4/30 0 Et0/0 10.13.1.5
20 Untagged 5.5.5.5/32[V] 0 Se2/0 point2point
21 Pop tag 10.13.21.4/30 0 Et1/0 10.13.1.9
Pop tag 10.13.21.4/30 0 Et0/0 10.13.1.5
22 Pop tag 10.13.22.4/30 0 Et1/0 10.13.1.9
Pop tag 10.13.22.4/30 0 Et0/0 10.13.1.5
23 Aggregate 0.0.0.0/0[V] 0
24 Aggregate 200.1.61.4/30[V] 0
26 Untagged 30.30.30.1/32[V] 0 Se2/0 point2point
PE1#
V Means It Is a VPN Prefix
Connected
VPN Prefix
No Outgoing Interface for the
Aggregate Entries; an
Additional FIB Lookup Is Done
2009 Cisco Systems, Inc. All rights reserved. 47
MPLS Forwarding Plane
Three cases in the MPLS forwarding
1. Label ImpositionIP to MPLS conversion
2. Label swappingMPLS to MPLS
3. Label dispositionMPLS to IP conversion
So, depending upon the case, we need to check
1. FIBFor IP packets that get forwarded as MPLS
2. LFIBFor MPLS packets that get fwded as MPLS
3. LFIBFor MPLS packets that get fwded as IP
2009 Cisco Systems, Inc. All rights reserved. 48
MPLS Forwarding Plane
PE1 does a FIB lookup for
the incoming IP packet
It imposes the label
For troubleshooting, look at
the FIB (not LFIB)
PE1
PE2
P1 1.1.1.0/30
Case 1: IP Packets Get Forwarded as MPLS
PE1#sh ip cef 1.1.1.0
1.1.1.0/30, version 25, epoch 0, cached adjacency 10.13.1.5
0 packets, 0 bytes
tag information set
local tag: 20
fast tag rewrite with Et0/0, 10.13.1.5, tags imposed: {2001}
via 10.13.1.5, Ethernet0/0, 0 dependencies
next hop 10.13.1.5, Ethernet0/0
valid cached adjacency
tag rewrite with Et0/0, 10.13.1.5, tags imposed: {2001}
PE1#
IP Packet
IP Packet 2001
2009 Cisco Systems, Inc. All rights reserved. 49
MPLS Forwarding Plane
P1 does the LFIB lookup for
incoming MPLS packets
P1 could swap (or dispose)
the label
For troubleshooting, look at
the LFIB (not FIB)
PE1
Case 2: MPLS Packets Get Forwarded as MPLS
P1#sh mpls for 10.13.1.62
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
2002 Pop tag 10.13.1.62/32 0 Se2/0 point2point
P1#
P1#sh mpls for 1.1.1.0
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
2001 20 1.1.1.1.0/30 0 Se2/0 point2point
P1#
IP Packet 2001
PE2
P1 1.1.1.0/30
IP Packet 20
2009 Cisco Systems, Inc. All rights reserved. 50
MPLS Forwarding Plane
Typically happen at the
edge
Could also happen at the
PHP router
For troubleshooting, look at
the LFIB (not FIB)
PE1
Case 3: MPLS Packets Get Forwarded as IP
PE2#sh mpls for 1.1.1.0
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
20 Untagged 1.1.1.1.0/30 0 Se2/0 point2point
PE2#
PE2
P1 1.1.1.0/30
IP Packet 20 IP Packet
2009 Cisco Systems, Inc. All rights reserved. 51
MPLS Fwd Plane: Fragmentation
After the Layer 2 header is added to the IP packet, the
resulting packet size shouldnt exceed the max packet
size (MTU size) applicable; otherwise, packet will be
fragmented
MTU size needs to be tuned to avoid fragmentation in
MPLS network
MTU could be increased only for MPLS packets =>
MPLS MTU
2009 Cisco Systems, Inc. All rights reserved. 52
Fragmentation
MTU Setting in MPLS
If the label imposition makes the packet bigger than the MPLS
MTU size of an outgoing interface, then
If the DF bit set, then discard the packet and send ICMP reply back
(with code=4)
If the DF bit is not set, then fragment the IP packet (say, into 2
packets), and then impose the same label(s) on both the packets, and
then transmit MPLS packets
Fragmentation should be done at the edge itself
2009 Cisco Systems, Inc. All rights reserved. 53
MPLS Fwd Plane: Show Commands
sh mpls forwarding
Shows all LFIB entries (vpn, non-vpn, TE, etc.)
sh mpls forwarding <prefix>
LFIB lookup based on a prefix
sh mpls forwarding label <label>
LFIB lookup based on an incoming label
sh mpls forwarding <prefix> detail
Shows detailed info such as L2 encap, etc.
2009 Cisco Systems, Inc. All rights reserved. 54
RSP-PE-WEST-4#sh mpls for 10.13.1.11 detail
Local Outgoing Prefix Bytes tag Outgoing Next Hop
tag tag or VC or Tunnel Id switched interface
45 51 10.13.1.11/32 0 Fa1/1/1 10.13.7.33
MAC/Encaps=14/18, MRU=1500, Tag Stack{51}
0003FD1C828100044E7548298847 00033000
No output feature configured
Per-packet load-sharing
RSP-PE-WEST-4#
MPLS Fwd Plane: Show Command
Detail Is Optional
MAC header =0003FD1C828100044E754829
MPLS Ethtype= 0x8847
Label = 0x00033000=3x16+3=51
14/18 means that the L2 header is of 14 bytes, but
L2+label header is 18 bytes (one label is 4 bytes)
MRU Max Receivable Unit. The
received packet will be transmitted
unfragmented on Fa1/1/1, if its size
is not more than 1500B.
Only One Outgoing
Label in the Label
Stack
2009 Cisco Systems, Inc. All rights reserved. 55
MPLS Fwd Plane: Debugs
Debug mpls lfib cef
Useful for seeing FIB and LFIB interaction when a label is
missing for a prefix
debug mpls lfib struct
Shows changes in the LFIB structures when label is
allocated/deallocated
Be Careful on the Production Routers
2009 Cisco Systems, Inc. All rights reserved. 56
MPLS Configuration
2009 Cisco Systems, Inc. All rights reserved. 57
Configuration Example
Ip cef need to be enabled
If cef is not enabled by default:
r out er # conf t
Ent er conf i gur at i on commands,
one per l i ne. End wi t h CNTL/ Z.
r out er ( conf i g) #i p cef
2009 Cisco Systems, Inc. All rights reserved. 58
Configuration Example
mpl s i p
mpl s l abel pr ot ocol l dp
mpl s l dp nei ghbor 10. 0. 0. 3 passwor d <passwor d>
no mpl s l dp adver t i se- t ags
mpl s l dp adver t i se- t ags f or 1
mpl s l dp r out er - i d Loopback0
i nt er f ace Gi gabi t Et her net 2/ 1
i p addr ess 10. 0. 1. 38 255. 255. 255. 252
mpl s mt u 1512
mpl s i p
access- l i st 1 per mi t 10. 0. 0. 0 0. 0. 0. 255
2009 Cisco Systems, Inc. All rights reserved. 59

Vous aimerez peut-être aussi