16-24
ATM Switch Router Software Configuration Guide
OL-7396-01
Chapter16 Configuring Tag Switching and MPLS
MPLS Overview
exchanges between network routing platforms is identical. The differences between LDP and TDP for
those features supported by both protocols are largely embedded in their respective implementation
details. For more information on MPLS/tag switching terminology, refer to the Cisco IOS Switching
Services Configuration Guide, Release 12.1.
How MPLS Works
In conventional Layer 3 forwarding, as a packet traverses the network, each router extracts all the
information relevant to forwarding the packet from the Layer 3 header. This information is then used as
an index for a routing table lookup to determine the pac ket's next hop.
In the most common case, the only relevant field in the header is the destination address field, but in
some cases other header fields may also be relevant. As a result, the header analysis must be done
independently at each router through which the packet passes, and a complicated lookup must also be
done at each router.
In MPLS, the analysis of the Layer 3 header is done just once, when the packet enters the network at the
ingress LSR (label switch router). This LSR reads the Layer 3 header and inserts a small fixed-format
label in front of each data packet. For ATM MPLS connections, the label used is the VPI/VCI of the
virtual circuit.The Layer 3 header is then mapped into a fixed length, unstructured value called a label.
Many different headers can map to the same label, as long as those headers always result in the same
choice of next hop. In effect, a label represents a forwarding equivalence class—that is, a set of packets,
which, however different they may be, are indistinguishable to the forwarding function.
The initial choice of label need not be based exclusively on the contents of the Layer 3 header; it can
also be based on policy. This allows forwarding decisions at subsequent hops to be based on policy as
well.
Once a label is chosen, a short label header is put at the front of the Layer 3 packet, so that the label
value can be carried across the network with the packet. At each subsequent hop, the forwarding decision
can be made simply by looking up the label. There is no need to re-analyze the header. Since the label
is a fixed length an unstructured value, looking it up is fast and simple.
A label represents a forwarding equivalence class, but it does not represe nt a particular path through the
network. In general, the path through the network continues to be chosen by the existing Layer 3 routing
algorithms such as OSPF, Enhanced IGRP, and BGP. That is, at each hop when a label is looked up, the
next hop chosen is determined by the dynamic routing algorithm.
The 32-bit MPLS label is located after the Layer 2 header and before the IP header. The MPLS label
contains the following fields:
The label field (20-bits) carries the actual value of the MPLS label.
The CoS field (3-bits) can affect the queuing and discard algorithms app lied to the packet as it is
transmitted through the network.
The Stack (S) field (1-bit) supports a hierarchical label stack.
The TTL (Time to Live) field (8-bits) provides conventional IP TTL functionality.
The MPLS label is also called a “Shim” header.