SR CP Exchange (ISIS)

SR CP Exchange (ISIS)

Hi Guys,

I saw my last post on Segment Routing was well accepted within my linked-in connections, which gave me sufficient fuel to write another one.Many thanks for your likes and comments for the last one.

So, continuing on the same hot topic Segment Routing, i feel the dataplane visualization of SR stack(withing a single IGP domain) is very simple to understand, but did you thought about how the dataplane is built, what control packets are inspected to determine the outgoing label ?

So let me try, to write down the CP process & how i understood it. Assume we have 3 Routers and below is there config.

{{ A }} ------------- {{ B }} ------------- {{ C }}



SID index A : index 6199, SRGB :100000 165534
SID index B : index 6200, SRGB :100000 165534
SID index C : index 6201, SRGB :100000 165534 

Now, to see the SR LSP's to node A, if i go to Router C & B and try to see the LSP Cross connect , they will be as below.

  • at node C, Local label 106199 & out label 106199, outgoing interface towards B
  • at node B, Local label 106199 to Out Label implicit-Null ( Explicit Null is also an option), with outgoing interface towards A.
{{ A }} ------------- {{ B }} ------------- {{ C }}

Outgoing Label:        3                106199
Local label :            X 106199              X 106199

Here the shown X means a Dataplane cross connect.

   

Pretty fine, so data plane is formed. But lets understand how the DP is formed. The DP information has been populated after getting information from Control Plane.SR Control plane protocols are ISIS, OSPF, BGP. For this write-up i am using the example with ISIS.

Now in ISIS, with the support of TLV, Router A sends few details about its loopback to all the routers in same SR domain. Other routers use this Control plane information and form the data plane.At node C, to form the MPLS cross connect, Node C uses the informaton of SRGB and SID-index to calculate the Local and Out label.

SRGB information is learned from Router Capability TLV and SID index is learned from Extended IP Reachability TLV, simple Right !! Lets dig further

  • Router capability TLV (TLV 242)
  • Extended IP Reachability ( TLV 135)

1. Router Capability TLV ( TLV 242)

Router Capability TLV carries some important information like SRGB,SRLB, Algorithm...etc. Refer the below short snippet. As per RFC 8667, Router capability TLV can carry below 4 sub-tlv's. Additionally, TLV 242 can carry Maximum SID depth of the originating Router ( as defined in RFC 8491).

Router Capabilities TLV
Type=242

1. SR-Capabilities Sub-TLV 
          >> used to share SRGB (Global Block) and SR Dataplane Capability
          >> Type = 2

2. SR-Algorithm Sub-TLV 
          >> used to share SR Algorithms supported, Default is 0
          >> Type = 19

3. SR Local Block Sub-TLV
          >> Used to share the SRLB( Local block)
          >> Type = 22

4. SRMS Preference Sub-TLV
          >> Type = 24

 {{ Reffered from RFC 8667 }}


Among them, SR-Capabilities Sub-tlv carries the rerquired SRGB Range information.Other Sub-TLV's and their usage is wrote above. I would like to go in deep with SR-capabilities sub-tlv only.

Format of : SR capabilities Sub TLV
Note : SR-capability sub-tlv can carry SID/label Sub-tlv.( defined in section 2.3 RFC 8667)

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Type        |     Length    |    Flags      |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                     Range                     |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                SID/Label Sub-TLV (variable)   |             
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+++


Format of : SID/label Sub TLV 

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Type        |     Length    |  
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                          SID/Label (variable)                 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+


Lets merge Both of them :

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Type        |     Length    |    Flags      |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                     Range                     |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Type        |     Length    |  
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                          SID/Label (variable)                 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+



In case you see the ISIS database with verbose command, you will see something like below.

Segment Routing: I:1 V:0, SRGB Base: 100000 Range: 65535.

This information is polulated from SR-capability sub-tlv only. Here in this information, basically Router A is sending its SRGB Range.Q. how the SRGB Range is sent ?

Like for example, if i tell you my range is 50 & starting value is 100, then total Range is 100-149 Right !! Router A does the same thing, it sends the range & starting value. Now All router's in the ISIS domain knows that Router A is configured with SRGB Range : 100000-165534.

2. Extended IP Reachability ( TLV 135)

Now coming to the 2nd part of the puzzle, is to share the Index of the SID corresponding to Loopback ip of A to the other nodes.This information is transferred as part of Extended IP Reachability. ( a quick note about extended IP reachability : as the name suggest, this information is about a IP, the Loopback IP, so in other words we are using TLV 135 to share the SID-index for IP prefix (Node A's Loopback)). Under extended IP reachability TLV, a new sub-tlv has been defined by RFC 8667 as Prefix-SID sub-tlv( Type = 3).

Format of Prefix-SID sub-TLV is :

+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|   Type        |     Length    |R|N|P|E|V|L|   |   Algorithm   |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                         SID/Index/Label (variable)            |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+--+-+-+-+-+-+-+--+-+-+-+-+-+

N Flag = 1 , signifies that, this is Node SID
P Flag = 0 , No-PHP flag, 0 Means do PHP on node B towards A
E Flag = 0 , means no explicit Null
V Flag = 0 , used to share an absolute Value instade of a Index.
L Flag = 0 , signify Global or local scope 

Now, using SRGB and SID-index information Router B & C can calulate the MPLS Label for Router A.

at C Out / Local Label = SRGB first Value + SID index.

at node B Out label is : 3 ( due to no-PHP flag set to 0) and Local label = SRGB first value + SID index.

fine enough !!

RFC 8667, describes few additional details about multiple SRGB Range & its application, Please refer them for more information.

A Quick note about Adj-SID:

Additionally for completeness, lets understand how the adj-sid is shared. In my example topology, Adj-sid is not required to form a SR-IGP LSP to node A. Adj-SID label is used in SR-TE computation by an Head end node, or PCE or explicit Manual configuration.

Adj-sid is shared as part of Extended IS Rechability ( TLV 22). TLV 22 carry the information about neighbors. TLV 22 can carry many sub tlv's as defined in RFC 5305. But to carry adj-sid , a new sub tlv has been defined in RFC 8667 ( which is called Adj-sid type 31).

format of Adj-sid : 

    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |   Type        |     Length    |F|B|V|L|S|P|   |     Weight    |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |                         SID/Label/Index (variable)            |
  
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+

Here 
V flag : value flag is set, indicating that its a absolute value rather than a index.
L flag : L flag is set, indicating that its allocated from SRLB Range.

Well this is it for now.

Many thanks for reading this post, Hope this notes will be helpful to you before you Jump into the sea ( RFC 8667).

Thanks again, Good night.

要查看或添加评论,请登录

Dipankar Shaw的更多文章

  • SRv6 L3VPN with Flex-Algo

    SRv6 L3VPN with Flex-Algo

    In my last article i explained a best effort uDT6 service, that sets the foundation for srv6 services & tunnels. Now…

  • SRv6 Tunnel with uDT6 Service SID

    SRv6 Tunnel with uDT6 Service SID

    In this article, I will provide an explanation of SRv6 (Segment Routing over IPv6) and delve into the uDT6 service…

  • UDPPing : Ping-pong with Layer 4

    UDPPing : Ping-pong with Layer 4

    Introduction: Recently i was watching a NANOG Presentation, where they showcased PINGO Project, which is able to…

    2 条评论
  • Sending BGP routes using ExaBGP

    Sending BGP routes using ExaBGP

    Hey all, Recently i came across a problem statement where i wanted to send some good amount of routes via BGP. While…

    3 条评论
  • Arista Segment Routing Config & show commands

    Arista Segment Routing Config & show commands

    Introduction : Will be keeping this post very very short, intention is to capture, how we can configure segment routing…

    2 条评论
  • EVPN VXLAN Inter subnet Routing using Asymmetric IRB model

    EVPN VXLAN Inter subnet Routing using Asymmetric IRB model

    Hello Guys, Frankly speaking, this topic is a complex one to understand if you dont work with evpn, VXLAN and IRB. I…

    1 条评论
  • BGP Unnumbered by Bard

    BGP Unnumbered by Bard

    Introduction BGP unnumbered is a feature that allows BGP to establish peering sessions without explicitly configuring…

    1 条评论
  • Ixia Open Traffic generator & DUT

    Ixia Open Traffic generator & DUT

    Hey, this will be a small post about using ixia open traffic generator, how it can generate some traffic so that…

  • Metallb Loadbalancer With BGP for k8s, Not Rock Music

    Metallb Loadbalancer With BGP for k8s, Not Rock Music

    Ok, 2023 is On. This article will be the 1st one of this year.

  • Default Route to Container lab

    Default Route to Container lab

    inuz Containers are awesome. They are lightweight, spins up too fast.

社区洞察

其他会员也浏览了