MPLS and Routing Tables
The IGPs and BGP store their routing information in the routing table
inet.0, which is the main IP routing table. Iftraffic-engineering bgpis configured, thereby allowing only BGP to use MPLS paths for forwarding traffic, MPLS path information is stored in a separate routing table,inet.3. Only BGP accesses theinet.3routing table. BGP uses bothinet.0andinet.3to resolve next-hop addresses. Iftraffic-engineering bgp-igpis configured, thereby allowing the IGPs to use MPLS paths for forwarding traffic, MPLS path information is stored in theinet.0routing table. (Figure 12 and Figure 13 illustrate the routing tables in the two traffic engineering configurations.)
![]()
The
inet.3routing table contains the host address of each LSP's egress router. This routing table is used on ingress routers to route packets to the destination egress router. BGP uses theinet.3routing table on the ingress router to help in resolving next-hop addresses.MPLS also maintains an MPLS path routing table (
mpls.0), which contains a list of the next label-switched router in each LSP. This routing table is used on transit routers to route packets to the next router along an LSP.Typically, the egress router in an LSP does not consult the
mpls.0routing table. (This router does not need to consultmpls.0because the penultimate router in the LSP either changes the packet's label to a value of 0 or pops the label.) In either case, the egress router forwards it as an IPv4 packet, consulting the IP routing table,inet.0, to determine how to forward the packet.When a transit or egress router receives an MPLS packet, information in the MPLS forwarding table is used to determine the next transit router in the LSP, or to determine that this router is the egress router.
When BGP resolves a next-hop prefix, it examines both the
inet.0andinet.3routing tables, seeking the next-hop with the highest preference. If it finds a next-hop entry with an equal preference in both routing tables, BGP prefers the entry in theinet.3routing table.
![]()
Generally, BGP selects next-hop entries in the
inet.3routing table, because their preferences are always lower than OSPF and IS-IS next-hop preferences. When you configure LSPs, you can override the default preference for MPLS LSPs, which might alter the next-hop selection process.When BGP selects a next-hop entry from the
inet.3routing table, it installs that LSP into the forwarding table in the Packet Forwarding Engine, which causes packets destined for that next-hop to enter and travel along the LSP. If the LSP is removed or fails, the path is removed from theinet.3routing table and from the forwarding table, and BGP reverts to using a next-hop from theinet.0routing table.