MPLS is an acronym for “Multi-Protocol Label Switching”. Cisco invented it in the ’90s. They gave it the name “Tag switching”. (change name Tag to Label).
Routing (layer 3 network protocol) is an end-to-end protocol. It means the network nodes (routers) must know how to reach all the network endpoints (the destinations).
Learning all the possible routes happens automatically by the routers themselves. Each router will ask the neighbouring routers (these are the other routers to which the router is connected) which IP routes they see and will exchange routes with each other.
From the moment you connect a new customer router to the network’s edge, all routers will learn how to reach this new router by distributing the new route from router to router throughout the network.
Of course, all these routes will create an immense mass of data to store in the router’s memory. The router will have to read the destination IP address of the received packet and look up the next hop to take in its table. He must choose which connection (interface) he sees as the shortest route to forward the packet to the next router.
The longer the list of available routes in his memory, the longer it will take to find the next hop. Routers may have many routes to check in their memory, reducing the packet transfer speed.
On the other hand, switches are less complicated. They look at a link address. However, network management systems have to calculate the end-to-end link to configure switches in large networks. Configuring each network switch is calculated by a network management system. Once done, the switch has only a table with links to its neighbours (a small table with only a few entries per interface).
Cisco intended to combine the advantages of routing (layer 3 end-to-end on a long list of IP addresses) with the advantages of switching (link layer 2 based on short switching tables).
Switching has the advantage of fast packet transfers due to short lookup tables. Switches are looking at a limited switching table. The short switching table only looks locally in its short table on which interface to forward the packet to the next hop.
While routing automatically learns all the existing routes, directing the packet to the appropriate router interface for the next hop becomes relatively slow.
The router must read through a long list of possible routes before deciding which interface to forward the packet.
We may remember the geographical rearrangement of the IP V4 IP addresses. It was an important step to reduce significantly the list of routes that a router needs to memorise.
This move was due to out-of-memory issues for many routers (on the public Internet). They had far too many routes to fit in their memories. The geographical division of the Internet caused a massive decrease in the number of Internet routes.
An IP MPLS network (a network that uses the MPLS protocol) combines both techniques in one network. Routers will learn routes by communicating with each other but will assign an additional label to the packets on the routing information. In the network’s backbone, MPLS routers will not route but switch these packets based on their label (tag).
Like routers learn routes from their neighbouring routers via a route distribution protocol (RDP), routers now also learn labels from each other using the Label Distribution Protocol (LDP).
The labels are inserted at the network’s edge by the provider edge routers (PE). They will find their place between the routing layer(3) and the link layer(2). Therefore, some call MPLS layer 2.5 (not part of the ISO layer model)!
In MPLS, each CE router has virtual routers for each customer connected via his access line. Many customers connect to the same PE router (at the POP). However, inside this router, they connect to their private virtual router with its private virtual forwarding tables. It also means that each customer can use their private IP ranges. Two different customers can use the same range without a problem.
The virtual routers belong to a VPN and have a network identity. The virtual routers inside the PE router communicate routes with other PE routers on the existing VPN IDs.
Based on the label, the network core routers (backbone) will realise fast-forwarding over the network. It results in completely separated VPNs. With MPLS, you can create your private IP network over a shared network infrastructure.
For information about the 7-layer communication stack, we refer to the OSI model of the ISO (“Open System Interface” of the “International Standard Organization”).
For information about the 5-layer TCP/IP stack, we refer to the TCP/IP communication stack.