Supported Platforms
Configuring Traffic Engineering for LSPs
When you configure an LSP, a host route (a 32-bit mask) is installed in the ingress router toward the egress router; the address of the host route is the destination address of the LSP. The bgp option for the traffic engineering statement at the [edit protocols mpls] hierarchy level is enabled by default (you can also explicitly configure the bgp option), allowing only BGP to use LSPs in its route calculations. The other traffic-engineering statement options allow you to alter this behavior in the master routing instance. This functionality is not available for specific routing instances. Also, you can enable only one of the traffic-engineering statement options (bgp, bgp-igp, bgp-igp-both-ribs, or mpls-forwarding) at a time.
![]() | Note: Enabling or disabling any of the traffic-engineering statement options causes all the MPLS routes to be removed and then reinserted into the routing tables. |
You can configure OSPF and traffic engineering to advertise the LSP metric in summary link-state advertisements (LSAs) as described in the section Advertising the LSP Metric in Summary LSAs.
The following sections describe how to configure traffic engineering for LSPs:
Using LSPs for Both BGP and IGP Traffic Forwarding
You can configure BGP and the IGPs to use LSPs for forwarding traffic destined for egress routers by including the bgp-igp option for the traffic-engineering statement. The bgp-igp option causes all inet.3 routes to be moved to the inet.0 routing table.
On the ingress router, include bgp-igp option for the traffic-engineering statement:
You can include this statement at the following hierarchy levels:
- [edit protocols mpls]
- [edit logical-systems logical-system-name protocols mpls]
Note: The bgp-igp option for the traffic-engineering statement cannot be configured for VPN). VPNs require that routes be in the inet.3 routing table.
Using LSPs for Forwarding in Virtual Private Networks
VPNs require that routes remain in the inet.3 routing table to function properly. For VPNs, configure the bgp-igp-both-ribs option of the traffic-engineering statement to cause BGP and the IGPs to use LSPs for forwarding traffic destined for egress routers. The bgp-igp-both-ribs option installs the ingress routes in both the inet.0 routing table (for IPv4 unicast routes) and the inet.3 routing table (for MPLS path information).
On the ingress router, include the traffic-engineering bgp-igp-both-ribs statement:
You can include this statement at the following hierarchy levels:
- [edit protocols mpls]
- [edit logical-systems logical-system-name protocols mpls]
When you use the bgp-igp-both-ribs statement, the routes from the inet.3 table get copied into the inet.0 table. The copied routes are LDP-signaled or RSVP-signaled, and are likely to have a lower preference than other routes in inet.0. Routes with a lower preference are more likely to be chosen as the active routes. This can be a problem because routing policies only act upon active routes. To prevent this problem, use the mpls-forwarding option instead.
Using RSVP and LDP Routes for Forwarding but Not Route Selection
If you configure the bgp-igp or bgpp-igp-both-ribs options for the traffic-engineering statement, high-priority LSPs can supersede IGP routes in the inet.0 routing table. IGP routes might no longer be redistributed since they are no longer the active routes.
If you configure the mpls-forwarding option for the traffic-engineering statement, LSPs are used for forwarding but are excluded from route selection. These routes are added to both the inet.0 and inet.3 routing tables. LSPs in the inet.0 routing table are given a low preference when the active route is selected. However, LSPs in the inet.3 routing table are given a normal preference and are therefore used for selecting forwarding next hops.
When you activate the mpls-forwarding option, routes whose state is ForwardingOnly are preferred for forwarding even if their preference is lower than that of the currently active route. To examine the state of a route, execute a show route detail command.
To use LSPs for forwarding but exclude them from route selection, include the mpls-forwarding option for the traffic-engineering statement:
You can include this statement at the following hierarchy levels:
- [edit protocols mpls]
- [edit logical-systems logical-system-name protocols mpls]
When you configure the mpls-forwarding option, IGP shortcut routes are copied to the inet.0 routing table only.
Unlike the bgp-igp-both-ribs option, the mpls-forwarding option allows you to use the LDP-signaled and RSVP-signaled routes for forwarding, and keep the BGP and IGP routes active for routing purposes so that routing policies can act upon them.
For example, suppose a router is running BGP and it has a BGP route of 10.10.10.1/32 that it needs to send to another BGP speaker. If you use the bgp-igp-both-ribs option, and your router also has a label-switched-path (LSP) to 10.10.10.1, the MPLS route for 10.10.10.1 becomes active in the inet.0 routing table. This prevents your router from advertising the 10.10.10.1 route to the other BGP router. On the other hand, if you use the mpls-forwarding option instead of the bgp-igp-both-ribs option, the 10.10.10.1/32 BGP route is advertised to the other BGP speaker, and the LSP is still used to forward traffic to the 10.10.10.1 destination.
Advertising the LSP Metric in Summary LSAs
You can configure MPLS and OSPF to treat an LSP as a link. This configuration allows other routers in the network to use this LSP. To accomplish this goal, you need to configure MPLS and OSPF traffic engineering to advertise the LSP metric in summary LSAs.
For MPLS, include the traffic-engineering bgp-igp and label-switched-path statements:
You can include these statements at the following hierarchy levels:
- [edit protocols mpls]
- [edit logical-systems logical-system-name protocols mpls]
For OSPF, include the lsp-metric-into-summary statement:
You can include this statement at the following hierarchy levels:
- [edit protocols ospf traffic-engineering shortcuts]
- [edit logical-systems logical-system-name protocols ospf traffic-engineering shortcuts]
For more information about OSPF traffic engineering, see the Junos OS Routing Protocols Configuration Guide.