MPLS is usually classified as a 2.5 layer protocol because it operates between layers 2 and 3 of
When a packet gets in a Provider Edge (PE) router, coming from an IP routed network, it’s then classified into a Forwarding Equivalence Class (FEC) depending on its characteristics to receive a label. Once it has a label the MPLS routers (LSR) will forward the labeled packet through Label Switch Paths (LSP) according to the labels it has. The forwarding decision was made before the LSP was created, hence the routers won’t look at the packet’s IP header details to forward it, only at the labels in the MPLS header.
The figure below shows how MPLS process and forwards a packet. When it gets in the MPLS domain, the first PE router pushes a label (according to the FEC), the next one swaps the
The MPLS header goes between Layer 2 and Layer 3 headers. The header is 32 bits long with the following fields:
- Label values: where label number goes
- Exp (Experimental bits): field used to CoS (Class of Service)
- S (Bottom of the stack bit): when set to 1 means that the current label is the last one
- TTL (Time to Live)
- Core MPLS Network: the network, such as a backbone, where MPLS runs
- FEC – Forward Equivalence Class: Based on the packet’s characteristics, such as destination IP, QoS, next-hop, etc., MPLS bundle some packet types in a set to whose it will give the same treating, usually associating those packets to the same label os LSP.
- LSR – Label Switch Router: routers in the MPLS network able to forward packets based on labels. LSR routers are used in the core of the network. This is also a P device; see below.
- LER – Labeled Edge Router: routers used at the edge of the MPLS network, between the MPLS and the IP network. It works as an ingress or egress router pushing or popping labels. LER devices are also PE routers; see below.
- LSP – Label Switch Path: is the path in the MPLS network a packet uses to reach the destination. Even if a packet run across the same routers on its way back, it uses a different LSP, so that LSPs are unidirectional.
- LDP – Label Distribution Protocol: LDP is the industry standard protocol for MPLS label distribution. It runs on multicast (126.96.36.199 – all routers) and uses 646 UDP port. Once it discovers a neighbor, it brings a TCP connection on 646 port up.
- TDP – Tag Distribution Protocol: TDP does the same as LDP, but is Cisco proprietary. It runs on broadcast and uses 711 UDP port. Once it discovers a neighbor, it brings a TCP connection on 711 port up.
- P – Provider Router: routers in the core network, not connected to any client device. It is also an LSR device; see above.
- PE – Provider Edge Router: routers at the edge of the core MPLS network; these routers have at least one interface connected to a P router and at least one interface connected to a Customer Edge router (CE). PE routers as also LER devices; see above.
- CE – Customer Edge: routers connected to a PE router external to the MPLS network. CEs do not receive labels through the links to the PEs; they are out of the MPLS domain.
- Ingress of Egress LSR: they are the PE routers because they are ingress or egress for the MPLS network. They receive a common IP packet from outside MPLS network, insert a label and forward to the MPLS network. When they are at the end of a packet’s path in the MPLS network, they perform the inverse.
- PHP – Penultimate Hop Popping: this feature, when configured in the penultimate router (a router connected to an MPLS edge router), makes the router to pop the label of a packet before to forward it to the edge router. This feature reduces the processing required by the edge router; if it receives a packet with an MPLS label, before the popping operation, it will execute a label lookup.
- MPLS-TE – MPLS Traffic Engineering:
- MP-BGP – Multiprotocol BGP: It is a BGP feature that expands BGP to support and distribute in parallel, but yet separately, different address-families (IPv4 and IPv6 unicast, multicast, VPN) rather than only IPv4 unicast. So, why is it here? Because this feature enables L3 VPNs in an MPLS network.
- David Bombal on Youtube:
- GTA UFRJ – Conceitos MPLS
- My Notes On Routing Protocols
- Perguntas mais freqüentes sobre MPLS para iniciantes