MPLS, VPN and VLAN

The fundamental concept behind MPLS is that of labeling packets. In a traditional routed IP network, each router makes an independent forwarding decision for each packet based solely on the packet’s network-layer header. Thus, every time a packet arrives at a router, the router has to identify what that packet is for (voice, data, video, application) and how to prioritize and where to route the packet next.

With MPLS, the first time the packet enters a network, it’s assigned to a specific forwarding equivalence class (FEC), indicated by appending a short bit sequence (the label) to the packet. Each router in the network has a table indicating how to handle packets, so once the packet has entered the network, routers do not need to perform header analysis. Instead, subsequent routers use the label as an index into a table that provides them with a new FEC for that packet.

This gives the MPLS network the ability to handle packets with particular characteristics (such as coming from particular ports or carrying traffic of particular application types) in a consistent fashion. Packets carrying real-time traffic, such as voice or video, can easily be mapped to low-latency routes across the network (prioritizing those packets) — something that’s challenging with conventional routing. The key architectural point with all this is that the labels provide a way to “attach” additional information to each packet — information above and beyond what the routers previously had.

Layer 2 or Layer 3?

There’s been a lot of confusion over the years about whether MPLS is a Layer 2 or Layer 3 service. But MPLS doesn’t fit neatly into the OSI seven-layer hierarchy. In fact, one of the key benefits of MPLS is that it separates forwarding mechanisms from the underlying data-link service.

The bottom line is that carriers can use MPLS to deliver a wide variety of services. The two most popular implementations of MPLS are layer 3 BGP/MPLS-VPNs  and Layer 2  Point to Point/VPNs.