Cisco NSO Transport SDN Function Pack Bundle User Guide Version 1 0 0 PDF
Cisco NSO Transport SDN Function Pack Bundle User Guide Version 1 0 0 PDF
Cisco NSO Transport SDN Function Pack Bundle User Guide Version 1 0 0 PDF
Bundle
User Guide
Version 1.0.0
May 2020
Cisco NSO Transport SDN Function Pack Bundle - User Guide
Total page: 186
THE SPECIFICATIONS AND INFORMATION REGARDING THE PRODUCTS IN THIS MANUAL ARE SUBJECT TO CHANGE WITHOUT NOTICE. ALL
STATEMENTS, INFORMATION, AND RECOMMENDATIONS IN THIS MANUAL ARE BELIEVED TO BE ACCURATE BUT ARE PRESENTED
WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED. USERS MUST TAKE FULL RESPONSIBILITY FOR THEIR APPLICATION OF ANY
PRODUCTS.
THE SOFTWARE LICENSE AND LIMITED WARRANTY FOR THE ACCOMPANYING PRODUCT ARE SET FORTH IN THE INFORMATION PACKET
THAT SHIPPED WITH THE PRODUCT AND ARE INCORPORATED HEREIN BY THIS REFERENCE. IF YOU ARE UNABLE TO LOCATE THE
SOFTWARE LICENSE OR LIMITED WARRANTY, CONTACT YOUR CISCO REPRESENTATIVE FOR A COPY.
The Cisco implementation of TCP header compression is an adaptation of a program developed by the University of California, Berkeley (UCB) as part of
UCB’s public domain version of the UNIX operating system. All rights reserved. Copyright © 1981, Regents of the University of California.
NOTWITHSTANDING ANY OTHER WARRANTY HEREIN, ALL DOCUMENT FILES AND SOFTWARE OF THESE SUPPLIERS ARE PROVIDED “AS
IS” WITH ALL FAULTS. CISCO AND THE ABOVE-NAMED SUPPLIERS DISCLAIM ALL WARRANTIES, EXPRESSED OR IMPLIED, INCLUDING,
WITHOUT LIMITATION, THOSE OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT OR ARISING FROM
A COURSE OF DEALING, USAGE, OR TRADE PRACTICE.
IN NO EVENT SHALL CISCO OR ITS SUPPLIERS BE LIABLE FOR ANY INDIRECT, SPECIAL, CONSEQUENTIAL, OR INCIDENTAL DAMAGES,
INCLUDING, WITHOUT LIMITATION, LOST PROFITS OR LOSS OR DAMAGE TO DATA ARISING OUT OF THE USE OR INABILITY TO USE THIS
MANUAL, EVEN IF CISCO OR ITS SUPPLIERS HAVE BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.
Any Internet Protocol (IP) addresses and phone numbers used in this document are not intended to be actual addresses and phone numbers. Any
examples, command display output, network topology diagrams, and other figures included in the document are shown for illustrative purposes only. Any
use of actual IP addresses or phone numbers in illustrative content is unintentional and coincidental.
Cisco and the Cisco logo are trademarks or registered trademarks of Cisco and/or its affiliates in the U.S. and other countries. To view a list of
Cisco trademarks, go to this URL: www.cisco.com/go/trademarks. Third-party trademarks mentioned are the property of their respective
owners. The use of the word partner does not imply a partnership relationship between Cisco and any other company. (1721R)
Copyright
© 2020 Cisco Systems, Inc. All rights reserved.
Cisco has more than 200 offices worldwide. Addresses, phone numbers, and fax numbers are listed on the Cisco Website at www.cisco.com/go/offices.
Contents Page 3
1 Contents
1 Contents ....................................................................................... iii
2 Preface ........................................................................................... 6
3 Getting Started............................................................................... 7
3.1 Cisco Network Services Orchestrator - Overview ................................. 7
3.2 Cisco NSO Transport SDN Function Pack Bundle - Overview ............... 9
3.3 T-SDN Function Packs Bundle Architecture ........................................ 10
4 SR-TE Core Function Pack ............................................................. 13
4.1 SR-TE ODN........................................................................................... 13
4.2 SR-Policy ............................................................................................. 13
5 Example Function Packs ............................................................... 15
5.1 SR-Settings .......................................................................................... 15
5.2 SR-PCE ................................................................................................. 15
5.3 L2VPN.................................................................................................. 15
5.4 L3VPN.................................................................................................. 16
6 Configuration ............................................................................... 17
6.1 Creating SR-TE Services ...................................................................... 17
6.1.1 Creating SR-ODN ................................................................. 17
6.1.2 Creating SR-Policies ............................................................. 19
6.2 Creating SR-Settings Services ............................................................. 20
6.2.1 Allocating Resources by Using Resource Pools ................... 22
6.3 Creating SR-PCE Services .................................................................... 30
6.4 Creating Flat L2VPN Services with the L2VPN Example Function Pack
............................................................................................................ 32
6.4.1 Creating Flat L2VPN-P2P ..................................................... 32
6.4.2 Creating Flat L2VPN – EVPN ................................................ 34
6.5 Creating Flat L3VPN Services with the L3VPN Example Function Pack
............................................................................................................ 39
6.5.1 Creating Flat L3VPN ............................................................. 39
6.5.2 Creating L3VPN SR-TE ODN ................................................. 41
6.5.3 Creating BVI L3VPN ............................................................. 44
7 Working with Action Commands .................................................. 46
7.1 Service Cleanup Actions...................................................................... 46
7.1.1 SR-ODN ................................................................................ 47
7.1.2 SR-Policy .............................................................................. 48
7.1.3 SR-Settings........................................................................... 48
7.1.4 SR-PCE ................................................................................. 49
7.1.5 L2VPN Example Services ..................................................... 50
7.1.6 L3VPN Example Services ..................................................... 51
7.2 Auto Cleanup ...................................................................................... 51
7.3 get-modifications Action .................................................................... 53
7.3.1 SR-ODN ................................................................................ 53
7.3.2 SR-Policy .............................................................................. 55
7.3.3 SR-Settings........................................................................... 55
Rev. 1.0.0 Cisco NSO Transport SDN Function Pack Bundle User Guide
Contents Page 4
Rev. 1.0.0 Cisco NSO Transport SDN Function Pack Bundle User Guide
Contents Page 5
Rev. 1.0.0 Cisco NSO Transport SDN Function Pack Bundle User Guide
Preface Page 6
2 Preface
Abstract
This document serves as the documentation reference and user guide for the
NSO Transport SDN Function Pack (T-SDN FP) Bundle. This document is
applicable to T-SDN FP Bundle version 1.0.0.
Audience
This document describes how to configure and use the T-SDN function packs.
This document is intended for Cisco Advanced Services developers, network
engineers, and system engineers who install, configure, and deliver the T-SDN
automation functionalities to Cisco customers.
Additional Documentation
This documentation requires the reader to have a good understanding of
Cisco NSO and its usage as described in the Cisco NSO documentation. For
documentation on additional Cisco products, see the Cisco documentation
website.
3 Getting Started
This topic provides an overview of Cisco Network Services Orchestration
(NSO) and an understanding of Cisco Transport SDN function packs.
You can also upload the configuration information to NSO by using the
payloads. These payloads contain the desired service configurations in an XML
format. Each service can have a single file or multiple files. Deploy the
configuration information by using payloads through the NSO CLI or by
invoking the Northbound interface to create and modify service
configurations. This documentation uses both network CLI and sample XML
payloads.
# netconf-console --port=[port_number]--host=[host_IP_address] -u
[username] -p [password] --edit-config payload.xml
Example
# netconf-console --port=830 --host=127.0.0.1 -u admin -p Fr3eB!rd$ --
edit-config payload.xml
Run the following command to get the configuration details from the
configuration database in the NSO. For more information about NETCONF, see
Cisco Networking Services Configuration Guide.
# netconf-console --port=[port_number]--host=[host_IP_address] -u
[host_username] -p [host_password] –get get-config
Example
# netconf-console --port=830 --host=127.0.0.1 -u admin -p Fr3eB!rd$ –get get-
config
NETCONF supports the following operations:
• <get-config>
• <edit-config> (operation="create")
• <edit-config> (operation="replace")
• <edit-config> (operation="merge")
• <edit-config> (operation="delete")
The typical workflow when using the network CLI in NSO is as follows:
• All changes are initially made to a (logical) copy of the NSO database of
configurations.
• You can view and verify the changes prior to committing them.
• The changes are committed, meaning that the changes are copied to
the NSO database and pushed out to the network. Changes that
violate integrity constraints or network policies are not committed.
The changes to the devices are done in a holistic distributed atomic
transaction, across all devices in parallel.
Changes either succeed and remain committed or fail and are rolled back as a
whole, returning the entire network to the uncommitted state.
SR-TE CFP configures the SR-TE policies and instantiates services. Using the
network topology and inventory collected, SR-TE CFP solution supports the
example function packs SR-Settings and SR-PCE. L3VPN and L2VPN services
can then be provisioned with specified segment routing policy. These example
function packs utilize SR-TE policies for service instantiation.
SR-TE CFP provides the SR-TE policies and SR-ODN services. T-SDN FPs
configure the SR-TE policies and instantiates services, such as the SR-Settings,
SR-PCE, L2VPN and/or L3VPN function packs that utilize these SR-TE policies.
Note: The example function packs can be used for reference
implementations.
SR-TE Settings allows you to configure the following on the head-end:
➢ Affinity
➢ Interface affinity
➢ PCC
➢ Flex-algo
➢ SRLG
➢ Performance Measurement
➢ IGP Metric
SR-PCE service helps configure path computation element related
configuration on nodes.
L2VPN allows you to configure point-to-point pseudowire (PW):
➢ Static PW or Ethernet VPN Virtual Private Wire Service (EVPN VPWS)
➢ Association of SR-TE Policy
The following diagram shows the workflow to instantiate the L2VPN EPVN
VPWS. It represents the logical flow of deployment, which can be deployed
either separately or in a single commit.
➢ Interface
➢ BGP Neighbor
➢ Association of SR-TE Policy
The following diagram shows the workflow to instantiate the L3VPN over
SR-TE. It represents the logical flow of deployment, which can be deployed
either separately or in a single commit.
4.2 SR-Policy
SR-TE uses a policy to steer traffic through the network. An SR-TE policy path
is expressed as a list of segments that specifies the path, called a segment ID
(SID) list.
An SR-TE policy uses one or more candidate paths. A candidate path is a single
segment list (SID-list) or a set of weighted SID-lists. If a packet is steered into
an SR-TE policy, the SID list is pushed on the packet by the head-end. The rest
of the network executes the instructions embedded in the SID list.
Each segment is an end-to-end path from the source to the destination, and
instructs the routers in the network to follow the specified path instead of the
shortest path calculated by the IGP.
An SR policy is uniquely identified by a tuple - head-end, color, and end-point.
The head-end is where the SR policy is instantiated or implemented. At a
given head-end, an SR policy is uniquely identified by a tuple (color, end-
point).
5.1 SR-Settings
Set the segment routing parameters to define the routing path/direction for
the segments.
In this service, you can use resource pools to logically allocate or share an
available set of resources. Resource pools provide the flexibility to manage
the existing resources and adjust the services to the needs of the customer.
For information on how to create SR-Settings and how to allocate resource
pools, see chapter Configuration in this documentation.
5.2 SR-PCE
SR-PCE describes a set of procedures by which a Path Computation Client
(PCC) can report and delegate control of a policy head-end.
For information on how to create SR-PCE, see chapter Configuration in this
documentation.
5.3 L2VPN
L2 Virtual Private Network (L2VPN) establishes an end-to-end layer 2
connection. L2VPN allows disparate systems to be connected in a way that it
appears as if they are connected by using a single physical connection, or are
using the same LAN.
L2VPNs employ L2 services over MPLS in order to build a topology of point-to-
point connections that connect end customer sites in a VPN.
5.4 L3VPN
L3VPN uses virtual routing and forwarding techniques to forward VPN traffic
over a network. For every endpoint, e-bgp can be configured to ODN.
The L3VPN service allows you to configure:
• VPN
• Interface
• BGP Neighbor
• Association of SR-TE Policy
6 Configuration
The topics in this chapter provide information on how to configure the
services by using the T-SDN FPs. T-SDN FPs comprise SR-TE CFP. The SR-TE CFP
consists of SR-TE ODN services and SR-TE Policy.
Segment Routing integrates with multi-service capabilities of MPLS, including
Layer 3 VPN (L3VPN), Virtual Private Wire Service (VPWS), Virtual Private LAN
Service (VPLS), and Ethernet VPN (EVPN).
SR-Settings, SR-Policy, L2VPN, and L3VPN are example function packs used to
demonstrate SR-TE CFP. You can choose to install the required packages for
these function packs during or after T-SDN FPs installation.
For more information on the list of packages extracted during T-SDN FP
installation, see Appendix A: Package Categories and Packages in this
documentation. For more information on how to install the packages, see the
Cisco NSO Transport SDN Function Pack Bundle Installation Guide.
<color>300</color>
<bandwidth>200</bandwidth>
<dynamic>
<metric-type>igp</metric-type>
<pce/>
<flex-alg>200</flex-alg>
<disjoint-path>
<type>node</type>
<group-id>10</group-id>
<sub-id>5</sub-id>
</disjoint-path>
<affinity>
<rule>
<action>exclude-any</action>
<color>BLUE</color>
</rule>
</affinity>
</dynamic>
</odn-template>
</odn>
</sr-te>
</config>
2. Display the plan to view the status of the service. The following table
discusses certain plan components unique to this service. For a detailed
description of plan components, see NSO documentation.
Plan
Value Description
Component
Represents the connected
cisco-sr-te-cfp-sr-odn-nano-
Type node(device) of the nano plan of a
plan-services:head-end
service.
Represents acceptance of service
cisco-sr-te-cfp-sr-odn-nano-
State intent and respective configuration
plan-services:config-apply
application on device
admin@ncs% run show sr-te cisco-sr-te-cfp-sr-odn:odn odn-template-plan
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
------------------------------------------------------------------------------------------
self self false - - init
reached 2020-04-22T21:26:01 - -
ready
reached 2020-04-22T21:27:44 - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end P-0 false - - init
reached 2020-04-22T21:26:01 - -
cisco-
sr-te-cfp-sr-odn-nano-plan-services:config-apply reached 2020-04-22T21:27:44 - -
ready
reached 2020-04-22T21:27:44 - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end PIOSXR-0 false - - init
reached 2020-04-22T21:26:01 - -
cisco-
sr-te-cfp-sr-odn-nano-plan-services:config-apply reached 2020-04-22T21:27:44 - -
ready
reached 2020-04-22T21:27:44 - -
2. Display the plan to view the status of the service. The following table
discusses certain plan components unique to this service. For a detailed
description of plan components, see NSO documentation.
Plan
Value Description
Component
Represents a connected node (device) of
Type head-end
the nano plan of a service.
cisco-sr-te-cfp-sr- Represents acceptance of service intent
State policies-nano-plan- and respective config application on device.
services:config-apply
• Affinity
• Interface affinity
• PCC
• Flex-algo
• SRLG
• Performance Measurement
• IGP Metric
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<bit-position>0</bit-position>
</color>
</affinity-map-te>
<pcc>
<pce>
<address>
<ipv4>
<address>1.1.1.1</address>
<precedence>128</precedence>
</ipv4>
<ipv4>
<address>2.2.2.2</address>
</ipv4>
</address>
</pce>
</pcc>
<node>
<name>PIOSXR-0</name>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>5</if-id>
<te>
<affinity>
<color>
<name>GREEN</name>
</color>
</affinity>
<metric>2</metric>
</te>
</interface>
<pcc>
<source-address>192.168.2.1</source-address>
</pcc>
</node>
<node>
<name>PIOSXR-1</name>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>7</if-id>
<te>
<affinity>
<color>
<name>BLUE</name>
</color>
</affinity>
<metric>2</metric>
</te>
</interface>
<pcc>
<disable/>
</pcc>
</node>
</sr-setting>
</config>
2. Display the plan to view the status of the service. The following table
discusses certain plan components unique to this service. For a detailed
description of plan components, see NSO documentation.
Plan
Value Description
Component
cisco-sr-te-settings- Represents a connected node (device) of
Type fp-nano-plan- the nano plan of a service.
services:node
cisco-sr-te-settings- Represents acceptance of service intent
State fp-nano-plan- and respective configuration application on
services:config-apply device.
admin@ncs% commit
Commit complete.
<node>
<name>P-1</name>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>3</if-id>
<te>
<affinity>
<color>
<name>GREEN</name>
</color>
<color>
<name>RED</name>
</color>
</affinity>
</te>
</interface>
<pcc>
<disable/>
</pcc>
</node>
<node>
<name>PIOSXR-0</name>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>5</if-id>
<te>
<affinity>
<color>
<name>GREEN</name>
</color>
</affinity>
<metric>2</metric>
</te>
</interface>
<pcc>
<source-address>192.168.2.1</source-address>
</pcc>
</node>
<node>
<name>PIOSXR-1</name>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>7</if-id>
<te>
<affinity>
<color>
<name>BLUE</name>
</color>
</affinity>
<metric>2</metric>
</te>
</interface>
<pcc>
<disable/>
</pcc>
</node>
<maximum-sid-depth>100</maximum-sid-depth>
<affinity-map-te>
<color>
<name>BLUE</name>
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<bit-position>0</bit-position>
</color>
</affinity-map-te>
<pcc>
<pce>
<address>
<ipv4>
<address>1.1.1.1</address>
<precedence>128</precedence>
</ipv4>
<ipv4>
<address>2.2.2.2</address>
</ipv4>
</address>
</pce>
</pcc>
</setting>
</settings>
</sr-te>
</config>
<flex-algo>
<name>129</name>
<algorithm-prefix-sid>
<index>4</index>
</algorithm-prefix-sid>
</flex-algo>
<loopback>
<id>1</id>
<flex-algo>
<name>128</name>
</flex-algo>
<flex-algo-enabled-flag>select</flex-algo-enabled-
flag>
</loopback>
<loopback>
<id>2</id>
<flex-algo>
<name>129</name>
</flex-algo>
<flex-algo-enabled-flag>select</flex-algo-enabled-
flag>
</loopback>
</node>
<address-family>both</address-family>
<igp-metric>
<metric>1004</metric>
<metric-level>
<metric>
<level>1</level>
<value>1005</value>
</metric>
</metric-level>
</igp-metric>
<mpls-preference>sr-prefer</mpls-preference>
</isis>
<isis>
<instance-name>CORE-2</instance-name>
<node>
<name>PIOSXR-0</name>
<flex-algo>
<name>128</name>
<algorithm-prefix-sid>
<absolute>18006</absolute>
</algorithm-prefix-sid>
</flex-algo>
<flex-algo>
<name>129</name>
<algorithm-prefix-sid>
<auto-assign-index/>
</algorithm-prefix-sid>
</flex-algo>
<loopback>
<id>3</id>
</loopback>
</node>
<node>
<name>P-0</name>
<flex-algo>
<name>128</name>
<algorithm-prefix-sid>
<absolute>18009</absolute>
</algorithm-prefix-sid>
</flex-algo>
<flex-algo>
<name>129</name>
<algorithm-prefix-sid>
<index>7</index>
</algorithm-prefix-sid>
</flex-algo>
<loopback>
<id>3</id>
</loopback>
</node>
<address-family>both</address-family>
<mpls-preference>sr-prefer</mpls-preference>
</isis>
</slice>
<node>
<name>PIOSXR-0</name>
<isis>
<instance-name>CORE</instance-name>
<loopback>
<id>1</id>
<prefix-sid>
<auto-assign-index/>
<n-flag-clear/>
</prefix-sid>
</loopback>
<loopback>
<id>2</id>
<prefix-sid>
<index>10</index>
</prefix-sid>
</loopback>
<address-family>both</address-family>
</isis>
<isis>
<instance-name>CORE-2</instance-name>
<loopback>
<id>3</id>
<prefix-sid>
<index>8</index>
</prefix-sid>
</loopback>
<address-family>both</address-family>
<mpls-preference>sr-prefer</mpls-preference>
</isis>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>5</if-id>
<isis>
<instance-name>CORE-2</instance-name>
<interface-igp-metric>
<metric>1009</metric>
</interface-igp-metric>
</isis>
</interface>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>7</if-id>
<isis>
<instance-name>CORE</instance-name>
<affinity>
<color>
<name>BLUE</name>
</color>
<color>
<name>RED</name>
</color>
</affinity>
<interface-igp-metric>
<metric-level>
<metric>
<level>2</level>
<value>1006</value>
</metric>
</metric-level>
</interface-igp-metric>
</isis>
</interface>
</node>
<node>
<name>P-0</name>
<isis>
<instance-name>CORE-2</instance-name>
<loopback>
<id>3</id>
<prefix-sid>
<auto-assign-absolute/>
</prefix-sid>
</loopback>
<address-family>both</address-family>
<mpls-preference>sr-prefer</mpls-preference>
</isis>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>5</if-id>
<isis>
<instance-name>CORE-2</instance-name>
<interface-igp-metric>
<metric>1009</metric>
</interface-igp-metric>
</isis>
</interface>
</node>
<affinity-map-isis>
<color>
<name>BLUE</name>
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<bit-position>0</bit-position>
</color>
</affinity-map-isis>
</setting>
</settings>
</sr-te>
</config>
admin@ncs% commit
Commit complete.
If you add resources to a resource pool beyond a specified range, the plan
fails with an error message.
plan failed
plan error-info message "com.tailf.pkg.idpool.exceptions.PoolExhaustedException: ID pool
SRGB_POOL exhausted"
<type>srlg</type>
<strict/>
<lsp>
<id>1</id>
<pcc-address>2.2.2.2</pcc-address>
<lsp-name>LSP-NAME</lsp-name>
<shortest-path/>
</lsp>
</group-id>
</disjoint-path>
<timers>
<reoptimization>600</reoptimization>
<keepalive>20</keepalive>
<minimum-peer-keepalive>21</minimum-peer-keepalive>
</timers>
<state-sync>
<ipv4>
<address>3.3.3.3</address>
</ipv4>
</state-sync>
<password>
<type>clear</type>
<secret>password123</secret>
</password>
<backoff>
<ratio>11</ratio>
<difference>10</difference>
<threshold>12</threshold>
</backoff>
<segment-routing>
<strict-sid-only/>
<te-latency/>
</segment-routing>
</pce>
</node>
</sr-pce>
</config>
2. Display the plan to view the status of the service. The following table
discusses certain plan components unique to this service. For a detailed
description of plan components, see NSO documentation.
Plan
Value Description
Component
cisco-sr-te-sr-pce- Represents a connected node (device) of
Type nano-plan- the nano plan of a service.
services:node
cisco-sr-te-sr-pce- Represents acceptance of service intent
State nano-plan- and respective configuration application on
services:config-apply device.
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
------------------------------------------------------------------------------------
self self false - - init
reached 2020-04-22T16:57:54 - -
ready
reached 2020-04-22T16:57:57 - -
cisco-sr-te-pce-fp-nano-plan-services:node PIOSXR-0 false - - init
reached 2020-04-22T16:57:54 - -
cisco-sr-te-
pce-fp-nano-plan-services:config-apply reached 2020-04-22T16:57:57 - -
ready
reached 2020-04-22T16:57:57 - -
6.4 Creating Flat L2VPN Services with the L2VPN Example Function
Pack
You can implement a custom L2VPN function pack to meet specific
requirements. Use the example function pack as a starting point or for design
patterns.
There are two types of example L2VPN services: L2VPN P2P and L2VPN EVPN
VPWS. Each service requires a mandatory Local Site and an optional Remote
Site to create the service.
For the Flat L2VPN yang model, see Appendix B - Yang Models in this
documentation.
<xconnect-encapsulation>mpls</xconnect-encapsulation>
<p2p-name>P2P-DOT1Q</p2p-name>
<control-word>no</control-word>
<pw-class>P2P-DOT1Q</pw-class>
<xconnect-local-ip>12.0.0.0</xconnect-local-ip>
<xconnect-remote-ip>14.0.0.0</xconnect-remote-ip>
<mpls-local-label>101</mpls-local-label>
<mpls-remote-label>202</mpls-remote-label>
</local-site>
<remote-site>
<pe>PIOSXR-1</pe>
<if-type>HundredGigE</if-type>
<if-id>0/0/0/8</if-id>
<if-encap>dot1q</if-encap>
<vlan-id>100</vlan-id>
<sub-if-id>100</sub-if-id>
<rewrite>
<ingress>
<translate>1-to-1</translate>
<dot1q>123</dot1q>
<mode>symmetric</mode>
</ingress>
</rewrite>
<xconnect-group-name>P2P-DOT1Q</xconnect-group-name>
<p2p-name>P2P-DOT1Q</p2p-name>
<pw-class>P2P-DOT1Q</pw-class>
</remote-site>
</flat-L2vpn-p2p>
</flat-L2vpn>
</config>
2. Display the plan to view the status of the service. For detailed service-
state-changes notifications, see chapter Notifications in this
documentation.
The following table discusses certain plan components unique to this
service. For a detailed description of plan components, see
NSO documentation.
Plan
Value Description
Component
This represents the Local-site (mandatory
local-site
site) of the L2VPN service.
Type
This represents the remote-site (optional
remote-site
site) of the L2VPN service.
cisco-flat-L2vpn- This represents the device configuration
fp-nano-plan- state in the nano-plan of a service.
State
services:config-
apply
<pe>PIOSXR-1</pe>
<if-type>TenGigE</if-type>
<if-id>0/0/0/35</if-id>
<if-description>L2VPN-Dynamic-02</if-description>
<if-encap>untagged</if-encap>
<sub-if-id>40</sub-if-id>
<xconnect-group-name>evpn_vpws_nso</xconnect-group-name>
<p2p-name>EVPN-PIOSXR-1</p2p-name>
</remote-site>
</flat-L2vpn-evpn-vpws>
</flat-L2vpn>
</config>
2. Display the plan to view the status of the service. For detailed
service-state-changes notifications, see chapter Notifications in this
documentation.
The following table discusses certain plan components unique to
this service. For a detailed description of plan components, see
NSO documentation.
Plan
Value Description
Component
This represents the Local-site
local-site (mandatory site) of the L2VPN
Type service.
This represents the remote-site
remote-site
(optional site) of the L2VPN service.
cisco-flat-L2vpn-fp-nano- This represents the device
State plan-services:config- configuration state in the nano-plan
apply of a service.
3. Verify the configuration on the device by running the sh run l2vpn command.
6.5 Creating Flat L3VPN Services with the L3VPN Example Function
Pack
You can implement a custom L3VPN function pack to meet specific
requirements. Use the example function pack as a starting point or for design
patterns.
The example Flat L3VPN service allows you to configure:
• VPN
• Interface
• BGP Neighbor
• Association of SR-TE Policy
The following table describes the L3VPN plan components.
Plan
Value Description
Component
This component represents one
Type endpoint of the endpoints of L3VPN
service.
This represents the device
cisco-flat-L3vpn-fp-nano-plan-
State configuration state in the nano-
services:config-apply
plan of a service.
<address-family>ipv4</address-family>
<vpn-target>
<rt-value>100:101</rt-value>
<rt-type>export</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:102</rt-value>
<rt-type>import</rt-type>
</vpn-target>
<vpn-target>
<rt-value>200:100</rt-value>
<rt-type>both</rt-type>
</vpn-target>
</address-family>
</vrf>
<sr-te>
<route-policy>L3-RP-EP1</route-policy>
</sr-te>
<l2-attachment-circuit>
<name>AC1</name>
<if-type>GigabitEthernet</if-type>
<if-id>0/0/0/6</if-id>
<vlan-id>100</vlan-id>
<rewrite>
<ingress>
<push/>
<dot1q>123</dot1q>
</ingress>
</rewrite>
</l2-attachment-circuit>
<l2-attachment-circuit>
<name>AC2</name>
<if-type>GigabitEthernet</if-type>
<if-id>0/0/0/5</if-id>
<vlan-id>200</vlan-id>
<rewrite>
<ingress>
<pop>1</pop>
<mode>symmetric</mode>
</ingress>
</rewrite>
</l2-attachment-circuit>
</endpoint>
</flat-L3vpn>
<l3vpn-route-policy
xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-flat-L3vpn">
<name>L3-RP-EP1</name>
<color>
<id>100</id>
<ipv4>
<prefix>1.1.1.1/32</prefix>
<prefix>1.1.1.2/32</prefix>
</ipv4>
</color>
<color>
<id>101</id>
<ipv4>
<prefix>2.1.1.1/32</prefix>
<prefix>2.1.1.2/32</prefix>
</ipv4>
</color>
</l3vpn-route-policy>
<l3vpn-route-policy
xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-flat-L3vpn">
<name>L3-RP-EP2</name>
<color>
<id>100</id>
<ipv4>
<prefix>3.1.1.1/32</prefix>
<prefix>3.1.1.2/32</prefix>
</ipv4>
</color>
<color>
<id>101</id>
<ipv4>
<prefix>4.1.1.1/32</prefix>
<prefix>4.1.1.2/32</prefix>
</ipv4>
</color>
</l3vpn-route-policy>
</config>
2. Display the plan to view the status of the service. For detailed service-state-
changes notifications, see chapter Notifications in this documentation.
<prefix>1.1.1.1/32</prefix>
<prefix>1.1.1.2/32</prefix>
</ipv4>
</color>
<color>
<id>101</id>
<ipv4>
<prefix>2.1.1.1/32</prefix>
<prefix>2.1.1.2/32</prefix>
</ipv4>
</color>
</l3vpn-route-policy>
<l3vpn-route-policy
xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-flat-L3vpn">
<name>L3-RP-EP2</name>
<color>
<id>100</id>
<ipv4>
<prefix>3.1.1.1/32</prefix>
<prefix>3.1.1.2/32</prefix>
</ipv4>
</color>
<color>
<id>101</id>
<ipv4>
<prefix>4.1.1.1/32</prefix>
<prefix>4.1.1.2/32</prefix>
</ipv4>
</color>
</l3vpn-route-policy>
</config>
2. The following is a sample payload to create the SR-ODN service for L3VPN.
<config xmlns="http://tail-f.com/ns/config/1.0">
<flat-L3vpn xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-
flat-L3vpn">
<name>L3</name>
<endpoint>
<endpoint-name>nc-0</endpoint-name>
<access-pe>P-0</access-pe>
<if-type>Loopback</if-type>
<if-id>3</if-id>
<pe-ip-addr>169.1.1.1/32</pe-ip-addr>
<as-no>65001</as-no>
<ce-pe-prot>
<e-bgp>
<neighbor-ipv4>169.1.1.2</neighbor-ipv4>
<remote-as-ipv4>65002</remote-as-ipv4>
</e-bgp>
</ce-pe-prot>
<vrf>
<vrf-definition>L3VPN</vrf-definition>
<route-distinguisher>1:2</route-distinguisher>
<vpn-id>11:13</vpn-id>
<address-family>
<address-family>ipv4</address-family>
<vpn-target>
<rt-value>100:101</rt-value>
<rt-type>export</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:102</rt-value>
<rt-type>import</rt-type>
</vpn-target>
<vpn-target>
<rt-value>200:100</rt-value>
<rt-type>both</rt-type>
</vpn-target>
</address-family>
</vrf>
<sr-te>
<route-policy>L3-RP-EP2</route-policy>
</sr-te>
</endpoint>
<endpoint>
<endpoint-name>nc-1</endpoint-name>
<access-pe>P-1</access-pe>
<if-type>Loopback</if-type>
<if-id>3</if-id>
<pe-ip-addr>169.1.1.1/32</pe-ip-addr>
<as-no>65001</as-no>
<ce-pe-prot>
<e-bgp>
<neighbor-ipv4>169.1.1.2</neighbor-ipv4>
<remote-as-ipv4>65002</remote-as-ipv4>
</e-bgp>
</ce-pe-prot>
<vrf>
<vrf-definition>L3VPN</vrf-definition>
<route-distinguisher>1:2</route-distinguisher>
<address-family>
<address-family>ipv4</address-family>
<vpn-target>
<rt-value>100:101</rt-value>
<rt-type>export</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:102</rt-value>
<rt-type>import</rt-type>
</vpn-target>
<vpn-target>
<rt-value>200:100</rt-value>
<rt-type>both</rt-type>
</vpn-target>
</address-family>
</vrf>
</endpoint>
</flat-L3vpn>
</config>
1. The following is a sample payload to create the BVI interface for L3VPN.
<config xmlns="http://tail-f.com/ns/config/1.0">
<flat-L3vpn xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-
flat-L3vpn">
<name>L3-CLI</name>
<endpoint>
<endpoint-name>nc-0</endpoint-name>
<access-pe>PIOSXR-0</access-pe>
<if-type>BVI</if-type>
<if-id>168</if-id>
<pe-ip-addr>169.1.1.1/28</pe-ip-addr>
<as-no>65001</as-no>
<ce-pe-prot>
<e-bgp>
<neighbor-ipv4>169.1.1.2</neighbor-ipv4>
<remote-as-ipv4>65002</remote-as-ipv4>
</e-bgp>
</ce-pe-prot>
<vrf>
<vrf-definition>L3VPN-0</vrf-definition>
<route-distinguisher>1:2</route-distinguisher>
<address-family>
<address-family>ipv4</address-family>
<vpn-target>
<rt-value>200:100</rt-value>
<rt-type>both</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:101</rt-value>
<rt-type>export</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:102</rt-value>
<rt-type>import</rt-type>
</vpn-target>
</address-family>
</vrf>
<l2-attachment-circuit>
<name>AC1</name>
<if-type>GigabitEthernet</if-type>
<if-id>0/0/0/6</if-id>
<vlan-id>100</vlan-id>
<rewrite>
<ingress>
<push/>
<dot1q>123</dot1q>
</ingress>
</rewrite>
</l2-attachment-circuit>
<l2-attachment-circuit>
<name>AC2</name>
<if-type>GigabitEthernet</if-type>
<if-id>0/0/0/5</if-id>
<vlan-id>200</vlan-id>
<rewrite>
<ingress>
<pop>1</pop>
<mode>symmetric</mode>
</ingress>
</rewrite>
</l2-attachment-circuit>
</endpoint>
</flat-L3vpn>
</config>
Arguments Description
service-type This is the type of the service, such as SR-TE ODN.
service This is the name of the service to clean.
device This is the name of the device to clean under a given service. This
parameter is optional. If you do not provide the device name, it cleans
up the entire service.
service-name This is the name of the service to clean.
local-site-only This can point to an unreachable local-site that is replaced by another
reachable local site device in the service.
remote-site-only This can point to an unreachable remote-site that is removed from the
service.
endpoint This is the endpoint name in the service. If you do not provide any
other parameter, it cleans up the entire service.
No-networking This flag indicates if NSO must delete the service components from
network devices. By default, it is set to true.
When true, NSO cleanup does not remove configuration from network
devices. When false, NSO cleansup the device configuration
7.1.1 SR-ODN
Perform the Cleanup action to clean up either a specific device in the service
or the entire service. Cleaning up the entire service cleans up all the devices in
the service.
7.1.2 SR-Policy
A policy service can have only one head-end. Therefore, you can clean up only
the service, even if you provide a device name.
The following action command shows how to clean up the service.
admin@ncs% request sr-te cleanup service-type sr-policy service SR-
CLI-DYNAMIC no-networking true
success true
detail Cleaning up SR TE service: SR-CLI-DYNAMIC
Removed all plan components
Removed service oper
Removing service /cisco-sr-te-cfp:sr-te/cisco-sr-te-cfp-sr-
policies:policies/cisco-sr-te-cfp-sr-policies:policy{SR-CLI-DYNAMIC}
Removed service /cisco-sr-te-cfp:sr-te/cisco-sr-te-cfp-sr-
policies:policies/cisco-sr-te-cfp-sr-policies:policy{SR-CLI-DYNAMIC}
Removed side-effects
Removed side-effects
Removed kickers
Removed kickers
Cleanup Successful
7.1.3 SR-Settings
Perform the Cleanup action either on a specific device or on the entire
service. Cleaning up the entire service cleans up all the devices in the service.
To clean up SR-Settings service per device
admin@ncs% request sr-setting-action cleanup service SETTING-1 device
PIOSXR-1 no-networking true
success true
detail Cleaning up SR TE service: SETTING-1
Removed all plan components
Removing service oper: /cisco-sr-te-settings-fp-internal:sr-setting-
internal/sr-setting-oper-data{SETTING-1 PIOSXR-1}
Removed service oper
Removed side-effects
Removed side-effects
Removed kickers
Removing kicker: /kickers/data-kicker{"pre-condition: /cisco-sr-te-
settings-fp-internal:sr-setting-internal/sr-setting-plan{SETTING-1
PIOSXR-1}/plan/component{ncs:self self}/state{cisco-sr-te-settings-fp-
nano-services:config-apply}"}
Removed kickers
Cleanup Successful
Removed side-effects
Removed kickers
Removing kicker: /kickers/data-kicker{"pre-condition: /cisco-sr-te-
settings-fp-internal:sr-setting-internal/sr-setting-plan{SETTING-1
PIOSXR-1}/plan/component{ncs:self self}/state{cisco-sr-te-settings-fp-
nano-services:config-apply}"}
Removed kickers
Cleanup Successful
7.1.4 SR-PCE
Perform the Cleanup action either on a specific device or on the entire
service. Cleaning up the entire service cleans up all the devices in the service.
To clean up SR-PCE service per device
admin@ncs% request sr-te cleanup service-type sr-pce service PCE-0
device PIOSXR-0 no-networking true
admin@ncs% request sr-pce-action cleanup service PCE-0 no-networking
true
success true
detail Cleaning up SR TE service: PCE-0
Removed all plan components
Removing service /cisco-sr-te-pce-fp:sr-pce{PCE-0}
Removed service /cisco-sr-te-pce-fp:sr-pce{PCE-0}
Removing service /cisco-sr-te-pce-fp-internal:sr-pce{PCE-0 PIOSXR-0}
Removed service /cisco-sr-te-pce-fp-internal:sr-pce{PCE-0 PIOSXR-0}
Removing service oper: /cisco-sr-te-pce-fp-internal:sr-pce-
internal/sr-pce-oper-data{PCE-0 PIOSXR-0}
Removed service oper
Removed side-effects
Removed side-effects
Removed kickers
Removed kickers
Cleanup Successful
After the clean up is complete, depending on whether the NSO or the device
holds the correct configuration, perform a sync-to or sync-from to synchronize
NSO and the device, when the device is active.
This topic contains information for the following services in the order listed.
➢ SR-TE CFP
➢ Example Function Packs
SR-TE CFP
SR-PCE
admin@ncs% set cisco-sr-te-pce-fp:cfp-configurations auto-cleanup true
admin@ncs% commit
Commit complete.
L2VPN
admin@ncs% set cisco-flat-L2vpn-fp:cfp-configurations auto-cleanup
true
admin@ncs% commit
Commit complete.
L3VPN
admin@ncs% set cisco-flat-L3vpn-fp:cfp-configurations auto-cleanup
true
admin@ncs% commit
Commit complete.
7.3.1 SR-ODN
Perform the get-modifications action either at the service level or at the
device level.
get-modifications action for the service
admin@ncs% request sr-te cisco-sr-te-cfp-sr-odn:odn odn-template SR-
ODN action get-modifications outformat cli
message devices {
device P-0 {
config {
segment-routing-ms-cfg:sr {
traffic-engineering {
on-demand-colors {
+ on-demand-color 300 {
+ on-demand-color-dyn-mpls {
+ on-demand-color-dyn-mpls-metric {
+ metric-type igp;
+ enable;
+ }
+ on-demand-color-dyn-mpls-pce {
+ enable;
+ }
+ disjoint-path {
+ group-id 10;
+ disjointness-type node;
+ sub-id 5;
+ }
+ on-demand-color-dyn-mpls-flex-
algorithm 200;
+ enable;
+ affinity-rules {
+ affinity-rule affinity-exclude-
any {
+ affinity-name BLUE;
+ }
+ }
+ }
+ bandwidth 200;
+ maximum-sid-depth 6;
+ enable;
+ }
}
}
}
}
}
}
7.3.2 SR-Policy
get-modifications action for service
admin@ncs% request sr-te cisco-sr-te-cfp-sr-policies:policies policy
SR-CLI-DYNAMIC action get-modifications outformat cli
devices {
device PIOSXR-0 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
+ segment-list mysidlist {
+ index 1 {
+ mpls {
+ label 17001;
+ }
+ }
+ index 2 {
+ mpls {
+ label 18001;
+ }
+ }
+ }
policy SR-CLI-DYNAMIC {
color {
end-point {
- ipv4 127.0.0.1;
+ ipv4 1.1.1.1;
}
}
candidate-paths {
+ preference 200 {
+ explicit {
+ segment-list mysidlist {
+ weight 10;
+ }
+ }
+ }
}
}
}
}
}
}
}
7.3.3 SR-Settings
Perform the get-modifications action either at the service level or at the
device level.
get-modifications action for a service
admin@ncs% request sr-setting SETTING-1 action get-modifications
outformat cli
message devices {
device PIOSXR-0 {
config {
+ cisco-ios-xr:segment-routing {
+ traffic-eng {
+ interface GigabitEthernet5 {
+ affinity {
+ color GREEN;
+ }
+ metric 2;
+ }
+ maximum-sid-depth 100;
+ affinity-map {
+ color BLUE {
+ prefix name;
+ bit-position 1;
+ }
+ color GREEN {
+ prefix name;
+ bit-position 2;
+ }
+ color RED {
+ prefix name;
+ bit-position 0;
+ }
+ }
+ pcc {
+ source-address {
+ ipv4 192.168.2.1;
+ }
+ pce {
+ address {
+ ipv4 1.1.1.1 {
+ precedence 128;
+ }
+ ipv4 2.2.2.2 {
+ precedence 255;
+ }
+ }
+ }
+ }
+ }
+ }
}
}
}
devices {
device PIOSXR-1 {
config {
+ cisco-ios-xr:segment-routing {
+ traffic-eng {
+ interface GigabitEthernet7 {
+ affinity {
+ color BLUE;
+ }
+ metric 2;
+ }
+ maximum-sid-depth 100;
+ affinity-map {
+ color BLUE {
+ prefix name;
+ bit-position 1;
+ }
+ color GREEN {
+ prefix name;
+ bit-position 2;
+ }
+ color RED {
+ prefix name;
+ bit-position 0;
+ }
+ }
+ }
+ }
}
}
}
7.3.4 SR-PCE
Perform the get-modifications action either at the service level or at the
device level.
get-modifications action for a service
admin@ncs% request sr-pce PCE-0 action get-modifications outformat cli
message devices {
device PIOSXR-0 {
config {
+ cisco-ios-xr:pce {
+ address {
+ ipv4 100.1.1.1;
+ }
+ disjoint-path {
+ group-id 60000 srlg {
+ sub-id 1;
+ strict;
+ lsp 1 {
+ pcc {
+ ipv4 2.2.2.2;
+ }
+ lsp-name LSP-NAME;
+ shortest-path;
+ }
+ }
+ }
+ timers {
+ reoptimization 600;
+ keepalive 20;
+ minimum-peer-keepalive 21;
+ }
+ state-sync {
+ ipv4 3.3.3.3;
+ }
+ password {
+ type clear;
+ secret password123;
+ }
+ backoff {
+ ratio 11;
+ difference 10;
+ threshold 12;
+ }
+ segment-routing {
+ strict-sid-only;
+ te-latency;
+ }
+ }
}
}
}
+ }
+ }
}
}
}
devices {
device PIOSXR-1 {
config {
cisco-ios-xr:interface {
+ HundredGigE 0/0/0/8 {
+ description "T-SDN Interface";
+ }
HundredGigE-subinterface {
+ HundredGigE 0/0/0/8.100 {
+ mode l2transport;
+ description "T-SDN Interface";
+ encapsulation {
+ dot1q {
+ vlan-id 100;
+ }
+ }
+ rewrite {
+ ingress {
+ tag {
+ translate 1-to-1;
+ dot1q 123;
+ mode symmetric;
+ }
+ }
+ }
+ }
}
}
+ cisco-ios-xr:l2vpn {
+ pw-class P2P-DOT1Q {
+ encapsulation {
+ mpls {
+ }
+ }
+ }
+ xconnect {
+ group P2P-DOT1Q {
+ p2p P2P-DOT1Q {
+ interface HundredGigE0/0/0/8.100;
+ neighbor 12.0.0.0 100 {
+ ip-version ipv4;
+ mpls {
+ static {
+ label {
+ local 202;
+ remote 101;
+ }
+ }
+ }
+ pw-class P2P-DOT1Q;
+ }
+ }
+ }
+ }
+ }
}
}
}
+ instance-as 0 {
+ four-byte-as 65001 {
+ vrfs {
+ vrf L3VPN {
+ vrf-global {
+ route-distinguisher {
+ type as;
+ as-xx 0;
+ as 1;
+ as-index 2;
+ }
+ vrf-global-afs {
+ vrf-global-af ipv4-
unicast {
+ enable;
+ }
+ }
+ exists;
+ }
+ vrf-neighbors {
+ vrf-neighbor 169.1.1.2 {
+ vrf-neighbor-afs {
+ vrf-neighbor-af ipv4-
unicast {
+ activate;
+ route-policy-in
PASS_ALL;
+ route-policy-out
PASS_ALL;
+ }
+ }
+ remote-as {
+ as-xx 0;
+ as-yy 65002;
+ }
+ }
+ }
+ }
+ }
+ bgp-running;
+ }
+ }
+ }
}
policy-repository-cfg:routing-policy {
route-policies {
+ route-policy PASS_ALL {
+ rpl-route-policy "route-policy PASS_ALL\n
pass\n end-policy\n ";
+ }
}
}
}
}
}
devices {
device P-1 {
config {
ifmgr-cfg:interface-configurations {
+ interface-configuration act Loopback3 {
+ interface-virtual;
+ vrf L3VPN;
+ ipv4-network {
+ addresses {
+ primary {
+ address 169.1.1.1;
+ netmask 255.255.255.255;
+ }
+ }
+ }
+ }
}
infra-rsi-cfg:vrfs {
+ vrf L3VPN {
+ create;
+ afs {
+ af ipv4 unicast default {
+ create;
+ bgp {
+ import-route-targets {
+ route-targets {
+ route-target as {
+ as-or-four-byte-as 0 100
102 0;
+ as-or-four-byte-as 0 200
100 0;
+ }
+ }
+ }
+ export-route-targets {
+ route-targets {
+ route-target as {
+ as-or-four-byte-as 0 100
101 0;
+ as-or-four-byte-as 0 200
100 0;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
}
ipv4-bgp-cfg:bgp {
+ instance default {
+ instance-as 0 {
+ four-byte-as 65001 {
+ vrfs {
+ vrf L3VPN {
+ vrf-global {
+ route-distinguisher {
+ type as;
+ as-xx 0;
+ as 1;
+ as-index 2;
+ }
+ vrf-global-afs {
+ vrf-global-af ipv4-
unicast {
+ enable;
+ }
+ }
+ exists;
+ }
+ vrf-neighbors {
+ vrf-neighbor 169.1.1.2 {
+ vrf-neighbor-afs {
+ vrf-neighbor-af ipv4-
unicast {
+ activate;
+ route-policy-in
PASS_ALL;
+ route-policy-out
PASS_ALL;
+ }
+ }
+ remote-as {
+ as-xx 0;
+ as-yy 65002;
+ }
+ }
+ }
+ }
+ }
+ bgp-running;
+ }
+ }
+ }
}
policy-repository-cfg:routing-policy {
route-policies {
+ route-policy PASS_ALL {
+ rpl-route-policy "route-policy PASS_ALL\n
pass\n end-policy\n ";
+ }
}
}
}
}
}
}
infra-rsi-cfg:vrfs {
+ vrf L3VPN {
+ create;
+ afs {
+ af ipv4 unicast default {
+ create;
+ bgp {
+ import-route-targets {
+ route-targets {
+ route-target as {
+ as-or-four-byte-as 0 100
102 0;
+ as-or-four-byte-as 0 200
100 0;
+ }
+ }
+ }
+ export-route-targets {
+ route-targets {
+ route-target as {
+ as-or-four-byte-as 0 100
101 0;
+ as-or-four-byte-as 0 200
100 0;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
}
ipv4-bgp-cfg:bgp {
+ instance default {
+ instance-as 0 {
+ four-byte-as 65001 {
+ vrfs {
+ vrf L3VPN {
+ vrf-global {
+ route-distinguisher {
+ type as;
+ as-xx 0;
+ as 1;
+ as-index 2;
+ }
+ vrf-global-afs {
+ vrf-global-af ipv4-
unicast {
+ enable;
+ }
+ }
+ exists;
+ }
+ vrf-neighbors {
+ vrf-neighbor 169.1.1.2 {
+ vrf-neighbor-afs {
+ vrf-neighbor-af ipv4-
unicast {
+ activate;
+ route-policy-in
PASS_ALL;
+ route-policy-out
PASS_ALL;
+ }
+ }
+ remote-as {
+ as-xx 0;
+ as-yy 65002;
+ }
+ }
+ }
+ }
+ }
+ bgp-running;
+ }
+ }
+ }
}
policy-repository-cfg:routing-policy {
route-policies {
+ route-policy PASS_ALL {
+ rpl-route-policy "route-policy PASS_ALL\n
pass\n end-policy\n ";
+ }
}
}
}
}
}
+ route-targets {
+ route-target as {
+ as-or-four-byte-as 0 100
102 0;
+ as-or-four-byte-as 0 200
100 0;
+ }
+ }
+ }
+ export-route-targets {
+ route-targets {
+ route-target as {
+ as-or-four-byte-as 0 100
101 0;
+ as-or-four-byte-as 0 200
100 0;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
}
ipv4-bgp-cfg:bgp {
+ instance default {
+ instance-as 0 {
+ four-byte-as 65001 {
+ vrfs {
+ vrf L3VPN {
+ vrf-global {
+ route-distinguisher {
+ type as;
+ as-xx 0;
+ as 1;
+ as-index 2;
+ }
+ vrf-global-afs {
+ vrf-global-af ipv4-
unicast {
+ enable;
+ }
+ }
+ exists;
+ }
+ vrf-neighbors {
+ vrf-neighbor 169.1.1.2 {
+ vrf-neighbor-afs {
+ vrf-neighbor-af ipv4-
unicast {
+ activate;
+ route-policy-in
PASS_ALL;
+ route-policy-out
PASS_ALL;
+ }
+ }
+ remote-as {
+ as-xx 0;
+ as-yy 65002;
+ }
+ }
+ }
+ }
+ }
+ bgp-running;
+ }
+ }
+ }
}
policy-repository-cfg:routing-policy {
route-policies {
+ route-policy PASS_ALL {
+ rpl-route-policy "route-policy PASS_ALL\n
pass\n end-policy\n ";
+ }
}
}
}
}
}
7.4.1 SR-ODN
Redeploying a service redeploys all the devices in the service. Redeploying a
device redeploys the service only on the requested device. When the device is
not-reachable and the plan fails, run the redeploy action for a specific device
to push the configuration again when the device is up.
View the plan and observe the timestamp to verify the service redeployment.
admin@ncs% run show sr-te cisco-sr-te-cfp-sr-odn:odn odn-template-plan
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
------------------------------------------------------------------------------------------
self self false - - init
reached 2020-04-22T21:26:01 - -
ready
reached 2020-04-22T21:33:38 - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end P-0 false - - init
reached 2020-04-22T21:26:01 - -
cisco-
sr-te-cfp-sr-odn-nano-plan-services:config-apply reached 2020-04-22T21:33:38 - -
ready
reached 2020-04-22T21:33:38 - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end PIOSXR-0 false - - init
reached 2020-04-22T21:26:01 - -
cisco-
sr-te-cfp-sr-odn-nano-plan-services:config-apply reached 2020-04-22T21:33:38 - -
ready
reached 2020-04-22T21:33:38 - -
View the plan and observe the timestamp to verify the device redeployment.
admin@ncs% run show sr-te cisco-sr-te-cfp-sr-odn:odn odn-template-plan
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
------------------------------------------------------------------------------------------
self self false - - init
reached 2020-04-22T21:26:01 - -
ready
reached 2020-04-22T21:34:46 - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end P-0 false - - init
reached 2020-04-22T21:26:01 - -
cisco-
sr-te-cfp-sr-odn-nano-plan-services:config-apply reached 2020-04-22T21:34:46 - -
ready
reached 2020-04-22T21:34:46 - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end PIOSXR-0 false - - init
reached 2020-04-22T21:26:01 - -
cisco-
sr-te-cfp-sr-odn-nano-plan-services:config-apply reached 2020-04-22T21:33:38 - -
ready
reached 2020-04-22T21:33:38 - -
7.4.2 SR-Policy
Redeploying at service level
The following command shows how to redeploy a service.
admin@ncs% request sr-te cisco-sr-te-cfp-sr-policies:policies policy
SR-CLI-DYNAMIC action redeploy
status SUCCESS
message Service Redeployed.
View the plan and observe the timestamp to verify the service redeployment.
admin@ncs% run show sr-te cisco-sr-te-cfp-sr-policies:policies policy-
plan
POST
BACK
ACTION
TYPE NAME TRACK GOAL STATE
STATUS WHEN ref STATUS
----------------------------------------------------------------------
self self false - init
reached 2020-02-11T22:30:16 - -
ready
reached 2020-02-11T22:31:52 - -
head-end PIOSXR-0 false - init
reached 2020-02-11T22:30:16 - -
cisco-sr-te-cfp-sr-policies-nano-plan-services:config-
apply reached 2020-02-11T22:31:22 - -
ready
reached 2020-02-11T22:31:52 - -
7.4.3 SR-Settings
Redeploying at service level
The following command shows how to redeploy a service.
admin@ncs% request sr-setting SETTING-1 action redeploy
status SUCCESS
message Service Redeployed.
View the plan and observe the timestamp to verify the service redeployment.
admin@ncs% run show sr-setting-plan
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
----------------------------------------------------------------------
self self false - - init
reached 2020-04-22T22:41:07 - -
ready
reached 2020-04-22T22:47:10 - -
cisco-sr-te-settings-fp-nano-plan-services:node PIOSXR-0 false - - init
reached 2020-04-22T22:41:07 - -
cisco-sr-
te-settings-fp-nano-plan-services:config-apply reached 2020-04-22T22:47:10 - -
ready
reached 2020-04-22T22:47:10 - -
cisco-sr-te-settings-fp-nano-plan-services:node PIOSXR-1 false - - init
reached 2020-04-22T22:41:07 - -
cisco-sr-
te-settings-fp-nano-plan-services:config-apply reached 2020-04-22T22:47:10 - -
ready
reached 2020-04-22T22:47:10 - -
View the plan and observe the timestamp to verify the device redeployment.
7.4.4 SR-PCE
Redeploying at service level
The following command shows how to redeploy a service.
admin@ncs% request sr-pce PCE-0 action redeploy
status SUCCESS
message Service Redeployed.
View the plan and observe the timestamp to verify the service redeployment.
admin@ncs% run show sr-pce-plan PCE-0 plan component
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
----------------------------------------------------------------------
self self false - - init
reached 2020-04-22T17:50:05 - -
ready
reached 2020-04-22T17:59:46 - -
cisco-sr-te-pce-fp-nano-plan-services:node PIOSXR-0 false - - init
reached 2020-04-22T17:50:05 - -
cisco-sr-te-
pce-fp-nano-plan-services:config-apply reached 2020-04-22T17:59:46 - -
ready
reached 2020-04-22T17:59:46 - -
View the plan and observe the timestamp to verify the device redeployment.
admin@ncs% run show sr-pce-plan PCE-0 plan component
POST
BACK STATUS
ACTION
TYPE NAME TRACK GOAL CODE STATE
STATUS WHEN ref STATUS
----------------------------------------------------------------------
self self false - - init
reached 2020-04-22T17:50:05 - -
ready
reached 2020-04-22T18:04:02 - -
cisco-sr-te-pce-fp-nano-plan-services:node PIOSXR-0 false - - init
reached 2020-04-22T17:50:05 - -
cisco-sr-te-
pce-fp-nano-plan-services:config-apply reached 2020-04-22T18:04:02 - -
ready
reached 2020-04-22T18:04:02 - -
View the plan to verify the site redeployment. The following displays a plan
for a local-site redeployment.
BACK
POST ACTION
TYPE NAME TRACK GOAL STATE
STATUS WHEN ref STATUS
------------------------------------------------------------------------------------------
self self false - init
reached 2020-02-11T22:10:06 - -
ready
reached 2020-02-11T22:20:01 - -
local-site PIOSXR-0 false - init
reached 2020-02-11T22:10:06 - -
cisco-
flat-L2vpn-fp-nano-plan-services:config-apply reached 2020-02-11T22:19:29 - -
ready
reached 2020-02-11T22:19:29 - -
remote-site PIOSXR-1 false - init
reached 2020-02-11T22:10:06 - -
cisco-
flat-L2vpn-fp-nano-plan-services:config-apply reached 2020-02-11T22:12:11 - -
ready
reached 2020-02-11T22:12:11 - -
View the plan to verify the endpoint redeployment. The following displays a
plan for an endpoint redeployment.
BACK
POST ACTION
TYPE NAME TRACK GOAL STATE
STATUS WHEN ref STATUS
------------------------------------------------------------------------------------------
self self false - init
reached 2020-02-21T00:36:11 - -
ready
reached 2020-02-21T02:18:25 - -
endpoint nc-0 false - init
reached 2020-02-21T00:36:11 - -
cisco-
flat-L3vpn-fp-nano-plan-services:config-apply reached 2020-02-21T02:18:23 - -
ready
reached 2020-02-21T02:18:23 - -
endpoint nc-1 false - init
reached 2020-02-21T00:36:11 - -
cisco-
flat-L3vpn-fp-nano-plan-services:config-apply reached 2020-02-21T02:17:55 - -
ready
reached 2020-02-21T02:17:55 - -
8 Using Custom-Templates
You can configure the devices directly by using custom-templates. With
custom-templates, you can also apply additional configurations that are not
supported by SR-TE CFP.
To use this feature, the apply-custom-template flag must be set to true. By
default, this flag is set to true. The plan for the service displays the status of
the custom-templates.
You can also turn this feature on/off. For more information on turning this flag
on/off, see section Turning Custom-Templates On/Off in this chapter.
While installing the CFP packages, the installer extracts and saves the custom-
templates-utils package in the /var/opt/ncs/packages directory.
If the custom-templates-utils package is not saved in the
/var/opt/ncs/packages directory, do the following:
1. Download the ncs-5.2.1-custom-template-utils-1.2.0-e5f4603.tar.gz file from
Cisco website.
2. Copy the file to the /var/opt/ncs/packages directory and extract the file.
3. Load the custom-templates packages to ncs in any of the following ways as
required.
a. If ncs is stopped, start ncs with the package reload option.
b. If ncs is running, execute request packages reload in ncs_cli.
Custom-templates must adhere to a naming convention. The custom-
templates name must start with either ct- or CT-. The device name variable in
configuration templates must be either DEVICE_NAME or DEVICE. These
variable names are reserved only for the device name in templates and hence
must not be used for anything else in a template.
For sample custom-templates for each service, see section Custom-Template
Payloads in this documentation.
10 Deleting Services
You may want to delete a service when the devices in the service are down or
when there is policy discrepancies. Use the following commands to delete the
services.
SR-ODN
delete sr-te cisco-sr-te-cfp-sr-odn:odn odn-template <service-name>
SR-Policy
delete sr-te cisco-sr-te-cfp-sr-policies:policies policy <service-
name>
SR-Settings
delete sr-setting <service-name>
SR-PCE
delete sr-pce <service-name>
L2VPN
delete flat-L2vpn <service-name>
L3VPN
delete flat-L3vpn <service-name>
11 Notifications
SR-TE CFP generates the following notifications that communicate important
information about the various events. Use this information to modify and
examine the payload content for a specific event.
Create Notification
notification {
eventTime 2020-04-24T17:26:51.198717+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component PIOSXR-0
state cisco-sr-te-cfp-sr-odn-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T17:26:51.198761+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component PIOSXR-0
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T17:26:54.428729+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T17:26:54.428848+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component P-0
state cisco-sr-te-cfp-sr-odn-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T17:26:54.428909+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component P-0
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T17:26:54.429021+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component PIOSXR-0
state cisco-sr-te-cfp-sr-odn-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T17:26:54.429094+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
component PIOSXR-0
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T17:27:58.800174+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-
template[name='SR-ODN']
operation deleted
}
}
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-26T20:25:12.262427+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-
policies:policies/policy[name='SR-CLI-DYNAMIC']
component PIOSXR-0
state cisco-sr-te-cfp-sr-policies-nano-plan-services:config-
apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-26T20:25:12.262501+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-
policies:policies/policy[name='SR-CLI-DYNAMIC']
component PIOSXR-0
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-26T13:27:18.478531+00:00
plan-state-change {
service /sr-te/cisco-sr-te-cfp-sr-
policies:policies/policy[name='SR-CLI-DYNAMIC']
operation deleted
}
}
notification {
eventTime 2020-04-24T22:23:49.485567+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component P-1
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T22:23:49.485695+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component PIOSXR-0
state init
operation created
status reached
}
}
notification {
eventTime 2020-04-24T22:23:49.485746+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component PIOSXR-0
state cisco-sr-te-settings-fp-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T22:23:49.48579+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component PIOSXR-0
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T22:23:49.485919+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component PIOSXR-1
state init
operation created
status reached
}
}
notification {
eventTime 2020-04-24T22:23:49.485967+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component PIOSXR-1
state cisco-sr-te-settings-fp-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T22:23:49.486011+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
component PIOSXR-1
state ready
operation created
status not-reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T15:24:31.965713+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='SETTING-1']
operation deleted
}
}
Create Notification
notification {
eventTime 2020-04-24T20:57:47.97983+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component self
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T20:57:47.979971+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component PIOSXR-0
state init
operation created
status reached
}
}
notification {
eventTime 2020-04-24T20:57:47.980017+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component PIOSXR-0
state cisco-sr-te-settings-fp-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T20:57:47.98006+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component PIOSXR-0
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T20:57:50.587655+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T20:57:50.587769+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component PIOSXR-0
state cisco-sr-te-settings-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T20:57:50.587842+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
component PIOSXR-0
state ready
Delete Notifications
notification {
eventTime 2020-04-24T20:59:56.64972+00:00
plan-state-change {
service /cisco-sr-te-settings-fp:sr-setting[name='ALGO-1']
operation deleted
}
}
Create Notification
notification {
eventTime 2020-04-27T23:13:43.877658+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component self
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-27T23:13:43.877775+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component P-0
state init
operation created
status reached
}
}
notification {
eventTime 2020-04-27T23:13:43.877816+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component P-0
state cisco-sr-te-pce-fp-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-27T23:13:43.877877+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component P-0
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-27T23:13:45.198269+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-27T23:13:45.19838+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component P-0
state cisco-sr-te-pce-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-27T23:13:45.198445+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
component P-0
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-27T16:17:18.761193+00:00
plan-state-change {
service /cisco-sr-te-pce-fp:sr-pce[name='PCE-0']
operation deleted
}
}
Create Notification
notification {
eventTime 2020-04-24T18:46:03.713054+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T18:46:03.7131+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component P-1
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T18:46:07.027717+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T18:46:07.027856+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component P-0
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T18:46:07.027971+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component P-0
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T18:46:07.028137+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T18:46:07.028216+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
component P-1
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T11:48:54.258083+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn01-nc']
operation deleted
}
}
Create Notification
notification {
eventTime 2020-04-24T19:04:38.620857+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T19:04:38.620913+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state ready
operation created
status not-reached
}
}
notification {
eventTime 2020-04-24T19:04:40.766288+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:04:40.766411+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-0
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:04:40.766538+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-0
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:04:40.76666+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:04:40.766727+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T12:16:07.883587+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
operation deleted
}
}
Create Notification
notification {
eventTime 2020-04-24T19:17:23.181496+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status not-reached
}
}
notification {
eventTime 2020-04-24T19:17:23.181557+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state ready
operation modified
status not-reached
}
}
notification {
eventTime 2020-04-24T19:17:24.918581+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:17:24.918739+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-0
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:17:24.918823+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-0
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:17:24.918995+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:17:24.919065+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T12:18:30.345774+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
operation deleted
}
}
Create Notification
notification {
eventTime 2020-04-24T19:46:34.412326+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status not-reached
}
}
notification {
eventTime 2020-04-24T19:46:34.412384+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state ready
operation modified
status not-reached
}
}
notification {
eventTime 2020-04-24T19:46:36.2144+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component self
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:46:36.214512+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-0
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:46:36.214574+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-0
state ready
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:46:36.214668+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state cisco-flat-L2vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:46:36.21472+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
component P-1
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T12:47:30.237791+00:00
plan-state-change {
service /flat-L2vpn[name='L2vpn-dynamic-02-nc']
operation deleted
}
}
notification {
eventTime 2020-04-24T19:53:28.990296+00:00
plan-state-change {
service /cisco-flat-L3vpn-fp:flat-L3vpn[name='L3']
component nc-1
state cisco-flat-L3vpn-fp-nano-plan-services:config-apply
operation modified
status reached
}
}
notification {
eventTime 2020-04-24T19:53:28.99036+00:00
plan-state-change {
service /cisco-flat-L3vpn-fp:flat-L3vpn[name='L3']
component nc-1
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T15:05:57.4621+00:00
plan-state-change {
service /cisco-flat-L3vpn-fp:flat-L3vpn[name='L3']
operation deleted
}
}
status reached
}
}
notification {
eventTime 2020-04-24T22:13:40.076062+00:00
plan-state-change {
service /cisco-flat-L3vpn-fp:flat-L3vpn[name='L3']
component nc-0
state ready
operation modified
status reached
}
}
Delete Notifications
notification {
eventTime 2020-04-24T15:15:13.831081+00:00
plan-state-change {
service /cisco-flat-L3vpn-fp:flat-L3vpn[name='L3']
operation deleted
}
}
12 Handling Zombies
Zombies are the internal operational data model in NSO to store deleted
service data. Zombies are helpful when performing staged deletions and RFM.
RFM is the NSO version of eventual consistency.
When a service deletion is triggered, NSO maintains references of the deleted
services (zombies) in operational data. The zombies are deleted from CDB
when all the configurations for the service are removed from the devices.
Zombies inform the Northbound the progress of a service deletion. It also
informs the stage it is waiting on, which helps to point to the problematic
area. For more information on nano-services and zombies, see NSO Developer
Guide.
In T-SDN FPs, you trigger a deletion to clean up the configuration on all the
endpoints/nodes in a service. However, depending on the number of nodes or
endpoints in a service, deleting the configuration at once may lock down the
database until the time the slowest device removes the configuration. It is,
therefore, recommended to delete the configurations in separate
transactions, such as per device.
Once the configuration is successfully removed from all the devices in the
service, continue to update the plan state to communicate the progress of
deletion to Nortbound. When the last device configuration is removed,
remove the plan, zombies, and all the service-related operational data from
CDB.
Sometimes, zombies are not deleted in the following scenarios even after
deleting the last device configuration. Some failures may require manual
intervention to delete configuration references from the devices. In such
cases, run the Cleanup action on the device and then run the service cleanup
action on T-SDN FPs. For more information on the Cleanup actions, see
chapter Working with Action Commands in this documentation.
1. Device is not reachable during deletion.
2. Device is reachable, but the configuration removal fails on the device for
other reasons.
To recreate a service with the same name as a deleted service, wait for the
service plan to be deleted. If the Northbound system tries to recreate the
service instance before the zombie/delete is fully processed, the following
error displays, which indicates the deletion process is still in progress.
"Aborted: Operation failed because: Service still in zombie state: 'YYY'".
Note: T-SDN FPs do not support zombie resurrect and redeploy options.
The following are some sample zombies for the SR-ODN service.
admin@ncs% run show zombies
::::::::::::::::::::::::::::INTERNAL ZOMBIE::::::::::::::::::::::::::::
zombies service /sr-te/cisco-sr-te-cfp-sr-odn-internal:odn/odn-template[name='SR-
ODN'][head-end='PIOSXR-0']
delete-path /sr-te/cisco-sr-te-cfp-sr-odn-internal:odn/odn-template[name='SR-ODN'][head-
end='PIOSXR-0']
POST
BACK
ACTION
TYPE NAME TRACK GOAL STATE STATUS
WHEN ref STATUS
-------------------------------------------------------------------------------
self self true - init reached -
- -
cisco-sr-te-cfp-sr-odn-nano-services:config-apply reached -
- -
ready not-reached -
- -
plan failed
plan error-info message "Failed to connect to device PIOSXR-0: connection refused: NEDCOM
CONNECT: Connection refused (Connection refused) in new state"
plan error-info log-entry "/zombies/service[service-path=\"/sr-te/cisco-sr-te-cfp-sr-odn-
internal:odn/odn-template[name='SR-ODN'][head-end='PIOSXR-0']\"]/log/log-entry[when='2020-
03-26T23:34:12.992768+00:00']"
WHEN TYPE LEVEL MESSAGE
-------------------------------------------------------------------------------
2020-03-26T23:34:12.992768+00:00 service-modified error Failed to connect to device
PIOSXR-0: connection refused: NEDCOM CONNECT: Connection refused (Connection refused) in
new state
::::::::::::::::::::::::::::EXTERNAL ZOMBIE::::::::::::::::::::::::::::
zombies service /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-template[name='SR-ODN']
delete-path /sr-te/cisco-sr-te-cfp-sr-odn:odn/odn-template[name='SR-ODN']
POST
BACK
ACTION
TYPE NAME TRACK GOAL STATE
STATUS WHEN ref STATUS
-------------------------------------------------------------------------------
self self true - init
not-reached - - -
ready
not-reached - - -
cisco-sr-te-cfp-sr-odn-nano-plan-services:head-end PIOSXR-0 true - init
reached - - -
cisco-sr-te-
cfp-sr-odn-nano-plan-services:config-apply failed - - -
ready
not-reached - - -
plan failed
module: cisco-sr-te-cfp-sr-policies
module: cisco-sr-te-cfp-sr-policies
augment /cisco-sr-te-cfp:sr-te:
+--rw policies
+--rw policy* [name]
| +--rw name? cisco-sr-te-cfp-sr-
types:Cisco-ios-xr-string
| +--rw head-end* [name]
| | +--rw name? -> /ncs:devices/device/name
| +--rw tail-end inet:ip-address
| +--rw color uint32
| +--rw binding-sid? uint32
| +--rw path* [preference]
| | +--rw preference? uint16
| | +--rw (sr-te-path-choice)?
| | +--:(explicit-path)
| | | +--rw explicit!
| | | +--rw sid-list* [name]
| | | | +--rw name? -> /cisco-sr-te-cfp:sr-
te/cisco-sr-te-cfp-sr-policies:policies/sid-list/name
| | | | +--rw weight? uint32
| | | +--rw constraints
| | | +--rw disjoint-path!
| | | | +--rw type enumeration
| | | | +--rw group-id uint16
| | | | +--rw sub-id? uint16
| | | +--rw affinity!
| | | | +--rw rule* [action]
| | | | +--rw action? enumeration
| | | | +--rw color* string
| | | +--rw segments!
| | | +--rw sid-algorithm? uint16
| | +--:(dynamic-path)
| | +--rw dynamic!
| | +--rw metric-type? enumeration
| | +--rw pce!
| | +--rw constraints
| | +--rw sid-limit? uint32
| | +--rw disjoint-path!
| | | +--rw type enumeration
| | | +--rw group-id uint16
| | | +--rw sub-id? uint16
| | +--rw affinity!
| | | +--rw rule* [action]
| | | +--rw action? enumeration
| | | +--rw color* string
| | +--rw segments!
| | +--rw sid-algorithm? uint16
| | | | | | +--:(index)
| | | | | | | +--rw index uint32
| | | | | | +--:(auto-assign-absolute)
| | | | | | | +--rw auto-assign-absolute empty
| | | | | | +--:(auto-assign-index)
| | | | | | +--rw auto-assign-index empty
| | | | | +--rw n-flag-clear? empty
| | | | +--rw flex-algo* [name]
| | | | +--rw name -> ../../../flex-algo/name
| | | +--rw address-family? enumeration
| | | +--rw mpls-preference? enumeration
| | | +--rw igp-metric!
| | | | +--rw metric? union
| | | | +--rw metric-level!
| | | | +--rw metric* [level]
| | | | +--rw level uint8
| | | | +--rw value? union
| | | +--rw flex-algo* [name]
| | | +--rw name uint32
| | | +--rw affinity-exclude-any* string
| | | +--rw metric-type? enumeration
| | | +--rw priority? uint32
| | | +--rw advertise-definition? empty
| | | +--rw algorithm-prefix-sid!
| | | +--rw (algorithm-prefix-sid-choice)?
| | | +--:(absolute)
| | | | +--rw absolute uint32
| | | +--:(index)
| | | | +--rw index uint32
| | | +--:(auto-assign-absolute)
| | | | +--rw auto-assign-absolute empty
| | | +--:(auto-assign-index)
| | | +--rw auto-assign-index empty
| | +--rw interface* [if-type if-id]
| | | +--rw if-type enumeration
| | | +--rw if-id string
| | | +--rw te!
| | | | +--rw affinity!
| | | | | +--rw color* [name]
| | | | | +--rw name -> ../../../../../../affinity-map-
te/color/name
| | | | +--rw metric? uint32
| | | +--rw isis!
| | | | +--rw instance-name string
| | | | +--rw affinity!
| | | | | +--rw color* [name]
| | | | | +--rw name -> ../../../../../../affinity-map-
isis/color/name
| | | | +--rw interface-igp-metric!
| | | | +--rw metric? union
| | | | +--rw metric-level!
module: cisco-flat-L3vpn-fp
+--rw l3vpn-route-policy* [name]
| +--rw name service-name
| +--rw color* [id]
| +--rw id uint32
| +--rw ipv4!
| | +--rw prefix* tailf:ipv4-address-and-prefix-length
| +--rw ipv6!
| +--rw ipv6-prefix* tailf:ipv6-address-and-prefix-length
+--rw flat-L3vpn* [name]
| +--rw name service-name
| +--rw endpoint* [endpoint-name]
| | +--rw endpoint-name string
| | +--rw access-pe -> /ncs:devices/device/name
| | +--rw if-type enumeration
| | +--rw if-id string
| | +--rw mtu? uint16
| | +--rw pe-ip-addr? tailf:ipv4-address-and-prefix-
length
| | +--rw pe-ipv6-addr? tailf:ipv6-address-and-prefix-
length
| | +--rw as-no? as-no-type
| | +--rw vlan-id? int32
| | +--rw ce-pe-prot
| | | +--rw (routing)?
| | | +--:(e-bgp)
| | | +--rw e-bgp
| | | +--rw neighbor-ipv4? inet:ipv4-address
| | | +--rw neighbor-ipv6? inet:ipv6-address
| | | +--rw remote-as-ipv4 as-no-type
| | | +--rw remote-as-ipv6 as-no-type
| | | +--rw update-source!
| | | +--rw if-type enumeration
| | | +--rw if-id string
| | +--rw vrf
| | | +--rw vrf-definition string
| | | +--rw route-distinguisher? asn-ip-type
| | | +--rw vpn-id? vpn-id-type
| | | +--rw address-family* [address-family]
| | | +--rw address-family address-family-type
| | | +--rw redistribute-connected? empty
| | | +--rw metric? Bgp-default-metric-range
| | | +--rw vpn-target* [rt-value]
| | | +--rw rt-type bgp-rt-type
| | | +--rw rt-value asn-ip-type
| | +--rw sr-te!
| | | +--rw (type)?
| | | +--:(route-policy)
| | | +--rw route-policy -> /l3vpn-route-policy/name
| | +--rw l2-attachment-circuit* [name]
| | | +--rw name string
| | | +--rw if-type enumeration
| | | +--rw if-id string
15.1.1 SR-ODN
Custom-template for all head-ends
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-te xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te">
<odn xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te-sr-odn">
<odn-template>
<name>SR-CLI-ODN-300</name>
<custom-template>
=============================================================>
APPLYING CUSTOM TEMPLATE AT GLOBAL LEVEL FOR ALL HEAD-ENDs
<name>CT-CLI-banner</name>
<variable>
<name>BANNER_TEXT</name>
<value>Welcome</value>
</variable>
</custom-template>
<head-end>
<name>PIOSXR-0</name>
</head-end>
...
</odn-template>
</odn>
</sr-te>
</config>
15.1.2 SR-Policy
Sample service payload using custom-template
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-te xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te">
<policies xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te-sr-
policies">
<policy>
<name>SR-CLI-DYNAMIC</name>
=================================================== CUSTOM TEMPLATE
CONFIG FOR SR-POLICY
<custom-template>
<name>CT-CLI-logging</name>
</custom-template>
...
</policy>
</policies>
</sr-te>
</config>
15.1.3 SR-Settings
Custom-templates for all nodes or per node
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-setting xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-
sr-te-settings">
<name>SETTING-1</name>
<custom-template>
=====================================================> APPLYING CT AT
GLOBAL LEVEL FOR ALL THE DEVICES IN A SERVICE
<name>CT-CLI-logging</name>
</custom-template>
<maximum-sid-depth>100</maximum-sid-depth>
<affinity-map-te>
<color>
<name>BLUE</name>
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<bit-position>0</bit-position>
</color>
</affinity-map-te>
<pcc>
<pce>
<address>
<ipv4>
<address>1.1.1.1</address>
<precedence>128</precedence>
</ipv4>
<ipv4>
<address>2.2.2.2</address>
</ipv4>
</address>
</pce>
</pcc>
<node>
<name>PIOSXR-0</name>
<custom-template>
=====================================================> APPLYING CT AT
LOCAL LEVEL FOR GIVEN THE DEVICE IN A SERVICE
<name>CT-CLI-banner</name>
<variable>
<name>BANNER_TEXT</name>
<value>Welcome</value>
</variable>
</custom-template>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>5</if-id>
<te>
<affinity>
<color>
<name>GREEN</name>
</color>
</affinity>
<metric>2</metric>
</te>
</interface>
<pcc>
<source-address>192.168.2.1</source-address>
</pcc>
</node>
<node>
<name>PIOSXR-1</name>
<interface>
<if-type>GigabitEthernet</if-type>
<if-id>7</if-id>
<te>
<affinity>
<color>
<name>BLUE</name>
</color>
</affinity>
<metric>2</metric>
</te>
</interface>
<pcc>
<disable/>
</pcc>
</node>
</sr-setting>
</config>
15.1.4 SR-PCE
Custom-template for all nodes or per node
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-pce xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-sr-te-
pce">
<name>PCE-0</name>
<custom-template> ==========================================>
APPLYING CUSTOM TEMPLATE AT GLOBAL LEVEL FOR ALL NODES
<name>CT-CLI-logging</name>
</custom-template>
<node>
<name>PIOSXR-0</name>
<custom-template> ==========================================>
APPLYING CUSTOM TEMPLATE AT LOCAL LEVEL FOR GIVEN NODE
<name>CT-CLI-banner</name>
<variable>
<name>BANNER_TEXT</name>
<value>Welcome</value>
</variable>
</custom-template>
<pce>
<address>100.1.1.1</address>
<disjoint-path>
<group-id>
<id>60000</id>
<type>srlg</type>
<strict/>
<lsp>
<id>1</id>
<pcc-address>2.2.2.2</pcc-address>
<lsp-name>LSP-NAME</lsp-name>
<shortest-path/>
</lsp>
</group-id>
</disjoint-path>
<timers>
<reoptimization>600</reoptimization>
<keepalive>20</keepalive>
<minimum-peer-keepalive>21</minimum-peer-keepalive>
</timers>
<state-sync>
<ipv4>
<address>3.3.3.3</address>
</ipv4>
</state-sync>
<password>
<type>clear</type>
<secret>password123</secret>
</password>
<backoff>
<ratio>11</ratio>
<difference>10</difference>
<threshold>12</threshold>
</backoff>
<segment-routing>
<strict-sid-only/>
<te-latency/>
</segment-routing>
</pce>
</node>
</sr-pce>
</config>
<config xmlns="http://tail-f.com/ns/config/1.0">
<flat-L3vpn xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-
flat-L3vpn">
<name>L3</name>
<custom-template>==============================================
==> APPLYING CUSTOM TEMPLATE AT GLOBAL LEVEL FOR ALL ENDPOINTS
<name>CT-NETCONF-logging</name>
</custom-template>
<endpoint>
<endpoint-name>nc-0</endpoint-name>
<access-pe>P-0</access-pe>
<if-type>Loopback</if-type>
<if-id>3</if-id>
<pe-ip-addr>169.1.1.1/32</pe-ip-addr>
<as-no>65001</as-no>
<custom-template>============================================
==> APPLYING CUSTOM TEMPLATE AT LOCAL LEVEL FOR SINGLE ENDPOINT
<name>CT-NETCONF-banner-iteration</name>
<iteration>
<number>1</number>
<variable>
<name>BANNER_NAME</name>
<value>login</value>
</variable>
<variable>
<name>BANNER_TEXT</name>
<value>Welcome to Netconf P-0</value>
</variable>
</iteration>
<iteration>
<number>2</number>
<variable>
<name>BANNER_NAME</name>
<value>prompt-timeout</value>
</variable>
<variable>
<name>BANNER_TEXT</name>
<value>TimedOut</value>
</variable>
</iteration>
</custom-template>
<vrf>
<vrf-definition>L3VPN</vrf-definition>
<route-distinguisher>1:2</route-distinguisher>
<address-family>
<address-family>ipv4</address-family>
<vpn-target>
<rt-value>200:100</rt-value>
<rt-type>both</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:101</rt-value>
<rt-type>export</rt-type>
</vpn-target>
<vpn-target>
<rt-value>100:102</rt-value>
<rt-type>import</rt-type>
</vpn-target>
</address-family>
</vrf>
<ce-pe-prot>
<e-bgp>
<neighbor-ipv4>169.1.1.2</neighbor-ipv4>
<remote-as-ipv4>65002</remote-as-ipv4>
</e-bgp>
</ce-pe-prot>
<sr-te>
<color>
<id>3000</id>
<ipv4>
</ipv4>
</color>
<color>
<id>3001</id>
<ipv4>
<prefix>10.1.1.1/32</prefix>
<prefix>20.1.1.1/32</prefix>
</ipv4>
</color>
</sr-te>
</endpoint>
...
</flat-L3vpn>
</config>
15.2.1 SR-ODN
get-modifications action for a service
admin@ncs% request sr-te cisco-sr-te-cfp-sr-odn:odn odn-template SR-
ODN action get-modifications outformat xml
message <devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>P-0</name>
<config>
<sr xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-segment-
routing-ms-cfg">
<traffic-engineering xmlns="http://cisco.com/ns/yang/Cisco-
IOS-XR-infra-xtc-agent-cfg">
<on-demand-colors>
<on-demand-color>
<color>300</color>
<on-demand-color-dyn-mpls>
<on-demand-color-dyn-mpls-metric>
<metric-type>igp</metric-type>
<enable/>
</on-demand-color-dyn-mpls-metric>
<on-demand-color-dyn-mpls-pce>
<enable/>
</on-demand-color-dyn-mpls-pce>
<disjoint-path>
<group-id>10</group-id>
<disjointness-type>node</disjointness-type>
<sub-id>5</sub-id>
</disjoint-path>
<on-demand-color-dyn-mpls-flex-algorithm>200</on-
demand-color-dyn-mpls-flex-algorithm>
<enable/>
<affinity-rules>
<affinity-rule>
<rule>affinity-exclude-any</rule>
<affinity-name>
<affinity-name>BLUE</affinity-name>
</affinity-name>
</affinity-rule>
</affinity-rules>
</on-demand-color-dyn-mpls>
<bandwidth>200</bandwidth>
<maximum-sid-depth>6</maximum-sid-depth>
<enable/>
</on-demand-color>
</on-demand-colors>
</traffic-engineering>
</sr>
</config>
</device>
</devices>
15.2.2 SR-Policy
get-modifications action for service
admin@ncs% request sr-te cisco-sr-te-cfp-sr-policies:policies policy
SR-CLI-DYNAMIC action get-modifications outformat xml
message <devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>PIOSXR-0</name>
<config>
<segment-routing xmlns="http://tail-f.com/ned/cisco-ios-xr">
<traffic-eng>
<segment-list>
<name>mysidlist</name>
<index>
<id>1</id>
<mpls>
<label>17001</label>
</mpls>
</index>
<index>
<id>2</id>
<mpls>
<label>18001</label>
</mpls>
</index>
</segment-list>
<policy>
<name>SR-CLI-DYNAMIC</name>
<color>
<end-point>
<ipv4>1.1.1.1</ipv4>
</end-point>
</color>
<candidate-paths>
<preference>
<id>200</id>
<explicit>
<segment-list>
<name>mysidlist</name>
<weight>10</weight>
</segment-list>
</explicit>
</preference>
</candidate-paths>
</policy>
</traffic-eng>
</segment-routing>
</config>
</device>
</devices>
15.2.3 SR-Settings
get-modifications action for a service
admin@ncs% request sr-setting SETTING-1 action get-modifications
outformat xml
message <devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>PIOSXR-0</name>
<config>
<segment-routing xmlns="http://tail-f.com/ned/cisco-ios-xr">
<traffic-eng>
<interface>
<name>GigabitEthernet5</name>
<affinity>
<color>
<name>GREEN</name>
</color>
</affinity>
<metric>2</metric>
</interface>
<maximum-sid-depth>100</maximum-sid-depth>
<affinity-map>
<color>
<name>BLUE</name>
<prefix>name</prefix>
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<prefix>name</prefix>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<prefix>name</prefix>
<bit-position>0</bit-position>
</color>
</affinity-map>
<pcc>
<source-address>
<ipv4>192.168.2.1</ipv4>
</source-address>
<pce>
<address>
<ipv4>
<address>1.1.1.1</address>
<precedence>128</precedence>
</ipv4>
<ipv4>
<address>2.2.2.2</address>
<precedence>255</precedence>
</ipv4>
</address>
</pce>
</pcc>
</traffic-eng>
</segment-routing>
</config>
</device>
</devices>
<devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>PIOSXR-1</name>
<config>
<segment-routing xmlns="http://tail-f.com/ned/cisco-ios-xr">
<traffic-eng>
<interface>
<name>GigabitEthernet7</name>
<affinity>
<color>
<name>BLUE</name>
</color>
</affinity>
<metric>2</metric>
</interface>
<maximum-sid-depth>100</maximum-sid-depth>
<affinity-map>
<color>
<name>BLUE</name>
<prefix>name</prefix>
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<prefix>name</prefix>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<prefix>name</prefix>
<bit-position>0</bit-position>
</color>
</affinity-map>
</traffic-eng>
</segment-routing>
</config>
</device>
</devices>
<interface>
<name>GigabitEthernet5</name>
<affinity>
<color>
<name>GREEN</name>
</color>
</affinity>
<metric>2</metric>
</interface>
<maximum-sid-depth>100</maximum-sid-depth>
<affinity-map>
<color>
<name>BLUE</name>
<prefix>name</prefix>
<bit-position>1</bit-position>
</color>
<color>
<name>GREEN</name>
<prefix>name</prefix>
<bit-position>2</bit-position>
</color>
<color>
<name>RED</name>
<prefix>name</prefix>
<bit-position>0</bit-position>
</color>
</affinity-map>
<pcc>
<source-address>
<ipv4>192.168.2.1</ipv4>
</source-address>
<pce>
<address>
<ipv4>
<address>1.1.1.1</address>
<precedence>128</precedence>
</ipv4>
<ipv4>
<address>2.2.2.2</address>
<precedence>255</precedence>
</ipv4>
</address>
</pce>
</pcc>
</traffic-eng>
</segment-routing>
</config>
</device>
</devices>
15.2.4 SR-PCE
get-modifications action for a service
admin@ncs% request sr-pce PCE-0 action get-modifications outformat xml
message <devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>PIOSXR-0</name>
<config>
<pce xmlns="http://tail-f.com/ned/cisco-ios-xr">
<address>
<ipv4>100.1.1.1</ipv4>
</address>
<disjoint-path>
<group-id>
<id>60000</id>
<type>srlg</type>
<sub-id>1</sub-id>
<strict/>
<lsp>
<id>1</id>
<pcc>
<ipv4>2.2.2.2</ipv4>
</pcc>
<lsp-name>LSP-NAME</lsp-name>
<shortest-path/>
</lsp>
</group-id>
</disjoint-path>
<timers>
<reoptimization>600</reoptimization>
<keepalive>20</keepalive>
<minimum-peer-keepalive>21</minimum-peer-keepalive>
</timers>
<state-sync>
<ipv4>
<address>3.3.3.3</address>
</ipv4>
</state-sync>
<password>
<type>clear</type>
<secret>password123</secret>
</password>
<backoff>
<ratio>11</ratio>
<difference>10</difference>
<threshold>12</threshold>
</backoff>
<segment-routing>
<strict-sid-only/>
<te-latency/>
</segment-routing>
</pce>
</config>
</device>
</devices>
<ip-version>ipv4</ip-version>
<mpls>
<static>
<label>
<local>101</local>
<remote>202</remote>
</label>
</static>
</mpls>
<pw-class>P2P-DOT1Q</pw-class>
</neighbor>
</p2p>
</group>
</xconnect>
</l2vpn>
</config>
</device>
</devices>
<devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>PIOSXR-1</name>
<config>
<interface xmlns="http://tail-f.com/ned/cisco-ios-xr">
<HundredGigE>
<id>0/0/0/8</id>
<description>T-SDN Interface</description>
</HundredGigE>
<HundredGigE-subinterface>
<HundredGigE>
<id>0/0/0/8.100</id>
<mode>l2transport</mode>
<description>T-SDN Interface</description>
<encapsulation>
<dot1q>
<vlan-id>100</vlan-id>
</dot1q>
</encapsulation>
<rewrite>
<ingress>
<tag>
<translate>1-to-1</translate>
<dot1q>123</dot1q>
<mode>symmetric</mode>
</tag>
</ingress>
</rewrite>
</HundredGigE>
</HundredGigE-subinterface>
</interface>
<l2vpn xmlns="http://tail-f.com/ned/cisco-ios-xr">
<pw-class>
<name>P2P-DOT1Q</name>
<encapsulation>
<mpls/>
</encapsulation>
</pw-class>
<xconnect>
<group>
<name>P2P-DOT1Q</name>
<p2p>
<name>P2P-DOT1Q</name>
<interface>
<name>HundredGigE0/0/0/8.100</name>
</interface>
<neighbor>
<address>12.0.0.0</address>
<pw-id>100</pw-id>
<ip-version>ipv4</ip-version>
<mpls>
<static>
<label>
<local>202</local>
<remote>101</remote>
</label>
</static>
</mpls>
<pw-class>P2P-DOT1Q</pw-class>
</neighbor>
</p2p>
</group>
</xconnect>
</l2vpn>
</config>
</device>
</devices>
</interface>
<l2vpn xmlns="http://tail-f.com/ned/cisco-ios-xr">
<pw-class>
<name>mpls-nso</name>
<encapsulation>
<mpls/>
</encapsulation>
</pw-class>
<xconnect>
<group>
<name>p2p-nso</name>
<p2p>
<name>STATIC-PIOSXR-1</name>
<interface>
<name>TenGigE0/0/0/7.200</name>
</interface>
<neighbor>
<address>12.0.0.0</address>
<pw-id>100</pw-id>
<ip-version>ipv4</ip-version>
<mpls>
<static>
<label>
<local>202</local>
<remote>101</remote>
</label>
</static>
</mpls>
<pw-class>mpls-nso</pw-class>
</neighbor>
</p2p>
</group>
</xconnect>
</l2vpn>
</config>
</device>
</devices>
<as-index>100</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
</route-target>
</route-targets>
</import-route-targets>
<export-route-targets>
<route-targets>
<route-target>
<type>as</type>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>100</as>
<as-index>101</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>200</as>
<as-index>100</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
</route-target>
</route-targets>
</export-route-targets>
</bgp>
</af>
</afs>
</vrf>
</vrfs>
<bgp xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-ipv4-bgp-cfg">
<instance>
<instance-name>default</instance-name>
<instance-as>
<as>0</as>
<four-byte-as>
<as>65001</as>
<vrfs>
<vrf>
<vrf-name>L3VPN</vrf-name>
<vrf-global>
<route-distinguisher>
<type>as</type>
<as-xx>0</as-xx>
<as>1</as>
<as-index>2</as-index>
</route-distinguisher>
<vrf-global-afs>
<vrf-global-af>
<af-name>ipv4-unicast</af-name>
<enable/>
</vrf-global-af>
</vrf-global-afs>
<exists/>
</vrf-global>
<vrf-neighbors>
<vrf-neighbor>
<neighbor-address>169.1.1.2</neighbor-address>
<vrf-neighbor-afs>
<vrf-neighbor-af>
<af-name>ipv4-unicast</af-name>
<activate/>
<route-policy-in>PASS_ALL</route-policy-in>
<route-policy-out>PASS_ALL</route-policy-
out>
</vrf-neighbor-af>
</vrf-neighbor-afs>
<remote-as>
<as-xx>0</as-xx>
<as-yy>65002</as-yy>
</remote-as>
</vrf-neighbor>
</vrf-neighbors>
</vrf>
</vrfs>
<bgp-running/>
</four-byte-as>
</instance-as>
</instance>
</bgp>
<routing-policy xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-
policy-repository-cfg">
<route-policies>
<route-policy>
<route-policy-name>PASS_ALL</route-policy-name>
<rpl-route-policy>route-policy PASS_ALL
pass
end-policy
</rpl-route-policy>
</route-policy>
</route-policies>
</routing-policy>
</config>
</device>
</devices>
<devices xmlns="http://tail-f.com/ns/ncs">
<device>
<name>P-1</name>
<config>
<interface-configurations xmlns="http://cisco.com/ns/yang/Cisco-
IOS-XR-ifmgr-cfg">
<interface-configuration>
<active>act</active>
<interface-name>Loopback3</interface-name>
<interface-virtual/>
<vrf xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-infra-rsi-
cfg">L3VPN</vrf>
<ipv4-network xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-
ipv4-io-cfg">
<addresses>
<primary>
<address>169.1.1.1</address>
<netmask>255.255.255.255</netmask>
</primary>
</addresses>
</ipv4-network>
</interface-configuration>
</interface-configurations>
<vrfs xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-infra-rsi-
cfg">
<vrf>
<vrf-name>L3VPN</vrf-name>
<create/>
<afs>
<af>
<af-name>ipv4</af-name>
<saf-name>unicast</saf-name>
<topology-name>default</topology-name>
<create/>
<bgp xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-ipv4-
bgp-cfg">
<import-route-targets>
<route-targets>
<route-target>
<type>as</type>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>100</as>
<as-index>102</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>200</as>
<as-index>100</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
</route-target>
</route-targets>
</import-route-targets>
<export-route-targets>
<route-targets>
<route-target>
<type>as</type>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>100</as>
<as-index>101</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>200</as>
<as-index>100</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
</route-target>
</route-targets>
</export-route-targets>
</bgp>
</af>
</afs>
</vrf>
</vrfs>
<bgp xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-ipv4-bgp-cfg">
<instance>
<instance-name>default</instance-name>
<instance-as>
<as>0</as>
<four-byte-as>
<as>65001</as>
<vrfs>
<vrf>
<vrf-name>L3VPN</vrf-name>
<vrf-global>
<route-distinguisher>
<type>as</type>
<as-xx>0</as-xx>
<as>1</as>
<as-index>2</as-index>
</route-distinguisher>
<vrf-global-afs>
<vrf-global-af>
<af-name>ipv4-unicast</af-name>
<enable/>
</vrf-global-af>
</vrf-global-afs>
<exists/>
</vrf-global>
<vrf-neighbors>
<vrf-neighbor>
<neighbor-address>169.1.1.2</neighbor-address>
<vrf-neighbor-afs>
<vrf-neighbor-af>
<af-name>ipv4-unicast</af-name>
<activate/>
<route-policy-in>PASS_ALL</route-policy-in>
<route-policy-out>PASS_ALL</route-policy-
out>
</vrf-neighbor-af>
</vrf-neighbor-afs>
<remote-as>
<as-xx>0</as-xx>
<as-yy>65002</as-yy>
</remote-as>
</vrf-neighbor>
</vrf-neighbors>
</vrf>
</vrfs>
<bgp-running/>
</four-byte-as>
</instance-as>
</instance>
</bgp>
<routing-policy xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-
policy-repository-cfg">
<route-policies>
<route-policy>
<route-policy-name>PASS_ALL</route-policy-name>
<rpl-route-policy>route-policy PASS_ALL
pass
end-policy
</rpl-route-policy>
</route-policy>
</route-policies>
</routing-policy>
</config>
</device>
</devices>
<bgp xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-ipv4-
bgp-cfg">
<import-route-targets>
<route-targets>
<route-target>
<type>as</type>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>100</as>
<as-index>102</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>200</as>
<as-index>100</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
</route-target>
</route-targets>
</import-route-targets>
<export-route-targets>
<route-targets>
<route-target>
<type>as</type>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>100</as>
<as-index>101</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
<as-or-four-byte-as>
<as-xx>0</as-xx>
<as>200</as>
<as-index>100</as-index>
<stitching-rt>0</stitching-rt>
</as-or-four-byte-as>
</route-target>
</route-targets>
</export-route-targets>
</bgp>
</af>
</afs>
</vrf>
</vrfs>
<bgp xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-ipv4-bgp-cfg">
<instance>
<instance-name>default</instance-name>
<instance-as>
<as>0</as>
<four-byte-as>
<as>65001</as>
<vrfs>
<vrf>
<vrf-name>L3VPN</vrf-name>
<vrf-global>
<route-distinguisher>
<type>as</type>
<as-xx>0</as-xx>
<as>1</as>
<as-index>2</as-index>
</route-distinguisher>
<vrf-global-afs>
<vrf-global-af>
<af-name>ipv4-unicast</af-name>
<enable/>
</vrf-global-af>
</vrf-global-afs>
<exists/>
</vrf-global>
<vrf-neighbors>
<vrf-neighbor>
<neighbor-address>169.1.1.2</neighbor-address>
<vrf-neighbor-afs>
<vrf-neighbor-af>
<af-name>ipv4-unicast</af-name>
<activate/>
<route-policy-in>PASS_ALL</route-policy-in>
<route-policy-out>PASS_ALL</route-policy-
out>
</vrf-neighbor-af>
</vrf-neighbor-afs>
<remote-as>
<as-xx>0</as-xx>
<as-yy>65002</as-yy>
</remote-as>
</vrf-neighbor>
</vrf-neighbors>
</vrf>
</vrfs>
<bgp-running/>
</four-byte-as>
</instance-as>
</instance>
</bgp>
<routing-policy xmlns="http://cisco.com/ns/yang/Cisco-IOS-XR-
policy-repository-cfg">
<route-policies>
<route-policy>
<route-policy-name>PASS_ALL</route-policy-name>
<rpl-route-policy>route-policy PASS_ALL
pass
end-policy
</rpl-route-policy>
</route-policy>
</route-policies>
</routing-policy>
</config>
</device>
</devices>
Device Verification
17001 100.100.100.1/32
18001 100.100.100.2/32
19001 100.100.100.3/32
20001 100.100.100.4/32
21001 Loopback0
22001 100.100.100.6/32
configure
set devices authgroups group iosxr_authgroup default-map remote-name
admin remote-password cisco
16.1.1 Use Case 1: Instantiating Example L3VPN over SR-TE for Color 30
L3VPN allows you to associate a SR-TE policy to instantiate the service. Define
and set the path for the color in the policy. For more information about
creating Flat L3VPN service and creating SR-Policies, see chapter
Configuration in this documentation.
This use case shows the end-to-end workflow to instantiate a
Flat-L3VPN service over SR-TE for color 30. The following diagram shows the
required tasks for this use case.
2. Display the plan and verify the policy is in the ready-reached state.
3. Get modifications for the policy to view if the configuration is pushed to the
device. For more information on the get-modifications action, see chapter
Working with Action Commands in this documentation.
admin@ncs# sr-te cisco-sr-te-cfp-sr-policies:policies policy sr-
flex action get-modifications outformat cli
message devices {
device PE-R5 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
+ policy srte_c_30_ep_100.100.100.6 {
+ binding-sid {
+ mpls 169001;
+ }
+ color {
+ value 30;
+ end-point {
+ ipv4 100.100.100.6;
+ }
+ }
+ candidate-paths {
+ preference 1 {
+ dynamic {
+ metric {
+ type te;
+ }
+ }
+ }
+ }
+ }
}
}
}
}
}
</vpn-target>
<vpn-target>
<rt-value>200:201</rt-value>
<rt-type>export</rt-type>
</vpn-target>
<vpn-target>
<rt-value>200:202</rt-value>
<rt-type>import</rt-type>
</vpn-target>
</address-family>
</vrf>
</endpoint>
</flat-L3vpn>
6. Associate the route policy to the L3VPN service. This configuration data is
deployed on the device when the flat-L3VPN service is applied with this route
policy.
<flat-L3vpn xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-
flat-L3vpn">
<name>L3vpn-flex</name>
<endpoint>
<endpoint-name>PE-R5</endpoint-name>
<sr-te>
<route-policy>L3-color-30</route-policy>
</sr-te>
</endpoint>
</flat-L3vpn>
7. Display the plan status for the L3VPN service and verify the service is
successfully deployed.
8. Get modifications for the L3VPN service and verify the route policy is applied
to the device PE-R5.
admin@ncs# flat-L3vpn L3vpn-flex action get-modifications outformat
cli
message devices {
device PE-R5 {
config {
cisco-ios-xr:vrf {
+ vrf-list L3VPN-flex {
+ address-family {
+ ipv4 {
+ unicast {
+ import {
+ route-target {
+ address-list 200:200;
+ address-list 200:202;
+ }
+ }
+ export {
+ route-policy SET_COLORv4_L3-
color-30;
+ route-target {
+ address-list 200:200;
+ address-list 200:201;
+ }
+ }
+ }
+ }
+ }
+ }
}
cisco-ios-xr:interface {
+ Loopback 4 {
+ description "T-SDN Interface";
+ vrf L3VPN-flex;
+ ipv4 {
+ address {
+ ip 122.122.122.1;
+ mask 255.255.255.255;
+ }
+ }
+ }
}
cisco-ios-xr:extcommunity-set {
+ opaque COLOR_30 {
+ set 30;
+ }
}
cisco-ios-xr:route-policy PASS_ALL {
- value " pass\r\n";
+ value pass;
}
+ cisco-ios-xr:route-policy SET_COLORv4_L3-color-30 {
+ value " if destination in (122.122.122.1/32)
then\r\n set extcommunity color COLOR_30\r\n endif\r\n";
+ }
cisco-ios-xr:router {
bgp {
bgp-no-instance 1 {
+ vrf L3VPN-flex {
+ rd 11:11;
+ address-family {
+ ipv4 {
+ unicast {
+ }
+ }
+ }
+ neighbor 123.123.123.2 {
+ remote-as 65009;
+ address-family {
+ ipv4 {
+ unicast {
+ route-policy in {
+ name PASS_ALL;
+ }
+ route-policy out {
+ name PASS_ALL;
+ }
+ }
+ }
+ }
+ }
+ }
}
}
}
}
RP/0/RP0/CPU0:PE-R5#
16.1.2 Use Case 2: Flat- L3VPN Route Policy for Color 20 by Using SR ODN with
Flex Algo
This use case discusses how to create and instantiate L3VPN service between
two devices for color 20. It discusses how to use the SR-ODN template for the
color for which an on-demand policy instantiation is desired.
The following diagram helps to understand the use case. The two devices -
device 5 and device 6 use two loopback interfaces for each device with IP
addresses 122.122.122.1 and 123.123.123.1 respectively on the same VIRL
L3VPN-T-SDN. Configure an ODN template for the color 20 for which to
instantiate the on-demand policy. Flex algo slices the network to define the
paths for the source and the destination traffic. For the color 20, flex algo
assigns the path 128 from device 5 and path 129 from device 6.
For more information about creating L3VPN service and SR-ODN service, see
chapter Configuration in this documentation. The following diagram shows
the required tasks for this use case.
To create a flat L3VPN route policy for color 20 by using SR-ODN with Flex
Algo:
1. Create SR-Settings service to setup Flex Algo on core and PE devices.
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-setting xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-
sr-te-settings">
<name>SR-SET-Flex-ALGO-ALL</name>
<node>
<name>Core-R1</name>
<isis>
<instance-name>1</instance-name>
<loopback>
<id>0</id>
<prefix-sid>
<absolute>16001</absolute>
</prefix-sid>
</loopback>
<flex-algo>
<name>128</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16801</absolute>
</algorithm-prefix-sid>
</flex-algo>
</isis>
</node>
<node>
<name>Core-R2</name>
<isis>
<instance-name>1</instance-name>
<loopback>
<id>0</id>
<prefix-sid>
<absolute>16002</absolute>
</prefix-sid>
</loopback>
<flex-algo>
<name>128</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16802</absolute>
</algorithm-prefix-sid>
</flex-algo>
</isis>
</node>
<node>
<name>Core-R3</name>
<isis>
<instance-name>1</instance-name>
<loopback>
<id>0</id>
<prefix-sid>
<absolute>16003</absolute>
</prefix-sid>
</loopback>
<flex-algo>
<name>129</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16903</absolute>
</algorithm-prefix-sid>
</flex-algo>
</isis>
</node>
<node>
<name>Core-R4</name>
<isis>
<instance-name>1</instance-name>
<loopback>
<id>0</id>
<prefix-sid>
<absolute>16004</absolute>
</prefix-sid>
</loopback>
<flex-algo>
<name>129</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16904</absolute>
</algorithm-prefix-sid>
</flex-algo>
</isis>
</node>
<node>
<name>PE-R5</name>
<isis>
<instance-name>1</instance-name>
<loopback>
<id>0</id>
<prefix-sid>
<absolute>16005</absolute>
</prefix-sid>
</loopback>
<flex-algo>
<name>128</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16805</absolute>
</algorithm-prefix-sid>
</flex-algo>
<flex-algo>
<name>129</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16905</absolute>
</algorithm-prefix-sid>
</flex-algo>
</isis>
</node>
<node>
<name>PE-R6</name>
<isis>
<instance-name>1</instance-name>
<loopback>
<id>0</id>
<prefix-sid>
<absolute>16006</absolute>
</prefix-sid>
</loopback>
<flex-algo>
<name>128</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16806</absolute>
</algorithm-prefix-sid>
</flex-algo>
<flex-algo>
<name>129</name>
<advertise-definition/>
<algorithm-prefix-sid>
<absolute>16906</absolute>
</algorithm-prefix-sid>
</flex-algo>
</isis>
</node>
</sr-setting>
</config>
2. Display the plan for the SR-Settings service and verify the service is deployed.
3. Get modifications for the SR-Settings service and verify the configuration is
pushed to the core and PE devices.
message devices {
device Core-R1 {
config {
cisco-ios-xr:router {
isis {
tag 1 {
+ flex-algo 128 {
+ advertise-definition;
+ }
interface Loopback0 {
address-family {
ipv4 {
unicast {
prefix-sid {
+ absolute 16001;
- index 1001;
}
}
}
}
}
}
}
}
}
}
}
devices {
device Core-R2 {
config {
cisco-ios-xr:router {
isis {
tag 1 {
+ flex-algo 128 {
+ advertise-definition;
+ }
interface Loopback0 {
address-family {
ipv4 {
unicast {
prefix-sid {
+ absolute 16002;
- index 2001;
}
}
}
}
}
}
}
}
}
}
}
devices {
device Core-R3 {
config {
cisco-ios-xr:router {
isis {
tag 1 {
+ flex-algo 129 {
+ advertise-definition;
+ }
interface Loopback0 {
address-family {
ipv4 {
unicast {
prefix-sid {
+ absolute 16003;
- index 3001;
}
}
}
}
}
}
}
}
}
}
}
devices {
device Core-R4 {
config {
cisco-ios-xr:router {
isis {
tag 1 {
+ flex-algo 129 {
+ advertise-definition;
+ }
interface Loopback0 {
address-family {
ipv4 {
unicast {
prefix-sid {
+ absolute 16004;
- index 4001;
}
}
}
}
}
}
}
}
}
}
}
devices {
device PE-R5 {
config {
cisco-ios-xr:router {
isis {
tag 1 {
+ flex-algo 128 {
+ advertise-definition;
+ }
+ flex-algo 129 {
+ advertise-definition;
+ }
interface Loopback0 {
address-family {
ipv4 {
unicast {
prefix-sid {
+ absolute 16005;
- index 5001;
}
}
}
}
}
}
}
}
}
}
}
devices {
device PE-R6 {
config {
cisco-ios-xr:router {
isis {
tag 1 {
+ flex-algo 128 {
+ advertise-definition;
+ }
+ flex-algo 129 {
+ advertise-definition;
+ }
interface Loopback0 {
address-family {
ipv4 {
unicast {
prefix-sid {
+ absolute 16006;
- index 6001;
}
}
}
}
}
}
}
}
}
}
}
4. Create and apply the SR-ODN template to assign color 20 the path 128
on PE-R5 and the path 129 on PE-R6.
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-te xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te">
<odn xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te-
sr-odn">
<odn-template>
<name>SR-Flex-Algo-PE-R5</name>
<head-end>
<name>PE-R5</name>
</head-end>
<color>20</color>
<dynamic>
<metric-type>igp</metric-type>
<flex-alg>128</flex-alg>
</dynamic>
</odn-template>
<odn-template>
<name>SR-Flex-Algo-PE-R6</name>
<head-end>
<name>PE-R6</name>
</head-end>
<color>20</color>
<dynamic>
<metric-type>igp</metric-type>
<flex-alg>129</flex-alg>
</dynamic>
</odn-template>
</odn>
</sr-te>
</config>
6. Get modifications for the SR ODN template and verify if the configuration is
pushed to devices PE-R5 and PE-R6.
admin@ncs# sr-te cisco-sr-te-cfp-sr-odn:odn odn-template SR-Flex-
Algo-PE-R5 action get-modifications
message devices {
device PE-R5 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
on-demand {
+ color 20 {
+ dynamic {
+ metric {
+ type igp;
+ }
+ sid-algorithm 128;
+ }
+ }
}
}
}
}
}
}
+ dynamic {
+ metric {
+ type igp;
+ }
+ sid-algorithm 129;
+ }
+ }
}
}
}
}
}
7. Create the L3VPN route policy for color 20 on devices PE-R5 and PE-R6. This
configuration data is deployed on the device when flat L3VPN service is
applied with this route policy.
<config xmlns="http://tail-f.com/ns/config/1.0">
<l3vpn-route-policy
xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-flat-L3vpn">
<name>L3-color-20-PE-R5</name>
<color>
<id>20</id>
<ipv4>
<prefix>122.122.122.1/32</prefix>
</ipv4>
</color>
</l3vpn-route-policy>
<l3vpn-route-policy
xmlns="http://cisco.com/ns/nso/fp/examples/cisco-tsdn-flat-L3vpn">
<name>L3-color-20-PE-R6</name>
<color>
<id>20</id>
<ipv4>
<prefix>123.123.123.1/32</prefix>
</ipv4>
</color>
</l3vpn-route-policy>
</config>
</e-bgp>
</ce-pe-prot>
<vrf>
<vrf-definition>L3VPN-T-SDN</vrf-definition>
<route-distinguisher>10:10</route-distinguisher>
<address-family>
<address-family>ipv4</address-family>
<redistribute-connected/>
<metric>2</metric>
<vpn-target>
<rt-value>110:110</rt-value>
<rt-type>both</rt-type>
</vpn-target>
</address-family>
</vrf>
<sr-te>
<route-policy>L3-color-20-PE-R5</route-policy>
</sr-te>
</endpoint>
<endpoint>
<endpoint-name>PE-R6</endpoint-name>
<access-pe>PE-R6</access-pe>
<if-type>Loopback</if-type>
<if-id>4</if-id>
<pe-ip-addr>123.123.123.1/24</pe-ip-addr>
<as-no>1</as-no>
<ce-pe-prot>
<e-bgp>
<neighbor-ipv4>123.123.123.2</neighbor-ipv4>
<remote-as-ipv4>65003</remote-as-ipv4>
<update-source>
<if-type>Loopback</if-type>
<if-id>4</if-id>
</update-source>
</e-bgp>
</ce-pe-prot>
<vrf>
<vrf-definition>L3VPN-T-SDN</vrf-definition>
<route-distinguisher>10:10</route-distinguisher>
<address-family>
<address-family>ipv4</address-family>
<redistribute-connected/>
<metric>2</metric>
<vpn-target>
<rt-value>110:110</rt-value>
<rt-type>both</rt-type>
</vpn-target>
</address-family>
</vrf>
<sr-te>
<route-policy>L3-color-20-PE-R6</route-policy>
</sr-te>
</endpoint>
</flat-L3vpn>
</config>
9. Associate the route policy to the L3VPN service on the devices PE-R5 and
PE-R6.
<config xmlns="http://tail-f.com/ns/config/1.0">
<flat-L3vpn xmlns="http://cisco.com/ns/nso/fp/examples/cisco-
tsdn-flat-L3vpn">
<name>L3VPN-TSDN</name>
<endpoint>
<endpoint-name>PE-R5</endpoint-name>
<sr-te>
<route-policy>L3-color-20-PE-R5</route-policy>
</sr-te>
</endpoint>
<endpoint>
<endpoint-name>PE-R6</endpoint-name>
<access-pe>PE-R6</access-pe>
<sr-te>
<route-policy>L3-color-20-PE-R6</route-policy>
</sr-te>
</endpoint>
</flat-L3vpn>
</config>
10. Verify the plan for L3VPN service. Make sure the services are ready reached
and type-self state-ready is in reached status.
11. Get modifications on the L3VPN service to verify the configuration is applied
on devices PE-R5 and PE-R6.
}
cisco-ios-xr:interface {
+ Loopback 4 {
+ description "T-SDN Interface";
+ vrf L3VPN-T-SDN;
+ ipv4 {
+ address {
+ ip 122.122.122.1;
+ mask 255.255.255.0;
+ }
+ }
+ }
}
cisco-ios-xr:extcommunity-set {
+ opaque COLOR_20 {
+ set 20;
+ }
}
+ cisco-ios-xr:route-policy PASS_ALL {
+ value pass;
+ }
+ cisco-ios-xr:route-policy SET_COLORv4_L3-color-20-PE-R5 {
+ value " if destination in (122.122.122.1/32)
then\r\n set extcommunity color COLOR_20\r\n endif\r\n";
+ }
cisco-ios-xr:router {
bgp {
bgp-no-instance 1 {
+ vrf L3VPN-T-SDN {
+ rd 10:10;
+ address-family {
+ ipv4 {
+ unicast {
+ redistribute {
+ connected {
+ metric 2;
+ }
+ }
+ }
+ }
+ }
+ neighbor 122.122.122.2 {
+ remote-as 65002;
+ update-source {
+ Loopback 4;
+ }
+ address-family {
+ ipv4 {
+ unicast {
+ route-policy in {
+ name PASS_ALL;
+ }
+ route-policy out {
+ name PASS_ALL;
+ }
+ }
+ }
+ }
+ }
+ }
}
}
}
}
}
}
devices {
device PE-R6 {
config {
cisco-ios-xr:vrf {
+ vrf-list L3VPN-T-SDN {
+ address-family {
+ ipv4 {
+ unicast {
+ import {
+ route-target {
+ address-list 110:110;
+ }
+ }
+ export {
+ route-policy SET_COLORv4_L3-
color-20-PE-R6;
+ route-target {
+ address-list 110:110;
+ }
+ }
+ }
+ }
+ }
+ }
}
cisco-ios-xr:interface {
+ Loopback 4 {
+ description "T-SDN Interface";
+ vrf L3VPN-T-SDN;
+ ipv4 {
+ address {
+ ip 123.123.123.1;
+ mask 255.255.255.0;
+ }
+ }
+ }
}
cisco-ios-xr:extcommunity-set {
+ opaque COLOR_20 {
+ set 20;
+ }
}
+ cisco-ios-xr:route-policy PASS_ALL {
+ value pass;
+ }
+ cisco-ios-xr:route-policy SET_COLORv4_L3-color-20-PE-R6 {
+ value " if destination in (123.123.123.1/32)
then\r\n set extcommunity color COLOR_20\r\n endif\r\n";
+ }
cisco-ios-xr:router {
bgp {
bgp-no-instance 1 {
+ vrf L3VPN-T-SDN {
+ rd 10:10;
+ address-family {
+ ipv4 {
+ unicast {
+ redistribute {
+ connected {
+ metric 2;
+ }
+ }
+ }
+ }
+ }
+ neighbor 123.123.123.2 {
+ remote-as 65003;
+ update-source {
+ Loopback 4;
+ }
+ address-family {
+ ipv4 {
+ unicast {
+ route-policy in {
+ name PASS_ALL;
+ }
+ route-policy out {
+ name PASS_ALL;
+ }
+ }
+ }
+ }
+ }
+ }
}
}
}
}
}
}
12. Perform self-test on L3VPN service to ensure the service is set up and both
the PE devices are able to ping on the loopback interfaces (Loopback-4)
created in L3VPN service.
admin@ncs# flat-L3vpn L3VPN-TSDN action self-test
status success
message [('PE-R6', 'PE-R5', 'success', 'Success rate is 100 percent
(5/5)'), ('PE-R5', 'PE-R6', 'success', 'Success rate is 100 percent
(5/5)')]
admin@ncs#
2. Display the plan for the policy and verify the policy status is reached.
3. Get modifications for the SR-TE policy and verify the configuration is pushed
to the devices.
admin@ncs#admin@ncs# sr-te cisco-sr-te-cfp-sr-policies:policies
policy sr-policy-color-40-PE-R5 action get-modifications outformat
cli
message devices {
device PE-R5 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
+ policy srte_c_40_ep_100.100.100.6 {
+ binding-sid {
+ mpls 40;
+ }
+ color {
+ value 40;
+ end-point {
+ ipv4 100.100.100.6;
+ }
+ }
+ candidate-paths {
+ preference 2 {
+ dynamic {
+ metric {
+ type latency;
+ }
+ }
+ }
+ }
+ }
}
}
}
}
}
cisco-ios-xr:segment-routing {
traffic-eng {
+ policy srte_c_40_ep_100.100.100.5 {
+ binding-sid {
+ mpls 40;
+ }
+ color {
+ value 40;
+ end-point {
+ ipv4 100.100.100.5;
+ }
+ }
+ candidate-paths {
+ preference 2 {
+ dynamic {
+ metric {
+ type latency;
+ }
+ }
+ }
+ }
+ }
}
}
}
}
}
<name>L2VPN-Service</name>
<service-type>p2p</service-type>
<flat-L2vpn-p2p>
<pw-id>100</pw-id>
<local-site>
<pe>PE-R5</pe>
<if-type>GigabitEthernet</if-type>
<if-id>0/0/0/2</if-id>
<if-description>L2vpn-p2p-flat-remote</if-description>
<if-encap>dot1q</if-encap>
<vlan-id>100</vlan-id>
<sub-if-id>100</sub-if-id>
<xconnect-group-name>TSDN-L2vpn</xconnect-group-name>
<xconnect-encapsulation>mpls</xconnect-encapsulation>
<p2p-name>p2p-flat</p2p-name>
<control-word>no</control-word>
<pw-class>TSDN-L2vpn-p2p</pw-class>
<xconnect-local-ip>100.100.100.5</xconnect-local-ip>
<xconnect-remote-ip>100.100.100.6</xconnect-remote-ip>
<mpls-local-label>101</mpls-local-label>
<mpls-remote-label>202</mpls-remote-label>
</local-site>
<remote-site>
<pe>PE-R6</pe>
<if-type>GigabitEthernet</if-type>
<if-id>0/0/0/1</if-id>
<if-description>L2vpn-p2p-flat-remote</if-description>
<if-encap>dot1q</if-encap>
<vlan-id>100</vlan-id>
<sub-if-id>100</sub-if-id>
<xconnect-group-name>TSDN-L2vpn</xconnect-group-name>
<p2p-name>p2p-flat</p2p-name>
<pw-class>TSDN-L2vpn-p2p</pw-class>
</remote-site>
</flat-L2vpn-p2p>
</flat-L2vpn>
</config>
7. Verify the plan status for L2VPN service and verify the service is successfully
deployed.
8. Get modifications for the L2VPN service verify the route policy is applied to
the devices.
admin@ncs# flat-L2vpn L2VPN-Service action get-modifications
message devices {
device PE-R5 {
config {
cisco-ios-xr:interface {
GigabitEthernet-subinterface {
+ GigabitEthernet 0/0/0/2.100 {
+ mode l2transport;
+ description L2vpn-p2p-flat-remote;
+ encapsulation {
+ dot1q {
+ vlan-id 100;
+ }
+ }
+ }
}
}
cisco-ios-xr:l2vpn {
+ pw-class TSDN-L2vpn-p2p {
+ encapsulation {
+ mpls {
+ preferred-path {
+ sr-te {
+ policy Local_RP-Color-40;
+ }
+ }
+ }
+ }
+ }
xconnect {
+ group TSDN-L2vpn {
+ p2p p2p-flat {
+ interface
GigabitEthernet0/0/0/2.100;
+ neighbor 100.100.100.6 100 {
+ ip-version ipv4;
+ mpls {
+ static {
+ label {
+ local 101;
+ remote 202;
+ }
+ }
+ }
+ pw-class TSDN-L2vpn-p2p;
+ }
+ }
+ }
}
}
}
}
}
devices {
device PE-R6 {
config {
cisco-ios-xr:interface {
GigabitEthernet-subinterface {
+ GigabitEthernet 0/0/0/1.100 {
+ mode l2transport;
+ description L2vpn-p2p-flat-remote;
+ encapsulation {
+ dot1q {
+ vlan-id 100;
+ }
+ }
+ }
}
}
+ cisco-ios-xr:l2vpn {
+ pw-class TSDN-L2vpn-p2p {
+ encapsulation {
+ mpls {
+ preferred-path {
+ sr-te {
+ policy Remote_RP-Color-40;
+ }
+ }
+ }
+ }
+ }
+ xconnect {
+ group TSDN-L2vpn {
+ p2p p2p-flat {
+ interface
GigabitEthernet0/0/0/1.100;
+ neighbor 100.100.100.5 100 {
+ ip-version ipv4;
+ mpls {
+ static {
+ label {
+ local 202;
+ remote 101;
+ }
+ }
+ }
+ pw-class TSDN-L2vpn-p2p;
+ }
+ }
+ }
+ }
+ }
}
}
}
9. Perform self-test on L2VPN service to ensure the service is set up on both the
PE devices.
admin@ncs# flat-L3vpn flat-L2vpn L2VPN-Service action self-test
status success
message local-site: success. remote-site: success
10. Verify the status of Segment Routing Traffic Engineering-Policy Admin and
Operational are up on both the devices. This indicates the successful
instantiation of L2VPN service over SR-TE for color 40.
On PE-R5
admin@ncs# devices device PE-R5 live-status exec show segment-routing
traffic-eng policy
result
Thu May 7 22:51:16.950 UTC
RP/0/RP0/CPU0:PE-R5#
On PE-R6
admin@ncs# devices device PE-R5 live-status exec show segment-routing
traffic-eng policy
The following graphic shows the required tasks you must perform for this use
case.
<threshold>12</threshold>
</backoff>
<segment-routing>
<strict-sid-only/>
<te-latency/>
</segment-routing>
</pce>
</node>
</sr-pce>
</config>
2. Display the plan for the SR-PCE service and verify the service is in the reached
status.
3. Get modifications for the SR-PCE service and verify the configuration is
pushed to the core-R2 device.
sr-pce PCE-Core-R2 action get-modifications outformat cli
message devices {
device Core-R2 {
config {
+ cisco-ios-xr:pce {
+ address {
+ ipv4 100.100.100.2;
+ }
+ disjoint-path {
+ }
+ timers {
+ reoptimization 600;
+ keepalive 20;
+ minimum-peer-keepalive 21;
+ }
+ state-sync {
+ ipv4 100.100.100.2;
+ }
+ backoff {
+ ratio 11;
+ difference 10;
+ threshold 12;
+ }
+ segment-routing {
+ strict-sid-only;
+ te-latency;
+ }
+ }
}
}
}
5. Display the plan for SR-Settings and verify the status is reached for all the
devices.
6. Get modifications for SR-Settings to verify the PCC settings is pushed to the
devices.
}
devices {
device Core-R4 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
pcc {
pce {
address {
ipv4 100.100.100.2 {
+ precedence 1;
}
}
}
}
}
}
}
}
}
devices {
device PE-R5 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
+ pcc {
+ pce {
+ address {
+ ipv4 100.100.100.2 {
+ precedence 1;
+ }
+ }
+ }
+ report-all;
+ }
}
}
}
}
}
devices {
device PE-R6 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
+ pcc {
+ pce {
+ address {
+ ipv4 100.100.100.2 {
+ precedence 1;
+ }
+ }
+ }
+ report-all;
+ }
}
}
}
}
}
7. Verify the PCE peer database to ensure PCC is enabled on all the devices in
the network.
admin@ncs# devices device Core-R2 live-status exec show pce ipv4
peer
result
Fri May 8 00:08:52.700 UTC
RP/0/RP0/CPU0:Core-R2#
admin@ncs#
8. Create the SR-policy with metric IGP for color 50 on the PE-R5 device.
<config xmlns="http://tail-f.com/ns/config/1.0">
<sr-te xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te">
<policies xmlns="http://cisco.com/ns/nso/cfp/cisco-tsdn-sr-te-
sr-policies">
<policy>
<name>SR-Policy-PCE</name>
<head-end>
<name>PE-R5</name>
</head-end>
<tail-end>100.100.100.6</tail-end>
<color>50</color>
<binding-sid>25601</binding-sid>
<path>
<preference>100</preference>
<dynamic>
<metric-type>igp</metric-type>
<pce/>
</dynamic>
</path>
</policy>
</policies>
</sr-te>
</config>
9. Display the plan status for the SR-TE policy and verify the policy is deployed.
successfully.
10. Get modifications for the SR-policy with PCE for color 50 to verify the policy is
enforced on the device PE-R5.
sr-te cisco-sr-te-cfp-sr-policies:policies policy SR-Policy-PCE action
get-modifications
message devices {
device PE-R5 {
config {
cisco-ios-xr:segment-routing {
traffic-eng {
+ policy srte_c_50_ep_100.100.100.6 {
+ binding-sid {
+ mpls 25601;
+ }
+ color {
+ value 50;
+ end-point {
+ ipv4 100.100.100.6;
+ }
+ }
+ candidate-paths {
+ preference 100 {
+ dynamic {
+ pcep {
+ }
+ metric {
+ type igp;
+ }
+ }
+ }
+ }
+ }
}
}
}
}
}
11. Verify the SR-TE policy operations. The status of Segment Routing Traffic
Engineering-Policy Admin and Operational must be up. This indicates the
successful instantiation of SR-PCE for color 50.
admin@ncs# devices device Core-R2 live-status exec show pce lsp detail
result
Fri May 8 00:11:26.400 UTC
----------------------
PCC 100.100.100.5:
RP/0/RP0/CPU0:Core-R2#
12. Verify the path computed by PCE for color 50 on the device PE-R5.
Candidate-paths:
Preference: 100 (configuration) (active)
Name: srte_c_50_ep_100.100.100.6
Requested BSID: 25601
PCC info:
Symbolic name: cfg_srte_c_50_ep_100.100.100.6_discr_100
PLSP-ID: 3
Dynamic (pce 100.100.100.2) (valid) ---------------> Learnt
by PCE
Metric Type: IGP, Path Accumulated Metric: 30
24003 [Adjacency-SID, 20.20.10.1 - 20.20.10.2]
24003 [Adjacency-SID, 20.20.10.13 - 20.20.10.14]
24005 [Adjacency-SID, 20.20.10.25 - 20.20.10.26]
Attributes:
Binding SID: 25601
Forward Class: 0
Steering BGP disabled: no
IPv6 caps enable: yes
RP/0/RP0/CPU0:PE-R5#
admin@ncs#