Beruflich Dokumente
Kultur Dokumente
An Introduction to MPLS Networks and Applications By Shawn Zandi CCIE (Routing & Switching / Security / Service Provider)
MPLS History
Cisco joined the MPLS story in 1998 (IOS 11.1) with tag switching... IETF released RFC 2547 "BGP/MPLS VPNs" in 1999
http://blog.shafagh.com
by Shawn Zandi
Terminology
Old Terminology Tag Switching Tag TDP TFIB TSR TSC TSP New Terminology MPLS Label LDP (Label Distribution Protocol) LFIB (Label Forwarding Information Base) LSR (Label Switch Router) LSC (Label Switch Controller) LSP (Label Switched Path)
MPLS Applications
MPLS VPN
Traffic Engineering
http://blog.shafagh.com
by Shawn Zandi
Advantages of MPLS
MPLS VPN
VRF routing tables and ease of growth. Carrier for any technology - ATM, FR, PPP, Ethernet, IPv4 and IPv6. AAL5 - RFC1483, LANE, Multiprotocol over ATM - MPOA providers need IP routing but BGP is only required on edges.
Unified infrastructure
Better IP over ATM than pervious solutions BGP-free core Optimal Traffic Flow
Connections logically are fully mesh and no extra circuit mapping is required.
Different path from least cost path, Source-based routing & Fast ReRouting (FRR)
Traffic Engineering
MPLS Label
BOS
Label
EXP
TTL
Label: 20 bits EXP: 3 bits BOS: 1 bit (bottom of stack) TTL: 8 bits
http://blog.shafagh.com by Shawn Zandi
Label Stack
Label Label
EXP EXP
0 0
TTL TTL
Label
EXP
TTL
Some MPLS applications like MPLS VPNs require more than one label in the label stack to forward the packets. MPLS VPNs and AToM put two labels in the label stack.
PPP
Label
Label
IPv4
MPLS is not a Layer 2 Protocol, not even Layer 3 MPLS is viewed as a Layer 2.5 protocol.
http://blog.shafagh.com by Shawn Zandi
Protocol Identifier
Frame Relay
NLPID
80
Inserts a label (push) and sends packet to MPLS network. Removes the label (pop) and sends packet on a data link.
Egress LSR
Intermediate LSR
Ingress LSR
Intermediate LSR
Egress LSR
Disposing LSR
11
PE
CE
MPLS VPN
12
http://blog.shafagh.com
by Shawn Zandi
Ingress LSR
LSR
LSR
LSR
Ingress LSR
MPLS Network
13
Nested LSP
LSP inside LSP The second Label spans the entire MPLS network.
LSP LSP
Ingress LSR
LSR
LSR
LSR
Ingress LSR
MPLS Network
14
http://blog.shafagh.com
by Shawn Zandi
FEC is group or flow of packets classified for a forwarding decision and have similar EXP. Ingress LSR decides which packet belongs to which FEC.
All packets with same FEC get the same label imposed by the ingress LSR
Same FEC = Same Label. Same Label <> Same FEC. (might have different FEC)
15
FEC Classification
Certain multicast group Based on DSCP or Precedence Based on VC (sub-interface) Based on Destination IP Based on BGP Prefixes pointing to the same Next-hop.
In this case all traffic for an Egress LSR (iBGP Peer) can be forwarded through a specific LSP.
16
http://blog.shafagh.com
by Shawn Zandi
Label Distribution
Adjacent LSRs must agree to use specific Label for a specific IP Prefix. Labels are local and have no global meaning. Labels are between adjacent LSRs.
A label distribution protocol is required.
Using IP Routing Protocol (EIGRP, ISIS, OSPF) Using Label Distribution Protocol (TDP, LDP, RSVP)
17
Advantage:
Does not need a new label distribution protocol. Routing and Label distribution are always in sync. EIGRP implementation is straight forward.
Disadvantage:
18
http://blog.shafagh.com
by Shawn Zandi
Label Information Base (LIB) holds remote and local label bindings. One local binding per prefix.
Label Space:
19
LFIB is Label Forwarding Instance Base, a table used to forward incoming and outgoing labels for LSPs. All remote bindings LIB Only one possible outgoing label in LIB
LDP Static MPBGP RSVP
20
1.
2.
LFIB
LIB
LFIB
http://blog.shafagh.com
by Shawn Zandi
MPLS Payload
The MPLS has no Network Level Protocol Identifier. NLPID exists in all Layer 2 protocols (different names) Intermediate LSRs do not need to know what payload is. Egress LSR should know what the payload is, to forward. Egress LSR is the one who created label binding for FEC.
21
LDP Modes
DOD Downstream-on-Demand (pull mode LC-ATM) UD Unsolicited Downstream (push mode Default) LLR Liberal Label Retention (keep all bindings in LIB - Default) CLR Conservative Label Retention (LC-ATM) Independent LSP (immediate local binding for FEC - Default) Ordered LSP (IOS ATM switches)
22
http://blog.shafagh.com
by Shawn Zandi
ip cef x.x.x.x adjacency table mpls forwarding-table mpls forwarding-table x.x.x.x mpls forwarding-table x.x.x.x detail mpls forwarding-table vrf mpls interfaces detail
23
Label Operation
24
http://blog.shafagh.com
by Shawn Zandi
Set by egress LSR for connected and summarized prefixes to penultimate LSR to not send Label. penultimate hop popping PHP
25
TTL (-1) is copied from IP header to MPLS and vice versa. Dont copy if TTL value is greater than packet TTL.
IP to Label Label to Label Label to IP
TTL=253 TTL=253
TTL=252 TTL=253
Igress LSR
LSR
LSR
26
http://blog.shafagh.com
by Shawn Zandi
SWAP
PUSH
POP
TTL=253
TTL=253
TTL=253
TTL=253
TTL=253
TTL=253
LSR
LSR
LSR
27
TTL Expire
ICMP time exceeded (type 11 code 0) is forwarded along the LSP because interim LSR might have no route to the originator of packet.
TTL Expired!
TTL=1
TTL=2 TTL=1
TTL=255
Ingress
LSR LSR
TTL=252
LSR
TTL=253 ICMP Time Exceeded TTL=253
Egress
http://blog.shafagh.com
by Shawn Zandi
MPLS MTU
Maximum size of packet that can be sent to data link without fragmentation. MRU Maximum Receive Unit used in LFIB for neighbors.
29
Fragmentation
Fragmentation <> Performance LSR strips the label and fragments payload. Path MTU Discovery
Modern hosts send IP with DF bit set (Dont Fragment) to receive ICMP type 3 code 4 Fragmentation needed Process continues with lowering the size till no error is received and correct MTU achieves.
LSR sends ICMP type 3 code 4 along with LSP (just like TTL exceeded)
30 http://blog.shafagh.com by Shawn Zandi
Discovery of LSRs (hello message 224.0.0.2/UDP/646) Session Establishment TCP Label Mapping Advertisement Notifications
31
show mpls ldp discovery [detail] show mpls interfaces (config-if)# mpls ldp discovery
32
http://blog.shafagh.com
by Shawn Zandi
More Information
33
34
http://blog.shafagh.com
by Shawn Zandi