Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Example: Tunneling LDP over SR-TE in OSPF Network

Overview

This example shows how to configure LDP tunneling over SR-TE in an OSPF network. This is illustrated by verifying that the LDP over SR-TE tunnel is enabled and the LDP tunnel to the remote edge device takes the right path. It also shows that the route to the remote edge device uses LDP forwarding and is tunneled over SR-TE. In the following topology (Figure 1), PE1 and PE2 are ingress and egress devices that support IPv4 only devices CE1 and CE2. The devices R1, R2, R3, and R4 comprise an IPv4 only SR-TE core network. The topology shows two LDP domains: LDP domain consists of devices CE1 and PE1; LDP domain B consists of devices PE2 and CE2. The LDP domains are connected to the SR-TE core network, which extends the LSP session over the core by tunneling them over SR-TE.

Topology

Figure 1: Tunneling LDP over SR-TE in OSPF NetworkTunneling LDP over SR-TE in OSPF Network

Requirements

This example uses the following hardware and software components:

  • MX Series routers as CE, PE, and core routers.

  • Junos OS Release 22.4R1 or later running on all devices.

Configuration

To tunnel LDP LSP over SR-TE in your core network, perform these tasks:

CLI Quick Configuration

To quickly configure this example, copy the following commands, paste them into a text file, remove any line breaks, change any details necessary to match your network configuration, copy and paste the commands into the CLI at the [edit] hierarchy level, and then enter commit from configuration mode.

Note: When you configure the enhanced-ip statement and commit the configuration, the following warning message appears prompting you to reboot the router:The reboot brings up the FPCs on the router.

Device CE1

Device PE1

Device R1

Device R2

Device R3

Device R4

Device PE2

Device CE2

Configuring PE1

Step-by-Step Procedure

The following example requires you to navigate various levels in the configuration hierarchy. For information about navigating the CLI, see Using the CLI Editor in Configuration Mode in the CLI User Guide.

To configure device PE1:

  1. Configure the network services mode as Enhanced IP. Enhanced IP sets the router's network services to enhanced Internet Protocol and uses enhanced mode capabilities.

  2. Configure the device's interfaces.

  3. Configure policy options to export BGP routes to the CE router, which runs the OSPF protocol in this example.

  4. Configure a Layer 3 VPN routing instance to support the OSPF-based CE1 device.

  5. Configure the router ID and autonomous system number for Device PE1.

  6. Configure OSPF, LDP, and MPLS on the interfaces connected to the core network.

  7. Configure BGP between the PE devices.

Results

From configuration mode, confirm your configuration by entering the show chassis, show interfaces, show policy-options, show routing-instances,show routing-options, and show protocols commands. If the output does not display the intended configuration, repeat the instructions in this example to correct the configuration.

Configuring R1 Device

Step-by-Step Procedure

The following example requires you to navigate various levels in the configuration hierarchy. For information about navigating the CLI, see Using the CLI Editor in Configuration Mode in the CLI User Guide.

To configure device R1:

  1. Configure the network services mode as Enhanced IP. Enhanced IP sets the router's network services to enhanced Internet Protocol and uses enhanced mode capabilities.

    After you configure the enhanced-ip statement and commit the configuration, the following warning message appears prompting you to reboot the router:

    The reboot brings up the FPCs on the router.

  2. Configure the device's interfaces.

  3. Configure routing options to identify the router in the domain.

  4. Configure OSPF adjacency SIDs on the interfaces and allocate SRGB labels to enable segment routing. The labels in the entire SRGB are available for OSPF. Prefix SIDs (and Node SIDs) are indexed from the SRGB.

  5. Configure TI-LFA to enable protection against link and node failures. SR using TI-LFA provides faster restoration of network connectivity by routing the traffic instantly to a backup or an alternate path if the primary path fails or becomes unavailable.

  6. Configure OSPF traffic engineering parameters.

  7. Enable LDP tunneling over SR-TE.

  8. Configure MPLS and LDP protocols on the interfaces in the LDP domain to exchange labels in the LDP domain.

  9. Enable targeted LDP session between the edge routers in the LDP domain.

  10. Configure a segment list to route the traffic to a specific path.

  11. Configure SR-TE LSP to the remote edge routers to enable LDP tunneling over SR-TE.

Results

From configuration mode, confirm your configuration by entering the show chassis, show interfaces, show routing-options, and show protocols commands. If the output does not display the intended configuration, repeat the instructions in this example to correct the configuration.

Verification

To confirm that the configuration is working properly, perform the following tasks:

Verifying LDP Tunneling over SR-TE

Purpose

Verify that the LDP over SR-TE tunnel is enabled and the LDP tunnel to the remote edge router is taking the right path.

Action

From operational mode, run the show spring-traffic-engineering lsp detail command.

On R1

On R2

Meaning

  • On R1, the LDP tunnel is established with the remote edge router 192.168.100.2 in the SR-TE core network. You can also see the SID label values 80104, 80204, 80304 in the output.

  • On R2, the LDP tunnel is established with the remote edge router 192.168.100.1 in the SR-TE core network. You can also see the SID label values 80504, 80300, 80200 in the output.

Verifying the Advertised Label

Purpose

Verify the labels advertised for the forwarding equivalence class (FEC).

Action

From operational mode, run the show ldp database command.

On R1

Verify the labels advertised towards the directly connected PE (PE1) and the labels received from remote edge router (R2).

On R2

Verify the labels advertised towards the directly connected PE (PE2) and the labels received from remote edge router (R1).

On PE1

Verify the label for the remote PE (PE2) device's loopback address is advertised by edge device R1 to the local PE (PE1) device.

On PE2

Verify the label for the remote PE (PE1) device's loopback address is advertised by edge device R2 to the local PE (PE2) device.

Meaning

  • On R1, you can see label 4117 is advertised towards the directly connected PE (PE1) and the label 27 is received from remote edge router (R2).

  • On R2, you can see label 18 is advertised towards the directly connected PE (PE2) and the label 25 is received from remote edge router (R1).

  • On PE1, you can see label 4117 is received from the local edge router (R1).

  • On PE2, you can see label 18 is received from the local edge router (R2).

Verify LDP Forwarding to the Remote PE Device

Purpose

Verify that the route to the remote PE router uses LDP forwarding and is tunneled over SR-TE.

Action

From operational mode, run the show route destination-prefix command.

On R1

Verify that the route to the remote PE (PE2) router is through LDP over SR-TE tunnel.

On R2

Verify that the route to the remote PE (PE1) router is through LDP over SR-TE tunnel.

On PE1

Verify that the route to the remote PE (PE2) router is through a targeted LDP session to the remote PE.

On PE2

Verify that the route to the remote PE (PE1) router is through a targeted LDP session to the remote PE.

Meaning

  • On R1, you can see the LDP label as 16 and the SR-TE label stacks as 80304, 80204, 85003, 85004.

  • On R2, you can see the LDP label as 22 and the SR-TE label stacks as 80200, 80300, 85004, 85003.

  • On PE1 and PE2, you can see the LDP label as 4117 and 20, respectively.

Verify End-to-End Reachability

Purpose

Verify CE1 can ping CE2 by using the ping 192.168.100.22 source 192.168.100.11 count 2 operational mode command.

Action

Meaning

The output from CE1 shows that CE1 can ping CE2.