440 likes | 669 Views
MPLS Architecture Overview. Jay Kumarasamy jayk@cisco.com. Adopted from Stefano Previdi’s presentation. Agenda. MPLS Concepts LSRs and labels Label assignment and distribution Label Switch Paths ATM LSRs Loops and TTL LDP overview
E N D
MPLS Architecture Overview Jay Kumarasamyjayk@cisco.com Adopted from Stefano Previdi’s presentation
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Day in the Life of a Packet
MPLS Concepts • MPLS: Multi Protocol Label Switching • MPLS is a layer 2+ switching • Developed to integrate IP and ATM • MPLS forwarding is done in the same way as in ATM switches • Packet forwarding is done based on Labels
MPLS Concepts • Unlike IP, classification/label can be based on: Destination Unicast address Traffic Engineering VPN QoS • FEC: Forwarding Equivalence Class • A FEC can represent a: Destination address prefix, VPN, Traffic Engineering tunnel, Class of Service.
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Summary
LSRs and Labels • LSR: Label Switch Router • Edge-LSR: LSRs that do label imposition and disposition • ATM-LSR: An ATM switch with Label Switch Controller
IGP domain with a label distribution protocol LSRs and Labels • An IP routing protocol is used within the routing domain (e.g.:OSPF, i-ISIS) • A label distribution protocol is used to distribute address/label mappings between adjacent neighbors • The ingress LSR receives IP packets, performs packet classification, assign a label, and forward the labelled packet into the MPLS network • Core LSRs switch packets/cells based on the label value • The egress LSR removes the label before forwarding the IP packet outside the MPLS network
0 1 2 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 Label | Exp|S| TTL LSRs and Labels Label = 20 bits Exp = Experimental, 3 bits S = Bottom of stack, 1bit TTL = Time to live, 8 bits • Uses new Ethertypes/PPP PIDs/SNAP values/etc • More than one Label is allowed -> Label Stack • MPLS LSRs always forward packets based on the value of the label at the top of the stack
LSRs and Labels Label Label PPP Header(Packet over SONET/SDH) PPP Header Shim Header Layer 3 Header Ethernet Ethernet Hdr Shim Header Layer 3 Header Frame Relay FR Hdr Shim Header Layer 3 Header GFC VPI VCI PTI CLP HEC DATA ATM Cell Header Subsequent cells GFC VPI VCI PTI CLP HEC DATA
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Day in the Life of a Packet
Label Assignment and Distribution • Labels have link-local significance • Each LSR binds his own label mappings • Each LSR assign labels to his FECs • Labels are assigned and exchanged between adjacent neighboring LSR • Applications may require non-adjacent neighbors
Label Assignment and Distribution Upstream and Downstream LSRs • Rtr-C is the downstream neighbor of Rtr-B for destination 171.68.10/24 • Rtr-B is the downstream neighbor of Rtr-A for destination 171.68.10/24 • LSRs know their downstream neighbors through the IP routing protocol • Next-hop address is the downstream neighbor 171.68.40/24 171.68.10/24 Rtr-A Rtr-B Rtr-C
Use label 30 for destination 171.68.10/24 Use label 40 for destination 171.68.10/24 In I/F In I/F In I/F In Lab In Lab In Lab Address Prefix Address Prefix Address Prefix Out I/F Out I/F Out I/F Out Lab Out Lab Out Lab 0 0 0 - 40 30 171.68.10 171.68.10 171.68.10 1 1 1 40 - 30 Next-Hop Next-Hop Next-Hop ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... Label Assignment and Distribution Unsolicited Downstream Distribution • LSRs distribute labels to the upstream neighbors 171.68.40/24 171.68.10/24 Rtr-A Rtr-B Rtr-C IGP derived routes
Use label 30 for destination 171.68.10/24 Use label 40 for destination 171.68.10/24 Request label for destination 171.68.10/24 Request label for destination 171.68.10/24 Label Assignment and Distribution On-Demand Downstream Distribution 171.68.10/24 171.68.40/24 Rtr-A Rtr-B Rtr-C • Upstream LSRs request labels to downstream neighbors • Downstream LSRs distribute labels upon request
Label Assignment and Distribution • Label Retention Modes • Liberal retention mode • LSR retains labels from all neighbors • Improve convergence time, when next-hop is again available after IP convergence • Require more memory and label space • Conservative retention mode • LSR retains labels only from next-hops neighbors • LSR discards all labels for FECs without next-hop • Free memory and label space
Label Assignment and Distribution Label Distribution Modes • Independent LSP control • LSR binds a Label to a FEC independently, whether or not the LSR has received a Label the next-hop for the FEC • The LSR then advertises the Label to its neighbor • Ordered LSP control • LSR only binds and advertise a label for a particular FEC if: • it is the egress LSR for that FEC or • it has already received a label binding from its next-hop
Label Assignment and Distribution Several protocols for label exchange • LDP • Maps unicast IP destinations into labels • RSVP, CR-LDP • Used in traffic engineering • BGP • External labels (VPN) • PIM • For multicast states label mapping
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Day in the Life of a Packet
Label Switch Path (LSP) IGP domain with a label distribution protocol IGP domain with a label distribution protocol • LSPs are derived from IGP routing information • LSPs may diverge from IGP shortest path • LSP tunnels (explicit routing) with TE • LSPs are unidirectional • Return traffic takes another LSP LSP follows IGP shortest path LSP diverges from IGP shortest path
Label Switch Path (LSP) Penultimate Hop Popping • The label at the top of the stack is removed (popped) by the upstream neighbor of the egress LSR • The egress LSR requests the “popping” through the label distribution protocol • Egress LSR advertises implicit-null label • The egress LSR will not have to do a lookup and remove itself the label • One lookup is saved in the egress LSR
Address Prefix and mask Next-Hop Interface In I/F In I/F In Lab In Lab Address Prefix Address Prefix Out I/F Out I/F Out Lab Out Lab Serial1 171.68.10/24 171.68.9.1 0 0 4 - 171.68/16 171.68/16 2 1 4 pop Next-Hop Next-Hop 171.68.44/24 171.68.12.1 Serial2 ... ... ... ... ... ... ... ... ... ... 171.68/16 ... Null Label Switch Path (LSP) Penultimate Hop Popping • Summary route for 171.68/16 • Summary route for 171.68/16 0 0 1 1 171.68.44/24 • Use label 4 for FEC 171.68/16 • Use label “implicit-null” for FEC 171.68/16 171.68.10/24 Egress LSR summarises morespecific routes and advertises a label for the new FEC Summary route is propagate through the IGP and label is assigned by each LSR • Egress LSR needs to do an IP lookup for finding more specific route • Egress LSR need NOT receive a labelled packet
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Summary
ATM LSRs • ATM switches forward cells, not packets • Label Dist is Downstream on-demand, Ordered • IGP label is carried in the VPI/VCI field • Merging LSR: • Ability to use the same label for different FECs if outgoing interface is the same • Save label space on ATM-LSRs • Cell interleave problem • Non Merging LSR: • ATM-LSR requests one label per FEC and per incoming interface (upstream neighbors) • Downstream LSR may request itself new label to its downstream neighbors
In I/F In Lab Address Prefix Out I/F Out Lab 1 5 171.68 0 3 2 8 171.68 0 4 ... ... ... ... ... 5 8 8 3 8 4 4 3 4 5 • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell ATM LSRs Non-Merging Downstream on Demand ATM-LSR requested additional label for same FEC in order to distinguish between incoming interfaces (Downstream on Demand) • IPPacket 171.68 • IPPacket
ATM LSRs VC-Merging Downstream on Demand In I/F In Lab Address Prefix Out I/F Out Lab 1 5 171.68 0 3 2 8 171.68 0 3 ... ... ... ... ... 5 3 3 3 3 3 8 8 8 5 • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell • ATMcell ATM-LSR transmitted cells in sequence in order for the downstream LSR to re-assembling correctly the cells into packets • IPPacket 171.68 • IPPacket
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Summary
Loops and TTL • In IP networks TTL is used to prevent packets to travel indefinitely in the network • MPLS may use same mechanism as IP, but not on all encapsulations • TTL is present in the label header for PPP and LAN headers (shim headers) • ATM cell header does not have TTL
Loops and TTL • LSRs using ATM do not have TTL capability • Some suggested options: • - hop-count object in LDP • - Path Vector object in LDP
Loops and TTL Label = 25 Label = 21 Label = 39 IP packetTTL = 6 IP packetTTL = 6 IP packetTTL = 6 LSR-1 LSR-3 LSR-2 IP packetTTL = 10 LSR-6 LSR-6 --> 25Hops=4 IP packetTTL = 6 IGP domain with a label distribution protocol Egress LSR-5 LSR-4 • TTL is decremented prior to enter the non-TTL capable LSP • If TTL is 0 the packet is discarded at the ingress point • TTL is examined at the LSP exit
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Day in the Life of a Packet
LDP Concepts • Label Distribution Protocol • Labels map to FECs for Unicast Destination Prefix • LDP works between adjacent/non-adjacent peers • LDP sessions are established between peers
LDP Messages • Discovery messages • Used to discover and maintain the presence of new peers • Hello packets (UDP) sent to all-routers multicast address • Once neighbor is discovered, the LDP session is established over TCP
LDP Messages • Session messages • Establish, maintain and terminate LDP sessions • Advertisement messages • Create, modify, delete label mappings • Notification messages • Error signalling
Agenda • MPLS Concepts • LSRs and labels • Label assignment and distribution • Label Switch Paths • ATM LSRs • Loops and TTL • LDP overview • Day in the Life of a Packet
Day in the life of a Packet Address Prefix and mask Next-Hop Interface In I/F In I/F In I/F In Lab In Lab In Lab Address Prefix Address Prefix Address Prefix Out I/F Out I/F Out I/F Out Lab Out Lab Out Lab Serial1 171.68.10/24 171.68.9.1 0 0 0 4 - 7 171.68/16 171.68/16 171.68/16 2 1 1 7 4 pop Next-Hop Next-Hop Next-Hop 171.68.44/24 171.68.12.1 Serial2 ... ... ... ... ... ... ... ... ... ... ... ... ... ... ... 171.68/16 ... Null P P 1 1 2 PE 0 PE 0 0 • Use label “implicit-null” for FEC 171.68/16 0 • Use label 4 for FEC 171.68/16 • Use label 7 for FEC 171.68/16 171.68.44/24 • Summary route for 171.68/16 • Summary route for 171.68/16 CE 171.68.10/24 Summary route is propagate through the IGP and label is assigned by each LSR Egress LSR summarises morespecific routes and advertises a label for the new FEC • Egress LSR needs to do an IP lookup for finding more specific route
Summary • LSRs forward packet based on label information • IP header and forwarding decision have been de-coupled for better flexibility • Label information can derive from different sources • IP routing protocols (destination based unicast routing) • Multicast • Traffic Engineering • QoS • VPN
Summary • MPLS allows flexible packet classification and network resources optimisation • Labels are distributed by different protocols • LDP, RSVP, BGP, PIM • Different distribution protocols may co-exist in the same LSR • Label have local (LSR) significance • No need for global (domain) wide label allocation/numbering