Help us improve your experience.

Let us know what you think.

Do you have time for a two-minute survey?

 
 

Example: Configuring SRv6 Network Programming in IS-IS Networks

This example shows how to configure SRv6 network programing in an IS-IS network. This feature is useful for service providers whose networks are predominantly IPv6 and have not deployed MPLS. Such networks depend only on the IPv6 headers and header extensions for transmitting data. SRv6 network programming provides flexibility to leverage segment routing without deploying MPLS.

Requirements

This example uses the following hardware and software components:

  • Eight MX Series routers with MPC7E, MPC8E, or MPC9E line cards

  • Junos OS Release 20.3R1 or later

Overview

Starting in Junos OS Release 20.3R1, you can configure SRv6 without MPLS in a core IPv6 network. SRv6 network programming is the capability of a network to encode a network program into individual network instructions that are then inserted into the IPv6 packet headers. The IPv6 packet carrying the network instructions explicitly tells the network about the precise SRv6 nodes available for packet processing. The network instruction is the SRv6 segment identifier (SID) that is represented by 128-bit IPv6 addresses. These instructions are distributed through the network in the IPv6 packet headers. Along with the addressing, network instructions define a particular task or function for each SRv6-capable node in the SRv6 network. This feature benefits networks that need to deploy SR traffic through transit routers that do not have segment routing capability yet.

Topology

In Figure 1, Router R0 and Router R7 are ingress and egress routers that support IPv4 only devices CE1 and CE2. Routers R1, R2, R3, R4, R5, and R6 comprise an IPv6 only provider core network. All routers belong to the same autonomous system. IS-IS is the interior gateway protocol in the IPv6 core and is configured to support SRv6. In this example the Router R2 is configured as an IPv6 route reflector with IBGP peering sessions to both R0 and R7. No other routers speak BGP in this example.

Note:

To better demonstrate SRv6 tunneling this example is based on a pure IPv6 provider core. SRv6 is supported with a dual stack core where both IPv6 and IPv4 are deployed.

The edge routers that support IPv4 devices need to transport IPv4 traffic using IPv6 tunnel encapsulation. The encapsulation tunnels are derived from SRv6 SIDs configured at SRv6-enabled routers. The IS-IS protocol processes these SRv6 SIDs and updates the inet6.3 table with the next-hop addresses of the available tunnel endpoints. When an IPv4 route is learned through BGP the router attempts to resolve the associated next hop through the inet6.3 table. When a matching entry is found the result is an automatic IPv6 tunnel to the endpoint that advertised the BGP route.

In this example both the R0 and R7 routers advertise their attached IPv4 subnet using BGP. This results in IPv6 tunnels between the edge routers. The tunnels are used to transport the IPv4 traffic over the IPv6 provider core. At egress, the edge routers decapsulate the outer IPv6 header and perform an IPv4 route lookup to forward the packet to its destination.

Figure 1: SRv6 Network Programming in IS-ISSRv6 Network Programming in IS-IS

Configuration

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.

Router R0

Router R1

Router R2

Router R3

Router R4

Router R5

Router R6

Router R7

Configuring Router R0

The following example requires that you 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 SRv6 network programming to support IPv4 tunnels over a IPv6 core, perform the following steps on the R0 router:

Step-by-Step Procedure

  1. Configure the device interfaces to enable IP transport.

  2. Configure the loopback interface with IPv4 and IPv6 addresses that is used as router ID for BGP sessions.

  3. Configure the router ID and autonomous system (AS) number to propagate routing information within a set of routing devices that belong to the same AS.

  4. Enable SRv6 globally and the locator address to indicate the SRv6 capability of the router. SRv6 SID is an IPv6 address that consists of the locator and a function. The routing protocols advertise the locator addresses.

  5. Configure the End-Sid function for the prefix segments. Specify a flavor, that is the behavior of the End-SID function as per your network requirements. Penultimate Segment Pop (PSP), Ultimate Segment Pop (USP), and Ultimate Segment Decapsulation (USP) are the three available flavors for SRv6 functions.

    Note:

    Ensure that the locator and the End-SID are in the same subnet to avoid a commit error.

  6. Configure End-X-SID function on the point-to-point (P2P) interface for the adjacency segments. Specify one or more flavor for the End-X-SID.

    Note:

    Ensure that the Locator and End-X-SID are in the same subnet to avoid a commit error. You must enable SRv6 and configure the locator at the [edit routing-options] before mapping locators to interfaces.

    Whenever you configure an srv6-adjacency-segment you must also configure the related locator under the protocols isis source-packet-routing srv6 locator hierarchy, as shown in step 5.
  7. Configure SRv6 options for the adjacency segment of the LAN interface xe-0/0/0:2.0. Specify a flavor as per your network requirements. Penultimate Segment Pop (PSP), Ultimate Segment Pop (USP), and Ultimate Segment Decapsulation (USP) are the three available flavors for the SRv6 adjacency segment.

    Note:

    Ensure that the Locator and End-X-Sid are in the same subnet to avoid a commit error. You must enable SRv6 and configure the locator at the [edit routing-options] before mapping locators to interfaces.

  8. Configure BGP on the core-facing interface to establish internal peering sessions.

  9. Define a policy to load balance packets.

  10. Apply the per-packet policy to enable load balancing of traffic.

Results

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

When done configuring the device, enter commit from configuration mode.

Verification

Confirm that the configuration is working properly.

Verifying IS-IS Adjacency and IBGP Session

Purpose

Verify IS-IS adjacencies and IBGP session at R2. R2 is chosen for this task because it has 5 adjacencies and also serves as the router reflector for the BGP control plane.

Note:

Its a good idea to confirm the IS-IS adjacencies on all routers before proceeding to the remaining verification steps. A successful SRv6 deployment requires that the interior gateway protocol is operational on all nodes.

Action

From operational mode, run the show isis adjacency command on router R2.

From operational mode, run the show bgp summary command on router R2.

Meaning

The output confirms the expected IS-IS adjacency count for the R2 router. It also confirms that R2 has established IPv6 based BGP sessions to both the R0 and R7 routers.

Verify SRv6 is Enabled

Purpose

Verify that SRv6 is enabled with a locator, End-SID, and flavor on Router R0.

Action

From operational mode, run the show isis overview command on Router R0.

Meaning

The configured SRv6 locator SRv6: Enabled Locator: 2001:db8:0:a0::/64, Algorithm: 0 and , End-SID and flavor END-SID: 2001:db8:0:a0:d01::, Flavor: USD are displayed in the output.

Verify the SRv6 End-X-SID Configuration

Purpose

Verify that an End-X-SID function and flavor are configured on R0.

Action

From operational mode, run the show isis adjacency detail command on Router R0.

Meaning

The field SRv6 protected END-X-SID: 2001:db8:0:a0:1a01:: indicates that End-X-SID function with Flavor PSP has been configured on router R0 for the interface used to attach to R1. Similar output is confirmed for the interface connected to R4, which uses a different End-X-SID.

Verifying the Locator Route is Installed

Purpose

Verify that the locator route has been installed.

Action

From operational mode, run the show route 2001:db8:0:a0::/64 detail command on router R0.

Meaning

The output confirms the locator route 2001:db8:0:a0::/64*[IS-IS/18] is installed in the inet6.0 table.

Verifying the End-X-SID Route is Installed

Purpose

To display the configured End-X-SID route information that is applied at the interface.

Action

From operational mode, run the show route 2001:db8:0:a0:1a01:: command on Router R0.

Meaning

The output confirms the End-X-SID route 2001:db8:0:a0::1a01/128 is installed in the inet.6.0 routing table.

Verifying the End-SID Route is Installed

Purpose

Verify that the End-SID routes for all routers in the SRv6 domain are installed in the inet6.3 table at Router R0.

Action

From operational mode, run the show route table inet6.3 protocol isis command on Router R0 to see all End-SIDs the router has learned. Then display detailed information about the End-SID associated with the R7 router.

Meaning

The output confirms that Router R0 has learned End-SIDs, that is, 2001:db8:0:a1::d11/128 and 2001:db8:0:a2::d21/128, from all other routers in the topology. Note the End-SIDs have been installed in the inet6.3 table. The detailed output for the End-SID advertised by R7 2001:db8:0:a7:d71:: confirms an SRv6 tunnel has been established between Router R0 and Router R7.

Note that the segment list is populated with the End-SID value configured on the Router R7. Recall that all End-SIDs in this example are configured with the Ultimate Segment Decapsulate (USD) flavor. It’s the combination of a local End-SID and the associated USD flavor that tells R7 it’s the egress of the IPv6 tunnel. Upon receipt R7 decapsulates the IPv4 packet and routes it according to the IPv4 destination address.

Verify the SRv6 Configuration in the IS-IS Database

Purpose

Display the IS-IS database to verify the End-SID and flavor configured at Router R7. In this example the command is executed on Router R0. Similar output is expected on all router because the IS-IS database is replicated to all nodes.

Action

From operational mode, run the show isis database R7.00-00 extensive command on Router R0.

Meaning

The presence of SRv6 SID: 2001:db8:0:a7:d71:: with Flavor: USD confirms that SRv6 is enabled with a SID decapsulate flavor on the R7 router. The output also shows that the interfaces at R7 have been configured for TI-LFA protection using a PSP flavor.

Verifying the Route to CE2 Uses an SRv6 Tunnel

Purpose

Display the route to the IPv4 subnet at R7 to confirm the next hop points to an SRv6 tunnel.

Action

From operational mode, run the show route 172.16.20.0/24 command on router R0.

Meaning

The output confirms that R0 has learned the route to the 172.16.20.0/24 subnet through its BGP session to R2, which recall is configured as a route reflector in this example. The next hops confirm that an SRv6 tunnel to the R7 router has been installed for this route. Two next hops are available in keeping with their being two equal cost paths between the R0 and R7 routers in the example topology.

Test IPv4 Connectivity Between CE1 and CE2

Purpose

Generate pings to verify IPv4 connectivity between the CE devices over the IPv6 provider core.

Action

From operational mode, run the ping 172.16.20.2 source 172.16.10.2 count 2 command on router R0.

Meaning

The output confirms IPv4 connectivity is working between the CE device networks. This provides verification that SRv6 tunneling over an IPv6 provider core is working properly in this example.