MPLS Labels and Devices

In my introduction to MPLS I explained why we use MPLS and explained some of the basics of how we use labels for forwarding decisions. In this lesson, we’ll take a closer look at the MPLS labels, the devices that we use and how IP packets travel through the MPLS network.

MPLS Label Format

The MPLS header has been standardized, you can find it in RFC 3032. The header is pretty simple, here’s what it looks like:

MPLS Label Header

Here’s what the different fields are used for:

  • Label value: the name says it all, this is where you will find the value of the label.
  • EXP: these are the three experimental bits. These are used for QoS, normally the IP precedence value of the IP packet will be copied here.
  • S: this is the “bottom of stack” bit. With MPLS it’s possible to add more than one label, you’ll see why in some of the MPLS VPN lessons. When this bit is set to one, it’s the last MPLS header. When it’s set to zero then there is one or more MPLS headers left.
  • TTL: just like in the IP header, this is the time to live field. You you can use this for traces in the MPLS network. Each hop decrements the TTL by one.

The MPLS header is added in between the L2 and L3 header:

MPLS Header Between Layer 2 3

That’s why we call it a “layer 2.5” protocol. Here’s an example of what it looks like in wireshark:

wireshark capture mpls header

Above you have an example of the MPLS header in between the Ethernet and IP header. You can also see the different fields, this header uses label value 16. We don’t use QoS and since there is only one MPLS header, the bottom of label stack bit has been set.

Where did the label value come from? MPLS uses a protocol called LDP (Label Distribution Protocol) for this. You will learn about it in the next lesson.

MPLS Devices and Operations

Now you know what the MPLS labels look like, let’s talk about a bit about the different devices you will encounter in a MPLS network. Here’s an overview:

MPLS Network Topology

Above you will find three different routers:

  • CE (Customer Edge): this device is the last device in the customer’s network, it could be a L2 or L3 device. In my picture I used a router but for example, it could be a switch. This device does not use MPLS.
  • PE (Provider Edge): this device is owned by the ISP and sits at the edge of the ISP’s network. It has an important role…it receives packets or frames from the customer and will then add a MPLS label to it and forwards towards the core. Another common name for this device is LER (Label Edge Router).
  • P (Provider): this device connects to PE routers and other P routers. It has a simple job, it switches packets based on their labels or removes the labels. Another common name for this device is the LSR (Label Switch Router) or transit router.

There are three actions we can perform with labels:

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

  • Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.
  • Try for Just $1. The Best Dollar You've Ever Spent on Your Cisco Career!
  • Full Access to our 662 Lessons. More Lessons Added Every Week!
  • Content created by Rene Molenaar (CCIE #41726)

519 Sign Ups in the last 30 days

satisfaction-guaranteed
100% Satisfaction Guaranteed!
You may cancel your monthly membership at any time.
No Questions Asked!

Forum Replies

  1. I am a bit confused when you say “BGP free core”. If we are using iBGP between the PE routers then how can it still be a BGP free core? Or does this simply mean there is no BGP process running on the ‘P’ router?

  2. Hi Praveen,

    These are different topics with different solutions. First of all, keep in mind that VPN is often used to talk about encryption / authentication / security but this is not always the case. Even a VLAN could be considered a VPN, it’s “virtual” and a “private network”.

    Let me give you a quick overview in a nutshell:

    • MPLS VPN: we use this for connectivity. service providers offer MPLS for remote connectivity. For details, check the MPLS material. The "VPN" part of MPLS is that we use VRFs to separate customer routing information and we create unique
    ... Continue reading in our forum

  3. In the lesson CE <-> PE is BGP
    PE <-> P is ospf

    I tried to create a similar lab. I find that there is only a LSP if the router has a route for the destination.
    So how does the P router have an LSP for 5.5.5.5 and 1.1.1.1 ?

    PE1#show mpls forwarding-table 
    Local      Outgoing   Prefix           Bytes Label   Outgoing   Next Hop    
    Label      Label      or Tunnel Id     Switched      interface              
    16         17         4.4.4.4/32       0             Gi0/2      192.168.23.3
    17         Pop Label  192.168.34.0/24  0             Gi0/2      192.168.23.3
    18  
    ... Continue reading in our forum

  4. Hi @kayoutoure

    It might help to think about this the other way around, let’s say we don’t use MPLS but BGP on all P and PE routers. This means that:

    * The P routers have to do a lookup in their routing tables for every destination.
    * The P routers have to know about every destination…this means you’ll have to redistribute customer information into BGP.
    * iBGP has to be a full mesh so if you add another P router in your network, you’ll have to establish neighbor adjacencies with all other iBGP routers. You can make your life a bit easier with route reflectors an

    ... Continue reading in our forum

  5. Hello Zaman

    MPLS functions on many vendors’ equipment as it is an open method of data-carrying. Cisco chooses to implement MPLS in combination with CEF because of their similarities in functions and the efficiency this introduces. Essentially, CEF functionality complements MPLS.

    MPLS is like CEF because it generates a table with mappings from incoming labels to outgoing labels and nex

    ... Continue reading in our forum

111 more replies! Ask a question or join the discussion by visiting our Community Forum