idnits 2.17.1 draft-ietf-spring-sr-yang-06.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** There are 10 instances of too long lines in the document, the longest one being 10 characters in excess of 72. ** The abstract seems to contain references ([RFC7950], [I-D.ietf-spring-segment-routing], [RFC6020]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 128 has weird spacing: '...terface if:...' == Line 133 has weird spacing: '...rw name str...' == Line 182 has weird spacing: '...r-bound uin...' == Line 183 has weird spacing: '...r-bound uin...' == Line 186 has weird spacing: '...r-bound uin...' == (3 more instances...) -- The document date (March 10, 2017) is 2604 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Unused Reference: 'I-D.ietf-isis-segment-routing-msd' is defined on line 1322, but no explicit reference was found in the text == Unused Reference: 'I-D.ietf-ospf-segment-routing-msd' is defined on line 1328, but no explicit reference was found in the text == Outdated reference: A later version (-19) exists of draft-ietf-isis-segment-routing-msd-02 == Outdated reference: A later version (-25) exists of draft-ietf-ospf-segment-routing-msd-02 == Outdated reference: A later version (-15) exists of draft-ietf-spring-segment-routing-11 Summary: 2 errors (**), 0 flaws (~~), 12 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 SPRING Working Group S. Litkowski 3 Internet-Draft Orange Business Service 4 Intended status: Standards Track Y. Qu 5 Expires: September 11, 2017 Huawei 6 P. Sarkar 7 J. Tantsura 8 Individual 9 March 10, 2017 11 YANG Data Model for Segment Routing 12 draft-ietf-spring-sr-yang-06 14 Abstract 16 This document defines a YANG data model ([RFC6020], [RFC7950]) for 17 segment routing ([I-D.ietf-spring-segment-routing]) configuration and 18 operation. This YANG model is intended to be used on network 19 elements to configure or operate segment routing. This document 20 defines also generic containers that SHOULD be reused by IGP protocol 21 modules to support segment routing. 23 Requirements Language 25 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 26 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 27 document are to be interpreted as described in [RFC2119]. 29 Status of This Memo 31 This Internet-Draft is submitted in full conformance with the 32 provisions of BCP 78 and BCP 79. 34 Internet-Drafts are working documents of the Internet Engineering 35 Task Force (IETF). Note that other groups may also distribute 36 working documents as Internet-Drafts. The list of current Internet- 37 Drafts is at http://datatracker.ietf.org/drafts/current/. 39 Internet-Drafts are draft documents valid for a maximum of six months 40 and may be updated, replaced, or obsoleted by other documents at any 41 time. It is inappropriate to use Internet-Drafts as reference 42 material or to cite them other than as "work in progress." 44 This Internet-Draft will expire on September 11, 2017. 46 Copyright Notice 48 Copyright (c) 2017 IETF Trust and the persons identified as the 49 document authors. All rights reserved. 51 This document is subject to BCP 78 and the IETF Trust's Legal 52 Provisions Relating to IETF Documents 53 (http://trustee.ietf.org/license-info) in effect on the date of 54 publication of this document. Please review these documents 55 carefully, as they describe your rights and restrictions with respect 56 to this document. Code Components extracted from this document must 57 include Simplified BSD License text as described in Section 4.e of 58 the Trust Legal Provisions and are provided without warranty as 59 described in the Simplified BSD License. 61 Table of Contents 63 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 64 1.1. Tree diagram . . . . . . . . . . . . . . . . . . . . . . 3 65 2. Design of the Data Model . . . . . . . . . . . . . . . . . . 3 66 3. Configuration . . . . . . . . . . . . . . . . . . . . . . . . 6 67 4. IGP Control plane configuration . . . . . . . . . . . . . . . 7 68 4.1. IGP interface configuration . . . . . . . . . . . . . . . 7 69 4.1.1. Adjacency SID properties . . . . . . . . . . . . . . 8 70 4.1.1.1. Bundling . . . . . . . . . . . . . . . . . . . . 8 71 4.1.1.2. Protection . . . . . . . . . . . . . . . . . . . 8 72 5. States . . . . . . . . . . . . . . . . . . . . . . . . . . . 9 73 6. Notifications . . . . . . . . . . . . . . . . . . . . . . . . 9 74 7. YANG Module . . . . . . . . . . . . . . . . . . . . . . . . . 9 75 8. Security Considerations . . . . . . . . . . . . . . . . . . . 28 76 9. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 28 77 10. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 28 78 11. Normative References . . . . . . . . . . . . . . . . . . . . 28 79 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 29 81 1. Introduction 83 This document defines a YANG data model for segment routing 84 configuration and operation. This document does not define the IGP 85 extensions to support segment routing but defines generic groupings 86 that SHOULD be reused by IGP extension modules. The reason of this 87 design choice is to not require implementations to support all IGP 88 extensions. For example, an implementation may support IS-IS 89 extension but not OSPF. 91 1.1. Tree diagram 93 A simplified graphical representation of the data model is presented 94 in Section 2. 96 The meaning of the symbols in these diagrams is as follows: 98 o Brackets "[" and "]" enclose list keys. 100 o Curly braces "{" and "}" contain names of optional features that 101 make the corresponding node conditional. 103 o Abbreviations before data node names: "rw" means configuration 104 (read-write), and "ro" state data (read-only). 106 o Symbols after data node names: "?" means an optional node and "*" 107 denotes a "list" or "leaf-list". 109 o Parentheses enclose choice and case nodes, and case nodes are also 110 marked with a colon (":"). 112 o Ellipsis ("...") stands for contents of subtrees that are not 113 shown. 115 2. Design of the Data Model 117 As the module definition is just starting, it is expected that there 118 will be changes as the module matures. 120 module: ietf-segment-routing 121 augment /rt:routing: 122 +--rw segment-routing 123 +--rw transport-type? identityref 124 +--rw msd {msd}? 125 | +--rw node-msd? uint8 126 | +--rw link-msd 127 | +--rw link-msds* [interface] 128 | +--rw interface if:interface-ref 129 | +--rw msd? uint8 130 +--rw bindings 131 | +--rw mapping-server {mapping-server}? 132 | | +--rw policy* [name] 133 | | +--rw name string 134 | | +--rw ipv4 135 | | | +--rw mapping-entry* [prefix algorithm] 136 | | | +--rw prefix inet:ipv4-prefix 137 | | | +--rw value-type? enumeration 138 | | | +--rw start-sid uint32 139 | | | +--rw range? uint32 140 | | | +--rw algorithm identityref 141 | | +--rw ipv6 142 | | +--rw mapping-entry* [prefix algorithm] 143 | | +--rw prefix inet:ipv6-prefix 144 | | +--rw value-type? enumeration 145 | | +--rw start-sid uint32 146 | | +--rw range? uint32 147 | | +--rw algorithm identityref 148 | +--rw connected-prefix-sid-map 149 | | +--rw ipv4 150 | | | +--rw ipv4-prefix-sid* [prefix algorithm] 151 | | | +--rw prefix inet:ipv4-prefix 152 | | | +--rw value-type? enumeration 153 | | | +--rw start-sid uint32 154 | | | +--rw range? uint32 155 | | | +--rw algorithm identityref 156 | | | +--rw last-hop-behavior? enumeration {sid-last-hop-behavior}? 157 | | +--rw ipv6 158 | | +--rw ipv6-prefix-sid* [prefix algorithm] 159 | | +--rw prefix inet:ipv6-prefix 160 | | +--rw value-type? enumeration 161 | | +--rw start-sid uint32 162 | | +--rw range? uint32 163 | | +--rw algorithm identityref 164 | | +--rw last-hop-behavior? enumeration {sid-last-hop-behavior}? 165 | +--rw local-prefix-sid 166 | +--rw ipv4 167 | | +--rw ipv4-prefix-sid-local* [prefix algorithm] 168 | | +--rw prefix inet:ipv4-prefix 169 | | +--rw value-type? enumeration 170 | | +--rw start-sid uint32 171 | | +--rw range? uint32 172 | | +--rw algorithm identityref 173 | +--rw ipv6 174 | +--rw ipv6-prefix-sid-local* [prefix algorithm] 175 | +--rw prefix inet:ipv6-prefix 176 | +--rw value-type? enumeration 177 | +--rw start-sid uint32 178 | +--rw range? uint32 179 | +--rw algorithm identityref 180 +--rw global-srgb 181 | +--rw srgb* [lower-bound upper-bound] 182 | +--rw lower-bound uint32 183 | +--rw upper-bound uint32 184 +--rw srlb 185 +--rw srlb* [lower-bound upper-bound] 186 +--rw lower-bound uint32 187 +--rw upper-bound uint32 188 augment /rt:routing-state: 189 +--ro segment-routing 190 +--ro node-capabilities 191 | +--ro transport-planes* [transport-plane] 192 | | +--ro transport-plane identityref 193 | +--ro readable-label-stack-depth? uint8 194 +--ro msd 195 | +--ro node-msd? uint8 196 | +--ro link-msd 197 | +--ro link-msds* [interface] 198 | +--ro interface if:interface-ref 199 | +--ro msd? uint8 200 +--ro label-blocks* 201 | +--ro lower-bound? uint32 202 | +--ro upper-bound? uint32 203 | +--ro size? uint32 204 | +--ro free? uint32 205 | +--ro used? uint32 206 | +--ro scope? enumeration 207 +--ro sid-list 208 +--ro sid* [target sid source source-protocol binding-type] 209 +--ro target string 210 +--ro sid uint32 211 +--ro algorithm? uint8 212 +--ro source inet:ip-address 213 +--ro used? boolean 214 +--ro source-protocol -> /rt:routing-state/control-plane-protocols 215 /control-plane-protocol/name 216 +--ro binding-type enumeration 217 +--ro scope? enumeration 219 notifications: 220 +---n segment-routing-global-srgb-collision 221 | +--ro srgb-collisions* 222 | +--ro lower-bound? uint32 223 | +--ro upper-bound? uint32 224 | +--ro routing-protocol? -> /rt:routing-state/control-plane-protocols 225 | /control-plane-protocol/name 226 | +--ro originating-rtr-id? router-id 227 +---n segment-routing-global-sid-collision 228 | +--ro received-target? string 229 | +--ro new-sid-rtr-id? router-id 230 | +--ro original-target? string 231 | +--ro original-sid-rtr-id? router-id 232 | +--ro index? uint32 233 | +--ro routing-protocol? -> /rt:routing-state/control-plane-protocols 234 | /control-plane-protocol/name 235 +---n segment-routing-index-out-of-range 236 +--ro received-target? string 237 +--ro received-index? uint32 238 +--ro routing-protocol? -> /rt:routing-state/control-plane-protocols 239 /control-plane-protocol/name 240 notifications: 241 +---n segment-routing-global-srgb-collision 242 | +--ro srgb-collisions* 243 | +--ro lower-bound? uint32 244 | +--ro upper-bound? uint32 245 | +--ro routing-protocol? -> /rt:routing-state/control-plane-protocols 246 | /control-plane-protocol/name 247 | +--ro originating-rtr-id? router-id 248 +---n segment-routing-global-sid-collision 249 | +--ro received-target? string 250 | +--ro new-sid-rtr-id? router-id 251 | +--ro original-target? string 252 | +--ro original-sid-rtr-id? router-id 253 | +--ro index? uint32 254 | +--ro routing-protocol? -> /rt:routing-state/control-plane-protocols 255 | /control-plane-protocol/name 256 +---n segment-routing-index-out-of-range 257 +--ro received-target? string 258 +--ro received-index? uint32 259 +--ro routing-protocol? -> /rt:routing-state/control-plane-protocols 260 /control-plane-protocol/name 262 3. Configuration 264 This module augments the "/rt:routing:" with a segment-routing 265 container. This container defines all the configuration parameters 266 related to segment-routing. 268 The segment-routing configuration is split in global configuration 269 and interface configuration. 271 The global configuration includes : 273 o segment-routing transport type : The underlying transport type for 274 segment routing. The version of the model limits the transport 275 type to an MPLS dataplane. The transport-type is only defined 276 once for a particular routing-instance and is agnostic to the 277 control plane used. Only a single transport-type is supported in 278 this version of the model. 280 o bindings : Defines prefix to SID mappings. The operator can 281 control advertisement of Prefix-SID independently for IPv4 and 282 IPv6. Two types of mappings are available : 284 * Mapping-server : maps non local prefixes to a segment ID. 285 Configuration of bindings does not automatically allow 286 advertisement of those bindings. Advertisement must be 287 controlled by each routing-protocol instance (see Section 4). 288 Multiple mapping policies may be defined. 290 * Connected prefixes : maps connected prefixes to a segment ID. 291 Advertisement of the mapping will be done by IGP when enabled 292 for segment routing (see Section 4). The SID value can be 293 expressed as an index (default), or an absolute value. The 294 "last-hop-behavior" configuration dictates the PHP behavior: 295 "explicit-null", "php", or "non-php". 297 o SRGB (Segment Routing Global Block): Defines a list of label 298 blocks represented by a pair of lower-bound/upper-bound labels. 299 The SRGB is also agnostic to the control plane used. So all 300 routing-protocol instance will have to advertise the same SRGB. 302 o SRLB (Segment Routing Local Block): Defines a list of label blocks 303 represented by a pair of lower-bound/upper-bound labels, reserved 304 for lcoal SIDs. 306 4. IGP Control plane configuration 308 Support of segment-routing extensions for a particular IGP control 309 plane is done by augmenting routing-protocol configuration with 310 segment-routing extensions. This augmentation SHOULD be part of 311 separate YANG modules in order to not create any dependency for 312 implementations to support all protocol extensions. 314 This module defines groupings that SHOULD be used by IGP segment 315 routing modules. 317 The "controlplane-cfg" grouping defines the generic global 318 configuration for the IGP. 320 The "enabled" leaf enables segment-routing extensions for the 321 routing-protocol instance. 323 The "bindings" container controls the routing-protocol instance's 324 advertisement of local bindings and the processing of received 325 bindings. 327 4.1. IGP interface configuration 329 The interface configuration is part of the "igp-interface-cfg" 330 grouping and includes Adjacency SID properties. 332 4.1.1. Adjacency SID properties 334 4.1.1.1. Bundling 336 This section is a first proposal on how to use S-bit in Adj-SID to 337 create bundles. Authors would like to trigger discussion based on 338 this first proposal. 340 In case of parallel IP links between routers, an additional Adjacency 341 SID may be advertised representing more than one adjacency (i.e., a 342 bundle of adjacencies). The "advertise-adj-group-sid" configuration 343 controls whether or not an additional adjacency SID is advertised. 345 The "advertise-adj-group-sid" would be a list of "group-id". The 346 "group-id" will permit to identify interfaces that must be bundled 347 together. 349 +-------+ +------+ 350 | | ------- L1 ---- | | 351 | R1 | ------- L2 ---- | R2 | 352 | | ------- L3 ---- | | 353 | | ------- L4 ---- | | 354 +-------+ +------+ 356 In the figure above, R1 and R2 are interconnected by four links. A 357 routing protocol adjacency is established on each link. Operator 358 would like to create segment-routing Adj-SID that represent some 359 bundles of links. We can imagine two different bundles : L1/L2 and 360 L2/L3. To achieve this behavior, the service provider will configure 361 a "group-id" X for both interfaces L1 and L2 and a "group-id" Y for 362 both interfaces L3 and L3. This will result in R1 advertising an 363 additional Adj-SID for each adjacency, for example a Adj-SID with S 364 flag set and value of 400 will be added to L1 and L2. A Adj-SID with 365 S flag set and value of 500 will be added to L3 and L4. As L1/L2 and 366 L3/L4 does not share the same "group-id", a different SID value will 367 be allocated. 369 4.1.1.2. Protection 371 The "advertise-protection" defines how protection for an interface is 372 advertised. It does not control the activation or deactivation of 373 protection. If the "single" option is used, a single Adj-SID will be 374 advertised for the interface. If the interface is protected, the 375 B-Flag for the Adj-SID advertisement will be set. If the "dual" 376 option is used and if the interface is protected, two Adj-SIDs will 377 be advertised for the interface adjacencies. One Adj-SID will always 378 have the B-Flag set and the other will have the B-Flag clear. This 379 option is intended to be used in the case of traffic engineering 380 where a path must use either protected segments or non-protected 381 segments. 383 5. States 385 The operational states contains information reflecting the usage of 386 allocated SRGB labels. 388 It also includes a list of all global SIDs, their associated 389 bindings, and other information such as the source protocol and 390 algorithm. 392 6. Notifications 394 The model defines the following notifications for segment-routing. 396 o segment-routing-global-srgb-collision: Rasied when a control plan 397 advertised SRGB blocks have conflicts. 399 o segment-routing-global-sid-collision: Raised when a control plane 400 advertised index is already associated with another target (in 401 this version, the only defined targets are IPv4 and IPv6 402 prefixes). 404 o segment-routing-index-out-of-range: Raised when a control plane 405 advertised index fall outside the range of SRGBs configured for 406 the network device. 408 7. YANG Module 410 file "ietf-segment-routing-common@2017-03-10.yang" 411 module ietf-segment-routing-common { 412 namespace "urn:ietf:params:xml:ns:yang:ietf-segment-routing-common"; 413 prefix sr-cmn; 415 import ietf-inet-types { 416 prefix inet; 417 } 419 organization 420 "IETF SPRING Working Group"; 421 contact 422 "WG List: 424 Editor: Stephane Litkowski 425 427 Author: Acee Lindem 428 429 Author: Yingzhen Qu 430 431 Author: Pushpasis Sarkar 432 433 Author: Jeff Tantsura 434 436 "; 437 description 438 "The YANG module defines a collection of types and groupings for 439 Segment routing."; 441 revision 2017-03-10 { 442 description 443 " 444 * Add support of SRLB 445 "; 446 reference "RFC XXXX: YANG Data Model for Segment Routing."; 447 } 448 revision 2016-10-28 { 449 description 450 " 451 * Add support of MSD (Maximum SID Depth) 452 * Update contact info 453 "; 454 reference "RFC XXXX: YANG Data Model for Segment Routing."; 455 } 456 revision 2016-10-24 { 457 description 458 "Initial"; 459 reference "RFC XXXX: YANG Data Model for Segment Routing."; 460 } 462 feature sid-last-hop-behavior { 463 description 464 "Configurable last hop behavior."; 465 } 467 identity segment-routing-transport { 468 description 469 "Base identity for segment routing transport."; 470 } 472 identity segment-routing-transport-mpls { 473 base segment-routing-transport; 474 description 475 "This identity represents MPLS transport for segment 476 routing."; 477 } 479 identity prefix-sid-algorithm { 480 description 481 "Base identity for prefix-sid algorithm."; 482 } 484 identity prefix-sid-algorithm-shortest-path { 485 base prefix-sid-algorithm; 486 description 487 "The default behavior of prefix-sid algorithm."; 488 } 490 identity prefix-sid-algorithm-strict-spf { 491 base prefix-sid-algorithm; 492 description 493 "This algorithm mandates that the packet is forwared 494 according to ECMP-aware SPF algorithm."; 495 } 497 grouping srlr { 498 description 499 "Grouping for SR Label Range configuration."; 500 leaf lower-bound { 501 type uint32; 502 description 503 "Lower value in the block."; 504 } 505 leaf upper-bound { 506 type uint32; 507 description 508 "Upper value in the block."; 509 } 510 } 512 grouping srgb-cfg { 513 description 514 "Grouping for SR Label Range configuration."; 515 list srgb { 516 key "lower-bound upper-bound"; 517 ordered-by user; 518 description 519 "List of global blocks to be 520 advertised."; 521 uses srlr; 522 } 524 } 526 grouping srlb-cfg { 527 description 528 "Grouping for SR Local Block range configuration."; 529 list srlb { 530 key "lower-bound upper-bound"; 531 ordered-by user; 532 description 533 "List of SRLBs."; 534 uses srlr; 535 } 536 } 538 grouping sid-value-type { 539 description 540 "Defines how the SID value is expressed."; 541 leaf value-type { 542 type enumeration { 543 enum "index" { 544 description 545 "The value will be 546 interpreted as an index."; 547 } 548 enum "absolute" { 549 description 550 "The value will become 551 interpreted as an absolute 552 value."; 553 } 554 } 555 default "index"; 556 description 557 "This leaf defines how value 558 must be interpreted."; 559 } 560 } 562 grouping ipv4-sid-cfg { 563 description 564 "This grouping defines cfg of prefix SID."; 565 leaf prefix { 566 type inet:ipv4-prefix; 567 description 568 "connected prefix sid."; 569 } 570 uses prefix-sid-attributes; 571 } 572 grouping ipv6-sid-cfg { 573 description 574 "This grouping defines cfg of prefix SID."; 575 leaf prefix { 576 type inet:ipv6-prefix; 577 description 578 "connected prefix sid."; 579 } 580 uses prefix-sid-attributes; 581 } 583 grouping last-hop-behavior { 584 description 585 "Defines last hop behavior"; 586 leaf last-hop-behavior { 587 if-feature "sid-last-hop-behavior"; 588 type enumeration { 589 enum "explicit-null" { 590 description 591 "Use explicit-null for the SID."; 592 } 593 enum "no-php" { 594 description 595 "Do no use PHP for the SID."; 596 } 597 enum "php" { 598 description 599 "Use PHP for the SID."; 600 } 601 } 602 description 603 "Configure last hop behavior."; 604 } 605 } 607 grouping node-capabilities { 608 description 609 "Containing SR node capabilities."; 610 container node-capabilities { 611 description 612 "Shows the SR capability of the node."; 613 list transport-planes { 614 key "transport-plane"; 615 description 616 "List of supported transport planes."; 617 leaf transport-plane { 618 type identityref { 619 base segment-routing-transport; 621 } 622 description 623 "Transport plane supported"; 624 } 625 } 626 leaf readable-label-stack-depth { 627 type uint8; 628 description 629 "Number of MPLS labels that 630 can be read in the stack."; 631 } 632 } 633 } 635 grouping prefix-sid-attributes { 636 description 637 "Containing SR attributes for a prefix."; 638 uses sid-value-type; 639 leaf start-sid { 640 type uint32; 641 mandatory true; 642 description 643 "Value associated with 644 prefix. The value must 645 be interpreted in the 646 context of value-type."; 647 } 648 leaf range { 649 type uint32; 650 description 651 "Describes how many SIDs could be 652 allocated."; 653 } 654 leaf algorithm { 655 type identityref { 656 base prefix-sid-algorithm; 657 } 658 description 659 "Prefix-sid algorithm."; 660 } 661 } 662 } 663 664 file "ietf-segment-routing@2017-03-10.yang" 665 module ietf-segment-routing { 666 namespace "urn:ietf:params:xml:ns:yang:ietf-segment-routing"; 667 prefix sr; 668 import ietf-inet-types { 669 prefix inet; 670 } 671 import ietf-yang-types { 672 prefix yang; 673 } 674 import ietf-routing { 675 prefix rt; 676 } 677 import ietf-interfaces { 678 prefix if; 679 } 680 import ietf-segment-routing-common { 681 prefix sr-cmn; 682 } 684 organization 685 "IETF SPRING Working Group"; 686 contact 687 "WG List: 689 Editor: Stephane Litkowski 690 692 Author: Acee Lindem 693 694 Author: Yingzhen Qu 695 696 Author: Pushpasis Sarkar 697 698 Author: Jeff Tantsura 699 701 "; 702 description 703 "The YANG module defines a generic configuration model for 704 Segment routing common across all of the vendor 705 implementations."; 707 revision 2017-03-10 { 708 description 709 " 710 * Change global-sid-list to sid-list and add a leaf scope 711 * Added support of SRLB 712 * Added support of local sids 713 * fixed indentations 714 "; 715 reference "RFC XXXX: YANG Data Model for Segment Routing."; 717 } 718 revision 2016-10-28 { 719 description 720 " 721 * Add support of MSD (Maximum SID Depth) 722 * Update contact info 723 "; 724 reference "RFC XXXX: YANG Data Model for Segment Routing."; 725 } 726 revision 2016-10-24 { 727 description 728 " 729 * Moved common SR types and groupings to a seperate module 730 "; 731 reference "RFC XXXX: YANG Data Model for Segment Routing."; 732 } 733 revision 2016-07-07 { 734 description 735 " 736 * Add support of prefix-sid algorithm configuration 737 * change routing-protocols to control-plane-protocols 738 "; 739 reference "RFC XXXX: YANG Data Model for Segment Routing."; 740 } 741 revision 2016-03-17 { 742 description 743 " 744 * Add notification segment-routing-global-srgb-collision 745 * Add router-id to segment-routing-global-sid-collision 746 * Remove routing-instance 747 * Add typedef router-id 748 "; 749 reference "RFC XXXX: YANG Data Model for Segment Routing."; 750 } 751 revision 2015-10-17 { 752 description 753 " 754 * Add per-protocol SRGB config feature 755 * Move SRBG config to a grouping 756 "; 757 reference "RFC XXXX: YANG Data Model for Segment Routing."; 758 } 759 revision 2015-06-22 { 760 description 761 " 762 * Prefix SID config moved to 763 connected-prefix-sid-map in global SR cfg 764 rather than IGP. 766 "; 767 reference "draft-litkowski-spring-sr-yang-01"; 768 } 769 revision 2015-04-23 { 770 description 771 " 772 * Node flag deprecated from prefixSID 773 * SR interface cfg moved to protocol 774 * Adding multiple binding policies for SRMS 775 "; 776 reference ""; 777 } 778 revision 2015-02-27 { 779 description 780 "Initial"; 781 reference "draft-litkowski-spring-sr-yang-00"; 782 } 784 feature mapping-server { 785 description 786 "Support of SRMS."; 787 } 789 feature protocol-srgb { 790 description 791 "Support per-protocol srgb configuration."; 792 } 794 feature msd { 795 description 796 "Support of signaling MSD (Maximum SID Depth) in IGP."; 797 } 799 typedef system-id { 800 type string { 801 pattern "[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.[0-9A-Fa-f]{4}\\.00"; 802 } 803 description 804 "This type defines ISIS system id using pattern, 805 system id looks like : 0143.0438.AeF0.00"; 806 } 808 typedef router-id { 809 type union { 810 type system-id; 811 type yang:dotted-quad; 812 } 813 description 814 "OSPF/BGP router id or ISIS system ID."; 815 } 817 grouping controlplane-cfg { 818 description 819 "Defines protocol configuration."; 820 container segment-routing { 821 description 822 "segment routing global config."; 823 leaf enabled { 824 type boolean; 825 default "false"; 826 description 827 "Enables segment-routing 828 protocol extensions."; 829 } 830 container bindings { 831 description 832 "Control of binding advertisement 833 and reception."; 834 container advertise { 835 description 836 "Authorize the advertise 837 of local mappings in binding TLV."; 838 leaf-list policies { 839 type string; 840 description 841 "List of policies to be advertised."; 842 } 843 } 844 leaf receive { 845 type boolean; 846 default "true"; 847 description 848 "Authorize the reception and usage 849 of binding TLV."; 850 } 851 } 852 } 853 } 855 grouping igp-interface-cfg { 856 description 857 "Grouping for IGP interface cfg."; 858 container segment-routing { 859 description 860 "container for SR interface cfg."; 861 container adjacency-sid { 862 description 863 "Defines the adjacency SID properties."; 864 list advertise-adj-group-sid { 865 key "group-id"; 866 description 867 "Control advertisement of S flag. 868 Enable to advertise a common Adj-SID 869 for parallel links."; 870 leaf group-id { 871 type uint32; 872 description 873 "The value is an internal value to identify 874 a group-ID. Interfaces with the same 875 group-ID will be bundled together."; 876 } 877 } 878 leaf advertise-protection { 879 type enumeration { 880 enum "single" { 881 description 882 "A single Adj-SID is associated 883 with the adjacency and reflects 884 the protection configuration."; 885 } 886 enum "dual" { 887 description 888 "Two Adj-SIDs will be associated 889 with the adjacency if interface 890 is protected. In this case 891 one will be enforced with 892 backup flag set, the other 893 will be enforced to backup flag unset. 894 In case, protection is not configured, 895 a single Adj-SID will be advertised 896 with backup flag unset."; 897 } 898 } 899 description 900 "If set, the Adj-SID refers to an 901 adjacency being protected."; 902 } 903 } 904 } 905 } 907 grouping msd-cfg { 908 description 909 "MSD configuration grouping."; 911 leaf node-msd { 912 type uint8; 913 description 914 "Node MSD is the lowest MSD supported by the node."; 915 } 916 container link-msd { 917 description 918 "Link MSD is a number represetns the particular link MSD value."; 919 list link-msds { 920 key "interface"; 921 description 922 "List of link MSDs."; 923 leaf interface { 924 type if:interface-ref; 925 description 926 "Name of the interface."; 927 } 928 leaf msd { 929 type uint8; 930 description 931 "SID depth of the interface associated with the link."; 932 } 933 } 934 } 935 } 937 notification segment-routing-global-srgb-collision { 938 description 939 "This notification is sent when received SRGB blocks from 940 a router conflict."; 941 list srgb-collisions { 942 description 943 "List of SRGB blocks that conflict."; 944 leaf lower-bound { 945 type uint32; 946 description 947 "Lower value in the block."; 948 } 949 leaf upper-bound { 950 type uint32; 951 description 952 "Upper value in the block."; 953 } 954 leaf routing-protocol { 955 type leafref { 956 path "/rt:routing-state/rt:control-plane-protocols/" 957 + "rt:control-plane-protocol/rt:name"; 958 } 959 description 960 "Routing protocol reference that received the event."; 961 } 962 leaf originating-rtr-id { 963 type router-id; 964 description 965 "Originating router id of this SRGB block."; 966 } 967 } 968 } 969 notification segment-routing-global-sid-collision { 970 description 971 "This notification is sent when a new mapping is learned 972 , containing mapping 973 where the SID is already used. 974 The notification generation must be throttled with at least 975 a 5 second gap. "; 976 leaf received-target { 977 type string; 978 description 979 "Target received in the controlplane that 980 caused SID collision."; 981 } 982 leaf new-sid-rtr-id { 983 type router-id; 984 description 985 "Router Id that advertising the conflicting SID."; 986 } 987 leaf original-target { 988 type string; 989 description 990 "Target already available in database that have the same SID 991 as the received target."; 992 } 993 leaf original-sid-rtr-id { 994 type router-id; 995 description 996 "Original router ID that advertised the conflicting SID."; 997 } 998 leaf index { 999 type uint32; 1000 description 1001 "Value of the index used by two different prefixes."; 1002 } 1003 leaf routing-protocol { 1004 type leafref { 1005 path "/rt:routing-state/rt:control-plane-protocols/" 1006 + "rt:control-plane-protocol/rt:name"; 1008 } 1009 description 1010 "Routing protocol reference that received the event."; 1011 } 1012 } 1013 notification segment-routing-index-out-of-range { 1014 description 1015 "This notification is sent when a binding 1016 is received, containing a segment index 1017 which is out of the local configured ranges. 1018 The notification generation must be throttled with at least 1019 a 5 second gap. "; 1020 leaf received-target { 1021 type string; 1022 description 1023 "Target received in the controlplane 1024 that caused SID collision."; 1025 } 1026 leaf received-index { 1027 type uint32; 1028 description 1029 "Value of the index received."; 1030 } 1031 leaf routing-protocol { 1032 type leafref { 1033 path "/rt:routing-state/rt:control-plane-protocols/" 1034 + "rt:control-plane-protocol/rt:name"; 1035 } 1036 description 1037 "Routing protocol reference that received the event."; 1038 } 1039 } 1040 augment "/rt:routing" { 1041 description 1042 "This augments routing-instance 1043 configuration with segment-routing."; 1044 container segment-routing { 1045 description 1046 "segment routing global config."; 1047 leaf transport-type { 1048 type identityref { 1049 base sr-cmn:segment-routing-transport; 1050 } 1051 default "sr-cmn:segment-routing-transport-mpls"; 1052 description 1053 "Dataplane to be used."; 1054 } 1055 container msd { 1056 if-feature "msd"; 1057 description 1058 "MSD configuration."; 1059 uses msd-cfg; 1060 } 1061 container bindings { 1062 description 1063 "List of bindings."; 1064 container mapping-server { 1065 if-feature "mapping-server"; 1066 description 1067 "Configuration of mapping-server 1068 local entries."; 1069 list policy { 1070 key "name"; 1071 description 1072 "Definition of mapping policy."; 1073 leaf name { 1074 type string; 1075 description 1076 "Name of the mapping policy."; 1077 } 1078 container ipv4 { 1079 description 1080 "IPv4 mapping entries."; 1081 list mapping-entry { 1082 key "prefix algorithm"; 1083 description 1084 "Mapping entries."; 1085 uses sr-cmn:ipv4-sid-cfg; 1086 } 1087 } 1088 container ipv6 { 1089 description 1090 "IPv6 mapping entries."; 1091 list mapping-entry { 1092 key "prefix algorithm"; 1093 description 1094 "Mapping entries."; 1095 uses sr-cmn:ipv6-sid-cfg; 1096 } 1097 } 1098 } 1099 } 1100 container connected-prefix-sid-map { 1101 description 1102 "Prefix SID configuration."; 1103 container ipv4 { 1104 description 1105 "Parameters associated with IPv4 prefix SID"; 1106 list ipv4-prefix-sid { 1107 key "prefix algorithm"; 1108 description 1109 "List of prefix SID 1110 mapped to IPv4 local prefixes."; 1111 uses sr-cmn:ipv4-sid-cfg; 1112 uses sr-cmn:last-hop-behavior; 1113 } 1114 } 1115 container ipv6 { 1116 description 1117 "Parameters associated with IPv6 prefix SID"; 1118 list ipv6-prefix-sid { 1119 key "prefix algorithm"; 1120 description 1121 "List of prefix SID 1122 mapped to IPv6 local prefixes."; 1123 uses sr-cmn:ipv6-sid-cfg; 1124 uses sr-cmn:last-hop-behavior; 1125 } 1126 } 1127 } 1128 container local-prefix-sid { 1129 description 1130 "Local sid configuration."; 1131 container ipv4 { 1132 description 1133 "List of local ipv4 sids."; 1134 list ipv4-prefix-sid-local { 1135 key "prefix algorithm"; 1136 description 1137 "List of local prefix-sid."; 1138 uses sr-cmn:ipv4-sid-cfg; 1139 } 1140 } 1141 container ipv6 { 1142 description 1143 "List of local ipv6 sids."; 1144 list ipv6-prefix-sid-local { 1145 key "prefix algorithm"; 1146 description 1147 "List of local prefix-sid."; 1148 uses sr-cmn:ipv6-sid-cfg; 1149 } 1150 } 1151 } 1153 } 1154 container global-srgb { 1155 description 1156 "Global SRGB configuration."; 1157 uses sr-cmn:srgb-cfg; 1158 } 1159 container srlb { 1160 description 1161 "SR Local Block configuration."; 1162 uses sr-cmn:srlb-cfg; 1163 } 1164 } 1165 } 1166 augment "/rt:routing-state" { 1167 description 1168 "This augments the operational states 1169 with segment-routing."; 1170 container segment-routing { 1171 description 1172 "Segment routing operational states."; 1173 uses sr-cmn:node-capabilities; 1174 container msd { 1175 description 1176 "MSD configuration state."; 1177 uses msd-cfg; 1178 } 1179 list label-blocks { 1180 description 1181 "List of labels blocks currently 1182 in use."; 1183 leaf lower-bound { 1184 type uint32; 1185 description 1186 "Lower bound of the label block."; 1187 } 1188 leaf upper-bound { 1189 type uint32; 1190 description 1191 "Upper bound of the label block."; 1192 } 1193 leaf size { 1194 type uint32; 1195 description 1196 "Number of indexes in the block."; 1197 } 1198 leaf free { 1199 type uint32; 1200 description 1201 "Number of indexes free in the block."; 1202 } 1203 leaf used { 1204 type uint32; 1205 description 1206 "Number of indexes used in the block."; 1207 } 1208 leaf scope { 1209 type enumeration { 1210 enum "global" { 1211 description 1212 "Global sid."; 1213 } 1214 enum "local" { 1215 description 1216 "Local sid."; 1217 } 1218 } 1219 description 1220 "Scope of this label block."; 1221 } 1222 } 1223 container sid-list { 1224 description 1225 "List of prefix and SID associations."; 1226 list sid { 1227 key "target sid source source-protocol binding-type"; 1228 ordered-by system; 1229 description 1230 "Binding."; 1231 leaf target { 1232 type string; 1233 description 1234 "Defines the target of the binding. 1235 It can be a prefix or something else."; 1236 } 1237 leaf sid { 1238 type uint32; 1239 description 1240 "Index associated with the prefix."; 1241 } 1242 leaf algorithm { 1243 type uint8; 1244 description 1245 "Algorithm to be used for the prefix 1246 SID."; 1247 } 1248 leaf source { 1249 type inet:ip-address; 1250 description 1251 "IP address of the router than own 1252 the binding."; 1253 } 1254 leaf used { 1255 type boolean; 1256 description 1257 "Defines if the binding is used 1258 in forwarding plane."; 1259 } 1260 leaf source-protocol { 1261 type leafref { 1262 path "/rt:routing-state/rt:control-plane-protocols/" 1263 + "rt:control-plane-protocol/rt:name"; 1264 } 1265 description 1266 "Rtg protocol that owns the binding"; 1267 } 1268 leaf binding-type { 1269 type enumeration { 1270 enum "prefix-sid" { 1271 description 1272 "Binding is learned from 1273 a prefix SID."; 1274 } 1275 enum "binding-tlv" { 1276 description 1277 "Binding is learned from 1278 a binding TLV."; 1279 } 1280 } 1281 description 1282 "Type of binding."; 1283 } 1284 leaf scope { 1285 type enumeration { 1286 enum "global" { 1287 description 1288 "Global sid."; 1289 } 1290 enum "local" { 1291 description 1292 "Local sid."; 1293 } 1294 } 1295 description 1296 "The sid is local or global."; 1298 } 1299 } 1300 } 1301 } 1302 } 1303 } 1304 1306 8. Security Considerations 1308 TBD. 1310 9. Acknowledgements 1312 Authors would like to thank Derek Yeung, Acee Lindem, Greg Hankins, 1313 Hannes Gredler, Uma Chunduri, Jeffrey Zhang, Shradda Hedge, Les 1314 Ginsberg for their contributions. 1316 10. IANA Considerations 1318 TBD. 1320 11. Normative References 1322 [I-D.ietf-isis-segment-routing-msd] 1323 Tantsura, J., Chunduri, U., Aldrin, S., and L. Ginsberg, 1324 "Signaling MSD (Maximum SID Depth) using IS-IS", draft- 1325 ietf-isis-segment-routing-msd-02 (work in progress), March 1326 2017. 1328 [I-D.ietf-ospf-segment-routing-msd] 1329 Tantsura, J., Chunduri, U., Aldrin, S., and P. Psenak, 1330 "Signaling MSD (Maximum SID Depth) using OSPF", draft- 1331 ietf-ospf-segment-routing-msd-02 (work in progress), March 1332 2017. 1334 [I-D.ietf-spring-segment-routing] 1335 Filsfils, C., Previdi, S., Decraene, B., Litkowski, S., 1336 and R. Shakir, "Segment Routing Architecture", draft-ietf- 1337 spring-segment-routing-11 (work in progress), February 1338 2017. 1340 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 1341 Requirement Levels", BCP 14, RFC 2119, March 1997. 1343 [RFC6020] Bjorklund, M., "YANG - A Data Modeling Language for the 1344 Network Configuration Protocol (NETCONF)", RFC 6020, 1345 October 2010. 1347 [RFC7950] Bjorklund, M., "The YANG 1.1 Data Modeling Language", 1348 RFC 7950, August 2016. 1350 Authors' Addresses 1352 Stephane Litkowski 1353 Orange Business Service 1355 Email: stephane.litkowski@orange.com 1357 Yingzhen Qu 1358 Huawei 1360 Email: yingzhen.qu@huawei.com 1362 Pushpasis Sarkar 1363 Individual 1365 Email: pushpasis.ietf@gmail.com 1367 Jeff Tantsura 1368 Individual 1370 Email: jefftant.ietf@gmail.com