idnits 2.17.1 draft-ietf-bfd-yang-12.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 : ---------------------------------------------------------------------------- No issues found here. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == The document doesn't use any RFC 2119 keywords, yet has text resembling RFC 2119 boilerplate text. -- The document date (March 20, 2018) is 2229 days in the past. Is this intentional? -- Found something which looks like a code comment -- if you have code sections in the document, please surround them with '' and '' lines. Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) == Outdated reference: A later version (-17) exists of draft-ietf-mpls-base-yang-06 == Outdated reference: A later version (-36) exists of draft-ietf-teas-yang-te-14 ** Obsolete normative reference: RFC 5246 (Obsoleted by RFC 8446) ** Obsolete normative reference: RFC 6536 (Obsoleted by RFC 8341) == Outdated reference: A later version (-10) exists of draft-ietf-rtgwg-lne-model-09 == Outdated reference: A later version (-12) exists of draft-ietf-rtgwg-ni-model-11 Summary: 2 errors (**), 0 flaws (~~), 6 warnings (==), 2 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group R. Rahman, Ed. 3 Internet-Draft Cisco Systems 4 Intended status: Standards Track L. Zheng, Ed. 5 Expires: September 21, 2018 Huawei Technologies 6 M. Jethanandani, Ed. 8 S. Pallagatti 10 G. Mirsky 11 ZTE Corporation 12 March 20, 2018 14 YANG Data Model for Bidirectional Forwarding Detection (BFD) 15 draft-ietf-bfd-yang-12.txt 17 Abstract 19 This document defines a YANG data model that can be used to configure 20 and manage Bidirectional Forwarding Detection (BFD). 22 The YANG modules in this document conform to the Network Management 23 Datastore Architecture (NMDA). 25 Status of This Memo 27 This Internet-Draft is submitted in full conformance with the 28 provisions of BCP 78 and BCP 79. 30 Internet-Drafts are working documents of the Internet Engineering 31 Task Force (IETF). Note that other groups may also distribute 32 working documents as Internet-Drafts. The list of current Internet- 33 Drafts is at http://datatracker.ietf.org/drafts/current/. 35 Internet-Drafts are draft documents valid for a maximum of six months 36 and may be updated, replaced, or obsoleted by other documents at any 37 time. It is inappropriate to use Internet-Drafts as reference 38 material or to cite them other than as "work in progress." 40 This Internet-Draft will expire on September 21, 2018. 42 Copyright Notice 44 Copyright (c) 2018 IETF Trust and the persons identified as the 45 document authors. All rights reserved. 47 This document is subject to BCP 78 and the IETF Trust's Legal 48 Provisions Relating to IETF Documents 49 (http://trustee.ietf.org/license-info) in effect on the date of 50 publication of this document. Please review these documents 51 carefully, as they describe your rights and restrictions with respect 52 to this document. Code Components extracted from this document must 53 include Simplified BSD License text as described in Section 4.e of 54 the Trust Legal Provisions and are provided without warranty as 55 described in the Simplified BSD License. 57 Table of Contents 59 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 60 1.1. Requirements Language . . . . . . . . . . . . . . . . . . 4 61 1.2. Tree Diagrams . . . . . . . . . . . . . . . . . . . . . . 4 62 2. Design of the Data Model . . . . . . . . . . . . . . . . . . 4 63 2.1. Design of Configuration Model . . . . . . . . . . . . . . 5 64 2.1.1. Common BFD configuration parameters . . . . . . . . . 6 65 2.1.2. Single-hop IP . . . . . . . . . . . . . . . . . . . . 7 66 2.1.3. Multihop IP . . . . . . . . . . . . . . . . . . . . . 7 67 2.1.4. MPLS Traffic Engineering Tunnels . . . . . . . . . . 8 68 2.1.5. MPLS Label Switched Paths . . . . . . . . . . . . . . 9 69 2.1.6. Link Aggregation Groups . . . . . . . . . . . . . . . 9 70 2.2. Design of Operational State Model . . . . . . . . . . . . 9 71 2.3. Notifications . . . . . . . . . . . . . . . . . . . . . . 10 72 2.4. RPC Operations . . . . . . . . . . . . . . . . . . . . . 10 73 2.5. BFD top level hierarchy . . . . . . . . . . . . . . . . . 10 74 2.6. BFD IP single-hop hierarchy . . . . . . . . . . . . . . . 10 75 2.7. BFD IP multihop hierarchy . . . . . . . . . . . . . . . . 12 76 2.8. BFD over LAG hierarchy . . . . . . . . . . . . . . . . . 14 77 2.9. BFD over MPLS LSPs hierarchy . . . . . . . . . . . . . . 17 78 2.10. BFD over MPLS-TE hierarchy . . . . . . . . . . . . . . . 19 79 2.11. Interaction with other YANG modules . . . . . . . . . . . 21 80 2.11.1. Module ietf-interfaces . . . . . . . . . . . . . . . 21 81 2.11.2. Module ietf-ip . . . . . . . . . . . . . . . . . . . 22 82 2.11.3. Module ietf-mpls . . . . . . . . . . . . . . . . . . 22 83 2.11.4. Module ietf-te . . . . . . . . . . . . . . . . . . . 22 84 2.12. IANA BFD YANG Module . . . . . . . . . . . . . . . . . . 22 85 2.13. BFD types YANG Module . . . . . . . . . . . . . . . . . . 25 86 2.14. BFD top-level YANG Module . . . . . . . . . . . . . . . . 38 87 2.15. BFD IP single-hop YANG Module . . . . . . . . . . . . . . 40 88 2.16. BFD IP multihop YANG Module . . . . . . . . . . . . . . . 43 89 2.17. BFD over LAG YANG Module . . . . . . . . . . . . . . . . 46 90 2.18. BFD over MPLS YANG Module . . . . . . . . . . . . . . . . 50 91 2.19. BFD over MPLS-TE YANG Module . . . . . . . . . . . . . . 54 92 3. Data Model examples . . . . . . . . . . . . . . . . . . . . . 57 93 3.1. IP single-hop . . . . . . . . . . . . . . . . . . . . . . 57 94 3.2. IP multihop . . . . . . . . . . . . . . . . . . . . . . . 58 95 3.3. LAG . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 96 3.4. MPLS . . . . . . . . . . . . . . . . . . . . . . . . . . 60 98 4. Security Considerations . . . . . . . . . . . . . . . . . . . 61 99 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 64 100 5.1. IANA-Maintained iana-bfd-types module . . . . . . . . . . 65 101 6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 65 102 7. References . . . . . . . . . . . . . . . . . . . . . . . . . 66 103 7.1. Normative References . . . . . . . . . . . . . . . . . . 66 104 7.2. Informative References . . . . . . . . . . . . . . . . . 68 105 Appendix A. Echo function configuration example . . . . . . . . 69 106 A.1. Example YANG module for BFD echo function configuration . 69 107 Appendix B. Change log . . . . . . . . . . . . . . . . . . . . . 71 108 B.1. Changes between versions -11 and -12 . . . . . . . . . . 71 109 B.2. Changes between versions -10 and -11 . . . . . . . . . . 71 110 B.3. Changes between versions -09 and -10 . . . . . . . . . . 71 111 B.4. Changes between versions -08 and -09 . . . . . . . . . . 71 112 B.5. Changes between versions -07 and -08 . . . . . . . . . . 72 113 B.6. Changes between versions -06 and -07 . . . . . . . . . . 72 114 B.7. Changes between versions -05 and -06 . . . . . . . . . . 72 115 B.8. Changes between versions -04 and -05 . . . . . . . . . . 72 116 B.9. Changes between versions -03 and -04 . . . . . . . . . . 72 117 B.10. Changes between versions -02 and -03 . . . . . . . . . . 73 118 B.11. Changes between versions -01 and -02 . . . . . . . . . . 73 119 B.12. Changes between versions -00 and -01 . . . . . . . . . . 73 120 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 73 122 1. Introduction 124 This document defines a YANG data model that can be used to configure 125 and manage Bidirectional Forwarding Detection (BFD) [RFC5880]. BFD 126 is a network protocol which is used for liveness detection of 127 arbitrary paths between systems. Some examples of different types of 128 paths over which we have BFD: 130 1) Two systems directly connected via IP. This is known as BFD over 131 single-hop IP, a.k.a. BFD for IPv4 and IPv6 [RFC5881] 133 2) Two systems connected via multiple hops as described in BFD for 134 Multiple Hops. [RFC5883] 136 3) Two systems connected via MPLS Label Switched Paths (LSPs) as 137 described in BFD for MPLS LSP [RFC5884] 139 4) Two systems connected via a Link Aggregation Group (LAG) interface 140 as described in BFD on LAG Interfaces [RFC7130] 142 5) Two systems connected via pseudowires (PWs), this is known as 143 Virtual Circuit Connectivity Verification (VCCV) as described in BFD 144 for PW VCCV [RFC5885]. This is not addressed in this document. 146 BFD typically does not operate on its own. Various control 147 protocols, also known as BFD clients, use the services provided by 148 BFD for their own operation as described in Generic Application of 149 BFD [RFC5882]. The obvious candidates which use BFD are those which 150 do not have "hellos" to detect failures, e.g. static routes, and 151 routing protocols whose "hellos" do not support sub-second failure 152 detection, e.g. OSPF and IS-IS. 154 The YANG modules in this document conform to the Network Management 155 Datastore Architecture (NMDA) Network Management Datastore 156 Architecture [I-D.ietf-netmod-revised-datastores]. This means that 157 the data models do not have separate top-level or sibling containers 158 for configuration and operational state data. 160 1.1. Requirements Language 162 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 163 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 164 document are to be interpreted as described in BCP 14 [RFC2119] 165 [RFC8174] when, and only when, they appear in all capitals, as shown 166 here. 168 1.2. Tree Diagrams 170 This document uses the graphical representation of data models 171 defined in [I-D.ietf-netmod-yang-tree-diagrams]. 173 2. Design of the Data Model 175 Since BFD is used for liveliness detection of various forwarding 176 paths, there is no uniform key to identify a BFD session. So the BFD 177 data model is split in multiple YANG modules where each module 178 corresponds to one type of forwarding path. For example, BFD for IP 179 single-hop is in one YANG module and BFD for MPLS-TE is in another 180 YANG module. The main difference between these modules is how a BFD 181 session is uniquely identified, i.e the key for the list containing 182 the BFD sessions for that forwarding path. To avoid duplication of 183 BFD definitions, we have common types and groupings which are used by 184 all the modules. 186 A new control-plane protocol "bfdv1" is defined and a "bfd" container 187 is created under control-plane-protocol as specified in "A YANG Data 188 Model for Routing Management (NMDA Version)" [RFC8349]. This new 189 "bfd" container is augmented by all the YANG modules for their 190 respective specific information: 192 1. ietf-bfd-ip-sh.yang augments "/routing/control-plane-protocols/ 193 control-plane-protocol/bfd/" with the "ip-sh" container for BFD 194 sessions over IP single-hop. 196 2. ietf-bfd-ip-mh.yang augments "/routing/control-plane-protocols/ 197 control-plane-protocol/bfd/" with the "ip-mh" container for BFD 198 sessions over IP multi-hop. 200 3. ietf-bfd-lag.yang augments "/routing/control-plane-protocols/ 201 control-plane-protocol/bfd/" with the "lag" container for BFD 202 sessions over LAG. 204 4. ietf-bfd-mpls.yang augments "/routing/control-plane-protocols/ 205 control-plane-protocol/bfd/" with the "mpls" container for BFD 206 over MPLS LSPs. 208 5. ietf-bfd-mpls-te.yang augments "/routing/control-plane-protocols/ 209 control-plane-protocol/bfd/" with the "mpls-te" container for BFD 210 over MPLS-TE. 212 BFD can operate in the following contexts: 214 1. At the network device level 216 2. In Logical Network Elements as described in YANG Logical Network 217 Element [I-D.ietf-rtgwg-lne-model] 219 3. In Network Instances as described in YANG Logical Network Element 220 [I-D.ietf-rtgwg-ni-model] 222 When used at the network device level, the BFD YANG model is used 223 "as-is". When the BFD YANG model is used in a Logical Network 224 Element or in a Network Instance, then the BFD YANG model augments 225 the mounted routing model for the Logical Network Element or the 226 Network Instance. 228 2.1. Design of Configuration Model 230 The configuration model consists mainly of the parameters specified 231 in BFD [RFC5880]. Some examples are desired minimum transmit 232 interval, required minimum receive interval, detection multiplier, 233 etc 235 BFD clients are applications that use BFD for fast detection of 236 failures. Some implementations have BFD session configuration under 237 the BFD clients. For example, BFD session configuration under 238 routing applications such as OSPF, IS-IS, BGP etc. Other 239 implementations have BFD session configuration centralized under BFD, 240 i.e. outside the multiple BFD clients. 242 The BFD parameters of interest to a BFD client are mainly the 243 multiplier and interval(s) since those parameters impact the 244 convergence time of the BFD clients when a failure occurs. Other 245 parameters such as BFD authentication are not specific to the 246 requirements of the BFD client. Ideally all configuration should be 247 centralized under BFD. However, this is a problem for clients of BFD 248 which auto-discover their peers. For example, IGPs do not have the 249 peer address configured, instead the IGP is enabled on an interface 250 and the IGP peers are auto-discovered. So for an operator to 251 configure BFD to an IGP peer, the operator would first have to 252 determine the peer addresses. And when a new peer is discovered, BFD 253 configuration would need to be added. To avoid this issue, we define 254 grouping client-cfg-parms in Section 2.13 for BFD clients to 255 configure BFD: this allows BFD clients such as the IGPs to have 256 configuration (multiplier and intervals) for the BFD sessions they 257 need. For example, when a new IGP peer is discovered, the IGP would 258 create a BFD session to the newly discovered peer and similarly when 259 an IGP peer goes away, the IGP would remove the BFD session to that 260 peer. The mechanism how the BFD sessions are created and removed by 261 the BFD clients is outside the scope of this document, but typically 262 this would be done by use of an API implemented by the BFD module on 263 the system. For BFD clients which create BFD sessions via their own 264 configuration, authentication parameters (if required) are still 265 specified in BFD. 267 2.1.1. Common BFD configuration parameters 269 The basic BFD configuration parameters are: 271 local-multiplier 272 This is the detection time multiplier as defined in BFD 273 [RFC5880]. 275 desired-min-tx-interval 276 This is the Desired Min TX Interval as defined in BFD 277 [RFC5880]. 279 required-min-rx-interval 280 This is the Required Min RX Interval as defined in BFD 281 [RFC5880]. 283 Although BFD [RFC5880] allows for different values for transmit and 284 receive intervals, some implementations allow users to specify just 285 one interval which is used for both transmit and receive intervals or 286 separate values for transmit and receive intervals. The BFD YANG 287 model supports this: there is a choice between "min-interval", used 288 for both transmit and receive intervals, and "desired-min-tx- 289 interval" and "required-min-rx-interval". This is supported via a 290 grouping which is used by the YANG modules for the various forwarding 291 paths. 293 For BFD authentication we have: 295 key-chain 296 This is a reference to key-chain defined in YANG Data Model 297 for Key Chains [RFC8177]. The keys, cryptographic 298 algorithms, key lifetime etc are all defined in the key-chain 299 model. 301 meticulous 302 This enables meticulous mode as per BFD [RFC5880]. 304 2.1.2. Single-hop IP 306 For single-hop IP, there is an augment of the "bfd" data node in 307 Section 2. The "ip-sh" node contains a list of IP single-hop 308 sessions where each session is uniquely identified by the interface 309 and destination address pair. For the configuration parameters we 310 use what is defined in Section 2.1.1. The "ip-sh" node also contains 311 a list of interfaces, this is used to specify authentication 312 parameters for BFD sessions which are created by BFD clients, see 313 Section 2.1. 315 [RFC5880] and [RFC5881] do not specify whether echo function is 316 continuous or on demand. Therefore the mechanism used to start and 317 stop echo function is implementation specific and should be done by 318 augmentation: 320 1) Configuration. This is suitable for continuous echo function. 321 An example is provided in Appendix A. 323 2) RPC. This is suitable for on-demand echo function. 325 2.1.3. Multihop IP 327 For multihop IP, there is an augment of the "bfd" data node in 328 Section 2. 330 Because of multiple paths, there could be multiple multihop IP 331 sessions between a source and a destination address. We identify 332 this as a "session-group". The key for each "session-group" consists 333 of: 335 source address 336 Address belonging to the local system as per BFD for Multiple 337 Hops [RFC5883] 339 destination address 340 Address belonging to the remote system as per BFD for 341 Multiple Hops [RFC5883] 343 For the configuration parameters we use what is defined in 344 Section 2.1.1 346 Here are some extra parameters: 348 tx-ttl 349 TTL of outgoing BFD control packets. 351 rx-ttl 352 Minimum TTL of incoming BFD control packets. 354 2.1.4. MPLS Traffic Engineering Tunnels 356 For MPLS-TE tunnels, BFD is configured under the MPLS-TE tunnel since 357 the desired failure detection parameters is a property of the MPLS-TE 358 tunnel. This is achieved by augmenting the MPLS-TE data model in 359 YANG Data Model for TE Topologies [I-D.ietf-teas-yang-te]. For BFD 360 parameters which are specific to the TE application, e.g. whether to 361 tear down the tunnel in the event of a BFD session failure, these 362 parameters will be defined in the YANG model of the MPLS-TE 363 application. 365 On top of the usual BFD parameters, we have the following per MPLS-TE 366 tunnel: 368 encap 369 Encapsulation for the BFD packets: choice between IP, G-ACh 370 and IP with G-ACh as per MPLS Generic Associated Channel 371 [RFC5586] 373 For general MPLS-TE data, "mpls-te" data node is added under the 374 "bfd" node in Section 2. Since some MPLS-TE tunnels are uni- 375 directional there is no MPLS-TE configuration for these tunnels on 376 the egress node (note that this does not apply to bi-directional 377 MPLS-TP tunnels). The BFD parameters for the egress node are added 378 under "mpls-te". 380 2.1.5. MPLS Label Switched Paths 382 Here we address MPLS LSPs whose FEC is an IP address. The "bfd" node 383 in Section 2 is augmented with "mpls" which contains a list of 384 sessions uniquely identified by an IP prefix. Because of multiple 385 paths, there could be multiple MPLS sessions to an MPLS FEC. We 386 identify this as a "session-group". 388 Since these LSPs are uni-directional there is no LSP configuration on 389 the egress node. 391 The BFD parameters for the egress node are added under "mpls". 393 2.1.6. Link Aggregation Groups 395 Per BFD on LAG Interfaces [RFC7130], configuring BFD on LAG consists 396 of having micro-BFD sessions on each LAG member link. Since the BFD 397 parameters are an attribute of the LAG, they should be under the LAG. 398 However there is no LAG YANG model which we can augment. So a "lag" 399 data node is added to the "bfd" node in Section 2, the configuration 400 is per-LAG: we have a list of LAGs. The destination IP address of 401 the micro-BFD sessions is configured per-LAG and per address-family 402 (IPv4 and IPv6) 404 2.2. Design of Operational State Model 406 The operational state model contains both the overall statistics of 407 BFD sessions running on the device and the per session operational 408 information. 410 The overall statistics of BFD sessions consist of number of BFD 411 sessions, number of BFD sessions up etc. This information is 412 available globally (i.e. for all BFD sessions) under the "bfd" node 413 in Section 2 and also per type of forwarding path. 415 For each BFD session, mainly three categories of operational state 416 data are shown. The fundamental information of a BFD session such as 417 the local discriminator, remote discriminator and the capability of 418 supporting demand detect mode are shown in the first category. The 419 second category includes a BFD session running information, e.g. the 420 remote BFD state and the diagnostic code received. Another example 421 is the actual transmit interval between the control packets, which 422 may be different from the desired minimum transmit interval 423 configured, is shown in this category. Similar examples are actual 424 received interval between the control packets and the actual transmit 425 interval between the echo packets. The third category contains the 426 detailed statistics of the session, e.g. when the session 427 transitioned up/down and how long it has been in that state. 429 For some path types, there may be more than 1 session on the virtual 430 path to the destination. For example, with IP multihop and MPLS 431 LSPs, there could be multiple BFD sessions from the source to the 432 same destination to test the various paths (ECMP) to the destination. 433 This is represented by having multiple "sessions" under each 434 "session-group". 436 2.3. Notifications 438 This YANG model defines notifications to inform end-users of 439 important events detected during the protocol operation. Pair of 440 local and remote discriminator identifies a BFD session on local 441 system. Notifications also give more important details about BFD 442 sessions; e.g. new state, time in previous state, network-instance 443 and the reason that the BFD session state changed. The notifications 444 are defined for each type of forwarding path but use groupings for 445 common information. 447 2.4. RPC Operations 449 None. 451 2.5. BFD top level hierarchy 453 At the "bfd" node under control-plane-protocol, there is no 454 configuration data, only operational state data. The operational 455 state data consist of overall BFD session statistics, i.e. for BFD on 456 all types of forwarding paths. 458 module: ietf-bfd 459 augment /rt:routing/rt:control-plane-protocols 460 /rt:control-plane-protocol: 461 +--rw bfd 462 +--ro summary 463 +--ro number-of-sessions? yang:gauge32 464 +--ro number-of-sessions-up? yang:gauge32 465 +--ro number-of-sessions-down? yang:gauge32 466 +--ro number-of-sessions-admin-down? yang:gauge32 468 2.6. BFD IP single-hop hierarchy 470 An "ip-sh" node is added under "bfd" node in control-plane-protocol. 471 The configuration and operational state data for each BFD IP single- 472 hop session is under this "ip-sh" node. 474 module: ietf-bfd-ip-sh 475 augment /rt:routing/rt:control-plane-protocols 476 /rt:control-plane-protocol/bfd:bfd: 478 +--rw ip-sh 479 +--ro summary 480 | +--ro number-of-sessions? yang:gauge32 481 | +--ro number-of-sessions-up? yang:gauge32 482 | +--ro number-of-sessions-down? yang:gauge32 483 | +--ro number-of-sessions-admin-down? yang:gauge32 484 +--rw sessions 485 | +--rw session* [interface dest-addr] 486 | +--rw interface if:interface-ref 487 | +--rw dest-addr inet:ip-address 488 | +--rw source-addr? inet:ip-address 489 | +--rw local-multiplier? multiplier 490 | +--rw (interval-config-type)? 491 | | +--:(tx-rx-intervals) 492 | | | +--rw desired-min-tx-interval? uint32 493 | | | +--rw required-min-rx-interval? uint32 494 | | +--:(single-interval) {single-minimum-interval}? 495 | | +--rw min-interval? uint32 496 | +--rw demand-enabled? boolean {demand-mode}? 497 | +--rw admin-down? boolean 498 | +--rw authentication! {authentication}? 499 | | +--rw key-chain? kc:key-chain-ref 500 | | +--rw meticulous? boolean 501 | +--ro path-type? identityref 502 | +--ro ip-encapsulation? boolean 503 | +--ro local-discriminator? discriminator 504 | +--ro remote-discriminator? discriminator 505 | +--ro remote-multiplier? multiplier 506 | +--ro demand-capability? boolean {demand-mode}? 507 | +--ro source-port? inet:port-number 508 | +--ro dest-port? inet:port-number 509 | +--ro session-running 510 | | +--ro session-index? uint32 511 | | +--ro local-state? state 512 | | +--ro remote-state? state 513 | | +--ro local-diagnostic? 514 | | | iana-bfd-types:diagnostic 515 | | +--ro remote-diagnostic? 516 | | | iana-bfd-types:diagnostic 517 | | +--ro remote-authenticated? boolean 518 | | +--ro remote-authentication-type? 519 | | | iana-bfd-types:auth-type {authentication}? 520 | | +--ro detection-mode? enumeration 521 | | +--ro negotiated-tx-interval? uint32 522 | | +--ro negotiated-rx-interval? uint32 523 | | +--ro detection-time? uint32 524 | | +--ro echo-tx-interval-in-use? uint32 525 | | {echo-mode}? 526 | +--ro session-statistics 527 | +--ro create-time? yang:date-and-time 528 | +--ro last-down-time? yang:date-and-time 529 | +--ro last-up-time? yang:date-and-time 530 | +--ro down-count? yang:counter32 531 | +--ro admin-down-count? yang:counter32 532 | +--ro receive-packet-count? yang:counter64 533 | +--ro send-packet-count? yang:counter64 534 | +--ro receive-invalid-packet-count? yang:counter64 535 | +--ro send-failed-packet-count? yang:counter64 536 +--rw interfaces* [interface] 537 +--rw interface if:interface-ref 538 +--rw authentication! {authentication}? 539 +--rw key-chain? kc:key-chain-ref 540 +--rw meticulous? boolean 542 notifications: 543 +---n singlehop-notification 544 +--ro local-discr? discriminator 545 +--ro remote-discr? discriminator 546 +--ro new-state? state 547 +--ro state-change-reason? iana-bfd-types:diagnostic 548 +--ro time-of-last-state-change? yang:date-and-time 549 +--ro dest-addr? inet:ip-address 550 +--ro source-addr? inet:ip-address 551 +--ro session-index? uint32 552 +--ro path-type? identityref 553 +--ro interface? if:interface-ref 554 +--ro echo-enabled? boolean 556 2.7. BFD IP multihop hierarchy 558 An "ip-mh" node is added under the "bfd" node in cntrol-plane- 559 protocol. The configuration and operational state data for each BFD 560 IP multihop session is under this "ip-mh" node. In the operational 561 state model we support multiple BFD multihop sessions per remote 562 address (ECMP), the local discriminator is used as key. 564 module: ietf-bfd-ip-mh 565 augment /rt:routing/rt:control-plane-protocols 566 /rt:control-plane-protocol/bfd:bfd: 567 +--rw ip-mh 568 +--ro summary 569 | +--ro number-of-sessions? yang:gauge32 570 | +--ro number-of-sessions-up? yang:gauge32 571 | +--ro number-of-sessions-down? yang:gauge32 572 | +--ro number-of-sessions-admin-down? yang:gauge32 573 +--rw session-groups 574 +--rw session-group* [source-addr dest-addr] 575 +--rw source-addr inet:ip-address 576 +--rw dest-addr inet:ip-address 577 +--rw local-multiplier? multiplier 578 +--rw (interval-config-type)? 579 | +--:(tx-rx-intervals) 580 | | +--rw desired-min-tx-interval? uint32 581 | | +--rw required-min-rx-interval? uint32 582 | +--:(single-interval) {single-minimum-interval}? 583 | +--rw min-interval? uint32 584 +--rw demand-enabled? boolean {demand-mode}? 585 +--rw admin-down? boolean 586 +--rw authentication! {authentication}? 587 | +--rw key-chain? kc:key-chain-ref 588 | +--rw meticulous? boolean 589 +--rw tx-ttl? bfd-types:hops 590 +--rw rx-ttl bfd-types:hops 591 +--ro sessions* 592 +--ro path-type? identityref 593 +--ro ip-encapsulation? boolean 594 +--ro local-discriminator? discriminator 595 +--ro remote-discriminator? discriminator 596 +--ro remote-multiplier? multiplier 597 +--ro demand-capability? boolean {demand-mode}? 598 +--ro source-port? inet:port-number 599 +--ro dest-port? inet:port-number 600 +--ro session-running 601 | +--ro session-index? uint32 602 | +--ro local-state? state 603 | +--ro remote-state? state 604 | +--ro local-diagnostic? 605 | | iana-bfd-types:diagnostic 606 | +--ro remote-diagnostic? 607 | | iana-bfd-types:diagnostic 608 | +--ro remote-authenticated? boolean 609 | +--ro remote-authentication-type? 610 | | iana-bfd-types:auth-type {authentication}? 611 | +--ro detection-mode? enumeration 612 | +--ro negotiated-tx-interval? uint32 613 | +--ro negotiated-rx-interval? uint32 614 | +--ro detection-time? uint32 615 | +--ro echo-tx-interval-in-use? uint32 616 | {echo-mode}? 617 +--ro session-statistics 618 +--ro create-time? 619 | yang:date-and-time 620 +--ro last-down-time? 621 | yang:date-and-time 622 +--ro last-up-time? 623 | yang:date-and-time 624 +--ro down-count? yang:counter32 625 +--ro admin-down-count? yang:counter32 626 +--ro receive-packet-count? yang:counter64 627 +--ro send-packet-count? yang:counter64 628 +--ro receive-invalid-packet-count? yang:counter64 629 +--ro send-failed-packet-count? yang:counter64 631 notifications: 632 +---n multihop-notification 633 +--ro local-discr? discriminator 634 +--ro remote-discr? discriminator 635 +--ro new-state? state 636 +--ro state-change-reason? iana-bfd-types:diagnostic 637 +--ro time-of-last-state-change? yang:date-and-time 638 +--ro dest-addr? inet:ip-address 639 +--ro source-addr? inet:ip-address 640 +--ro session-index? uint32 641 +--ro path-type? identityref 643 2.8. BFD over LAG hierarchy 645 A "lag" node is added under the "bfd" node in control-plane-protocol. 646 The configuration and operational state data for each BFD LAG session 647 is under this "lag" node. 649 module: ietf-bfd-lag 650 augment /rt:routing/rt:control-plane-protocols 651 /rt:control-plane-protocol/bfd:bfd: 652 +--rw lag 653 +--rw micro-bfd-ipv4-session-statistics 654 | +--ro summary 655 | +--ro number-of-sessions? yang:gauge32 656 | +--ro number-of-sessions-up? yang:gauge32 657 | +--ro number-of-sessions-down? yang:gauge32 658 | +--ro number-of-sessions-admin-down? yang:gauge32 659 +--rw micro-bfd-ipv6-session-statistics 660 | +--ro summary 661 | +--ro number-of-sessions? yang:gauge32 662 | +--ro number-of-sessions-up? yang:gauge32 663 | +--ro number-of-sessions-down? yang:gauge32 664 | +--ro number-of-sessions-admin-down? yang:gauge32 665 +--rw sessions 666 +--rw session* [lag-name] 667 +--rw lag-name if:interface-ref 668 +--rw ipv4-dest-addr? inet:ipv4-address 669 +--rw ipv6-dest-addr? inet:ipv6-address 670 +--rw local-multiplier? multiplier 671 +--rw (interval-config-type)? 672 | +--:(tx-rx-intervals) 673 | | +--rw desired-min-tx-interval? uint32 674 | | +--rw required-min-rx-interval? uint32 675 | +--:(single-interval) {single-minimum-interval}? 676 | +--rw min-interval? uint32 677 +--rw demand-enabled? boolean {demand-mode}? 678 +--rw admin-down? boolean 679 +--rw authentication! {authentication}? 680 | +--rw key-chain? kc:key-chain-ref 681 | +--rw meticulous? boolean 682 +--rw use-ipv4? boolean 683 +--rw use-ipv6? boolean 684 +--ro member-links* [member-link] 685 +--ro member-link if:interface-ref 686 +--ro micro-bfd-ipv4 687 | +--ro path-type? identityref 688 | +--ro ip-encapsulation? boolean 689 | +--ro local-discriminator? discriminator 690 | +--ro remote-discriminator? discriminator 691 | +--ro remote-multiplier? multiplier 692 | +--ro demand-capability? boolean 693 | | {demand-mode}? 694 | +--ro source-port? inet:port-number 695 | +--ro dest-port? inet:port-number 696 | +--ro session-running 697 | | +--ro session-index? uint32 698 | | +--ro local-state? state 699 | | +--ro remote-state? state 700 | | +--ro local-diagnostic? 701 | | | iana-bfd-types:diagnostic 702 | | +--ro remote-diagnostic? 703 | | | iana-bfd-types:diagnostic 704 | | +--ro remote-authenticated? boolean 705 | | +--ro remote-authentication-type? 706 | | | iana-bfd-types:auth-type 707 | | | {authentication}? 708 | | +--ro detection-mode? enumeration 709 | | +--ro negotiated-tx-interval? uint32 710 | | +--ro negotiated-rx-interval? uint32 711 | | +--ro detection-time? uint32 712 | | +--ro echo-tx-interval-in-use? uint32 713 | | {echo-mode}? 714 | +--ro session-statistics 715 | +--ro create-time? 716 | | yang:date-and-time 717 | +--ro last-down-time? 718 | | yang:date-and-time 719 | +--ro last-up-time? 720 | | yang:date-and-time 721 | +--ro down-count? 722 | | yang:counter32 723 | +--ro admin-down-count? 724 | | yang:counter32 725 | +--ro receive-packet-count? 726 | | yang:counter64 727 | +--ro send-packet-count? 728 | | yang:counter64 729 | +--ro receive-invalid-packet-count? 730 | | yang:counter64 731 | +--ro send-failed-packet-count? 732 | yang:counter64 733 +--ro micro-bfd-ipv6 734 +--ro path-type? identityref 735 +--ro ip-encapsulation? boolean 736 +--ro local-discriminator? discriminator 737 +--ro remote-discriminator? discriminator 738 +--ro remote-multiplier? multiplier 739 +--ro demand-capability? boolean 740 | {demand-mode}? 741 +--ro source-port? inet:port-number 742 +--ro dest-port? inet:port-number 743 +--ro session-running 744 | +--ro session-index? uint32 745 | +--ro local-state? state 746 | +--ro remote-state? state 747 | +--ro local-diagnostic? 748 | | iana-bfd-types:diagnostic 749 | +--ro remote-diagnostic? 750 | | iana-bfd-types:diagnostic 751 | +--ro remote-authenticated? boolean 752 | +--ro remote-authentication-type? 753 | | iana-bfd-types:auth-type 754 | | {authentication}? 755 | +--ro detection-mode? enumeration 756 | +--ro negotiated-tx-interval? uint32 757 | +--ro negotiated-rx-interval? uint32 758 | +--ro detection-time? uint32 759 | +--ro echo-tx-interval-in-use? uint32 760 | {echo-mode}? 761 +--ro session-statistics 762 +--ro create-time? 763 | yang:date-and-time 764 +--ro last-down-time? 765 | yang:date-and-time 766 +--ro last-up-time? 767 | yang:date-and-time 768 +--ro down-count? 769 | yang:counter32 770 +--ro admin-down-count? 771 | yang:counter32 772 +--ro receive-packet-count? 773 | yang:counter64 774 +--ro send-packet-count? 775 | yang:counter64 776 +--ro receive-invalid-packet-count? 777 | yang:counter64 778 +--ro send-failed-packet-count? 779 yang:counter64 781 notifications: 782 +---n lag-notification 783 +--ro local-discr? discriminator 784 +--ro remote-discr? discriminator 785 +--ro new-state? state 786 +--ro state-change-reason? iana-bfd-types:diagnostic 787 +--ro time-of-last-state-change? yang:date-and-time 788 +--ro dest-addr? inet:ip-address 789 +--ro source-addr? inet:ip-address 790 +--ro session-index? uint32 791 +--ro path-type? identityref 792 +--ro lag-name? if:interface-ref 793 +--ro member-link? if:interface-ref 795 2.9. BFD over MPLS LSPs hierarchy 797 An "mpls" node is added under the "bfd" node in control-plane- 798 protocol. The configuration is per MPLS FEC under this "mpls" node. 799 In the operational state model we support multiple BFD sessions per 800 MPLS FEC (ECMP), the local discriminator is used as key. The "mpls" 801 node can be used in a network device (top-level), or mounted in an 802 LNE or in a network instance. 804 module: ietf-bfd-mpls 805 augment /rt:routing/rt:control-plane-protocols 806 /rt:control-plane-protocol/bfd:bfd: 807 +--rw mpls 808 +--ro summary 809 | +--ro number-of-sessions? yang:gauge32 810 | +--ro number-of-sessions-up? yang:gauge32 811 | +--ro number-of-sessions-down? yang:gauge32 812 | +--ro number-of-sessions-admin-down? yang:gauge32 813 +--rw egress 814 | +--rw enable? boolean 815 | +--rw local-multiplier? multiplier 816 | +--rw (interval-config-type)? 817 | | +--:(tx-rx-intervals) 818 | | | +--rw desired-min-tx-interval? uint32 819 | | | +--rw required-min-rx-interval? uint32 820 | | +--:(single-interval) {single-minimum-interval}? 821 | | +--rw min-interval? uint32 822 | +--rw authentication! {authentication}? 823 | +--rw key-chain? kc:key-chain-ref 824 | +--rw meticulous? boolean 825 +--rw session-groups 826 +--rw session-group* [mpls-fec] 827 +--rw mpls-fec inet:ip-prefix 828 +--rw local-multiplier? multiplier 829 +--rw (interval-config-type)? 830 | +--:(tx-rx-intervals) 831 | | +--rw desired-min-tx-interval? uint32 832 | | +--rw required-min-rx-interval? uint32 833 | +--:(single-interval) {single-minimum-interval}? 834 | +--rw min-interval? uint32 835 +--rw demand-enabled? boolean {demand-mode}? 836 +--rw admin-down? boolean 837 +--rw authentication! {authentication}? 838 | +--rw key-chain? kc:key-chain-ref 839 | +--rw meticulous? boolean 840 +--ro sessions* 841 +--ro path-type? identityref 842 +--ro ip-encapsulation? boolean 843 +--ro local-discriminator? discriminator 844 +--ro remote-discriminator? discriminator 845 +--ro remote-multiplier? multiplier 846 +--ro demand-capability? boolean {demand-mode}? 847 +--ro source-port? inet:port-number 848 +--ro dest-port? inet:port-number 849 +--ro session-running 850 | +--ro session-index? uint32 851 | +--ro local-state? state 852 | +--ro remote-state? state 853 | +--ro local-diagnostic? 854 | | iana-bfd-types:diagnostic 855 | +--ro remote-diagnostic? 856 | | iana-bfd-types:diagnostic 857 | +--ro remote-authenticated? boolean 858 | +--ro remote-authentication-type? 859 | | iana-bfd-types:auth-type {authentication}? 860 | +--ro detection-mode? enumeration 861 | +--ro negotiated-tx-interval? uint32 862 | +--ro negotiated-rx-interval? uint32 863 | +--ro detection-time? uint32 864 | +--ro echo-tx-interval-in-use? uint32 865 | {echo-mode}? 866 +--ro session-statistics 867 | +--ro create-time? 868 | | yang:date-and-time 869 | +--ro last-down-time? 870 | | yang:date-and-time 871 | +--ro last-up-time? 872 | | yang:date-and-time 873 | +--ro down-count? yang:counter32 874 | +--ro admin-down-count? yang:counter32 875 | +--ro receive-packet-count? yang:counter64 876 | +--ro send-packet-count? yang:counter64 877 | +--ro receive-invalid-packet-count? yang:counter64 878 | +--ro send-failed-packet-count? yang:counter64 879 +--ro mpls-dest-address? inet:ip-address 881 notifications: 882 +---n mpls-notification 883 +--ro local-discr? discriminator 884 +--ro remote-discr? discriminator 885 +--ro new-state? state 886 +--ro state-change-reason? iana-bfd-types:diagnostic 887 +--ro time-of-last-state-change? yang:date-and-time 888 +--ro dest-addr? inet:ip-address 889 +--ro source-addr? inet:ip-address 890 +--ro session-index? uint32 891 +--ro path-type? identityref 892 +--ro mpls-dest-address? inet:ip-address 894 2.10. BFD over MPLS-TE hierarchy 896 YANG Data Model for TE Topologies [I-D.ietf-teas-yang-te] is 897 augmented. BFD is configured per MPLS-TE tunnel, and BFD session 898 operational state data is provided per MPLS-TE LSP. 900 module: ietf-bfd-mpls-te 901 augment /rt:routing/rt:control-plane-protocols 902 /rt:control-plane-protocol/bfd:bfd: 903 +--rw mpls-te 904 +--rw egress 905 | +--rw enable? boolean 906 | +--rw local-multiplier? multiplier 907 | +--rw (interval-config-type)? 908 | | +--:(tx-rx-intervals) 909 | | | +--rw desired-min-tx-interval? uint32 910 | | | +--rw required-min-rx-interval? uint32 911 | | +--:(single-interval) {single-minimum-interval}? 912 | | +--rw min-interval? uint32 913 | +--rw authentication! {authentication}? 914 | +--rw key-chain? kc:key-chain-ref 915 | +--rw meticulous? boolean 916 +--ro summary 917 +--ro number-of-sessions? yang:gauge32 918 +--ro number-of-sessions-up? yang:gauge32 919 +--ro number-of-sessions-down? yang:gauge32 920 +--ro number-of-sessions-admin-down? yang:gauge32 921 augment /te:te/te:tunnels/te:tunnel: 922 +--rw local-multiplier? multiplier 923 +--rw (interval-config-type)? 924 | +--:(tx-rx-intervals) 925 | | +--rw desired-min-tx-interval? uint32 926 | | +--rw required-min-rx-interval? uint32 927 | +--:(single-interval) {single-minimum-interval}? 928 | +--rw min-interval? uint32 929 +--rw demand-enabled? boolean {demand-mode}? 930 +--rw admin-down? boolean 931 +--rw authentication! {authentication}? 932 | +--rw key-chain? kc:key-chain-ref 933 | +--rw meticulous? boolean 934 +--rw encap? identityref 935 augment /te:te/te:lsps-state/te:lsp: 936 +--ro path-type? identityref 937 +--ro ip-encapsulation? boolean 938 +--ro local-discriminator? discriminator 939 +--ro remote-discriminator? discriminator 940 +--ro remote-multiplier? multiplier 941 +--ro demand-capability? boolean {demand-mode}? 942 +--ro source-port? inet:port-number 943 +--ro dest-port? inet:port-number 944 +--ro session-running 945 | +--ro session-index? uint32 946 | +--ro local-state? state 947 | +--ro remote-state? state 948 | +--ro local-diagnostic? iana-bfd-types:diagnostic 949 | +--ro remote-diagnostic? iana-bfd-types:diagnostic 950 | +--ro remote-authenticated? boolean 951 | +--ro remote-authentication-type? iana-bfd-types:auth-type 952 | | {authentication}? 953 | +--ro detection-mode? enumeration 954 | +--ro negotiated-tx-interval? uint32 955 | +--ro negotiated-rx-interval? uint32 956 | +--ro detection-time? uint32 957 | +--ro echo-tx-interval-in-use? uint32 {echo-mode}? 958 +--ro session-statistics 959 | +--ro create-time? yang:date-and-time 960 | +--ro last-down-time? yang:date-and-time 961 | +--ro last-up-time? yang:date-and-time 962 | +--ro down-count? yang:counter32 963 | +--ro admin-down-count? yang:counter32 964 | +--ro receive-packet-count? yang:counter64 965 | +--ro send-packet-count? yang:counter64 966 | +--ro receive-invalid-packet-count? yang:counter64 967 | +--ro send-failed-packet-count? yang:counter64 968 +--ro mpls-dest-address? inet:ip-address 970 notifications: 971 +---n mpls-te-notification 972 +--ro local-discr? discriminator 973 +--ro remote-discr? discriminator 974 +--ro new-state? state 975 +--ro state-change-reason? iana-bfd-types:diagnostic 976 +--ro time-of-last-state-change? yang:date-and-time 977 +--ro dest-addr? inet:ip-address 978 +--ro source-addr? inet:ip-address 979 +--ro session-index? uint32 980 +--ro path-type? identityref 981 +--ro mpls-dest-address? inet:ip-address 982 +--ro tunnel-name? string 984 2.11. Interaction with other YANG modules 986 Generic YANG Data Model for Connectionless OAM protocols 987 [I-D.ietf-lime-yang-connectionless-oam] describes how the LIME 988 connectionless OAM model could be extended to support BFD. 990 Also, the operation of the BFD data model depends on configuration 991 parameters that are defined in other YANG modules. 993 2.11.1. Module ietf-interfaces 995 The following boolean configuration is defined in A YANG Data Model 996 for Interface Management [RFC8343]: 998 /if:interfaces/if:interface/if:enabled 999 If this configuration is set to "false", no BFD packets can 1000 be transmitted or received on that interface. 1002 2.11.2. Module ietf-ip 1004 The following boolean configuration is defined in A YANG Data Model 1005 for IP Management [I-D.ietf-netmod-rfc7277bis]: 1007 /if:interfaces/if:interface/ip:ipv4/ip:enabled 1008 If this configuration is set to "false", no BFD IPv4 packets 1009 can be transmitted or received on that interface. 1011 /if:interfaces/if:interface/ip:ipv4/ip:forwarding 1012 If this configuration is set to "false", no BFD IPv4 packets 1013 can be transmitted or received on that interface. 1015 /if:interfaces/if:interface/ip:ipv6/ip:enabled 1016 If this configuration is set to "false", no BFD IPv6 packets 1017 can be transmitted or received on that interface. 1019 /if:interfaces/if:interface/ip:ipv6/ip:forwarding 1020 If this configuration is set to "false", no BFD IPv6 packets 1021 can be transmitted or received on that interface. 1023 2.11.3. Module ietf-mpls 1025 The following boolean configuration is defined in A YANG Data Model 1026 for MPLS Base [I-D.ietf-mpls-base-yang]: 1028 /rt:routing/mpls:mpls/mpls:interface/mpls:config/mpls:enabled 1029 If this configuration is set to "false", no BFD MPLS packets 1030 can be transmitted or received on that interface. 1032 2.11.4. Module ietf-te 1034 The following configuration is defined in the "ietf-te" YANG module 1035 YANG Data Model for TE Topology [I-D.ietf-teas-yang-te]: 1037 /ietf-te:te/ietf-te:tunnels/ietf-te:tunnel/ietf-te:config/ietf- 1038 te:admin-status 1039 If this configuration is not set to "state-up", no BFD MPLS 1040 packets can be transmitted or received on that tunnel. 1042 2.12. IANA BFD YANG Module 1044 file "iana-bfd-types@2018-03-20.yang" 1046 module iana-bfd-types { 1048 yang-version 1.1; 1049 namespace "urn:ietf:params:xml:ns:yang:iana-bfd-types"; 1051 prefix "iana-bfd-types"; 1053 organization "IANA"; 1055 contact 1056 " Internet Assigned Numbers Authority 1058 Postal: ICANN 1059 4676 Admiralty Way, Suite 330 1060 Marina del Rey, CA 90292 1062 Tel: +1 310 823 9358 1063 "; 1065 description 1066 "This module defines YANG data types for IANA-registered 1067 BFD parameters. 1069 This YANG module is maintained by IANA and reflects the 1070 'BFD Diagnostic Codes' and 'BFD Authentication Types' registries. 1072 Copyright (c) 2018 IETF Trust and the persons 1073 identified as authors of the code. All rights reserved. 1075 Redistribution and use in source and binary forms, with or 1076 without modification, is permitted pursuant to, and subject 1077 to the license terms contained in, the Simplified BSD License 1078 set forth in Section 4.c of the IETF Trust's Legal Provisions 1079 Relating to IETF Documents 1080 (http://trustee.ietf.org/license-info). 1082 This version of this YANG module is part of RFC XXXX; see 1083 the RFC itself for full legal notices."; 1085 // RFC Ed.: replace XXXX with actual RFC number and remove 1086 // this note 1088 reference "RFC XXXX"; 1090 revision 2018-03-20 { 1091 description "Initial revision."; 1092 reference "RFC XXXX: IANA BFD YANG Data Types."; 1093 } 1095 /* 1096 * Type Definitions 1097 */ 1098 typedef diagnostic { 1099 type enumeration { 1100 enum none { 1101 value 0; 1102 description "None"; 1103 } 1104 enum control-expiry { 1105 value 1; 1106 description "Control timer expiry"; 1107 } 1108 enum echo-failed { 1109 value 2; 1110 description "Echo failure"; 1111 } 1112 enum neighbor-down { 1113 value 3; 1114 description "Neighbor down"; 1115 } 1116 enum forwarding-reset { 1117 value 4; 1118 description "Forwarding reset"; 1119 } 1120 enum path-down { 1121 value 5; 1122 description "Path down"; 1123 } 1124 enum concatenated-path-down { 1125 value 6; 1126 description "Concatenated path down"; 1127 } 1128 enum admin-down { 1129 value 7; 1130 description "Admin down"; 1131 } 1132 enum reverse-concatenated-path-down { 1133 value 8; 1134 description "Reverse concatenated path down"; 1135 } 1136 enum mis-connectivity-defect { 1137 value 9; 1138 description "Mis-connectivity defect as specified in RFC6428"; 1139 } 1140 } 1141 description 1142 "BFD diagnostic as defined in RFC 5880, values are maintained in 1143 the 'BFD Diagnostic Codes' IANA registry. Range is 0 to 31."; 1144 } 1145 typedef auth-type { 1146 type enumeration { 1147 enum reserved { 1148 value 0; 1149 description "Reserved"; 1150 } 1151 enum simple-password { 1152 value 1; 1153 description "Simple password"; 1154 } 1155 enum keyed-md5 { 1156 value 2; 1157 description "Keyed MD5"; 1158 } 1159 enum meticulous-keyed-md5 { 1160 value 3; 1161 description "Meticulous keyed MD5"; 1162 } 1163 enum keyed-sha1 { 1164 value 4; 1165 description "Keyed SHA1"; 1166 } 1167 enum meticulous-keyed-sha1 { 1168 value 5; 1169 description "Meticulous keyed SHA1"; 1170 } 1171 } 1172 description 1173 "BFD authentication type as defined in RFC 5880, values are 1174 maintained in the 'BFD Authentication Types' IANA registry. 1175 Range is 0 to 255."; 1176 } 1177 } 1179 1181 2.13. BFD types YANG Module 1183 This YANG module imports typedefs from [RFC6991], [RFC8177] and the 1184 "control-plane-protocol" identity from [RFC8349]. 1186 file "ietf-bfd-types@2018-03-20.yang" 1188 module ietf-bfd-types { 1190 yang-version 1.1; 1192 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-types"; 1193 prefix "bfd-types"; 1195 import iana-bfd-types { 1196 prefix "iana-bfd-types"; 1197 } 1199 import ietf-inet-types { 1200 prefix "inet"; 1201 reference "RFC 6991: Common YANG Data Types"; 1202 } 1204 import ietf-yang-types { 1205 prefix "yang"; 1206 reference "RFC 6991: Common YANG Data Types"; 1207 } 1209 import ietf-routing { 1210 prefix "rt"; 1211 reference 1212 "RFC 8349: A YANG Data Model for Routing Management 1213 (NMDA version)"; 1214 } 1216 import ietf-key-chain { 1217 prefix "kc"; 1218 reference "RFC 8177: YANG Data Model for Key Chains"; 1219 } 1221 organization "IETF BFD Working Group"; 1223 contact 1224 "WG Web: 1225 WG List: 1227 Editors: Reshad Rahman (rrahman@cisco.com), 1228 Lianshu Zheng (vero.zheng@huawei.com), 1229 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1231 description 1232 "This module contains a collection of BFD specific YANG data type 1233 definitions, as per RFC 5880, and also groupings which are common 1234 to other BFD YANG modules. 1236 Copyright (c) 2018 IETF Trust and the persons 1237 identified as authors of the code. All rights reserved. 1239 Redistribution and use in source and binary forms, with or 1240 without modification, is permitted pursuant to, and subject 1241 to the license terms contained in, the Simplified BSD License 1242 set forth in Section 4.c of the IETF Trust's Legal Provisions 1243 Relating to IETF Documents 1244 (http://trustee.ietf.org/license-info). 1246 This version of this YANG module is part of RFC XXXX; see 1247 the RFC itself for full legal notices."; 1249 // RFC Ed.: replace XXXX with actual RFC number and remove this 1250 // note 1252 reference "RFC XXXX"; 1254 revision 2018-03-20 { 1255 description "Initial revision."; 1256 reference "RFC XXXX: YANG Data Model for BFD"; 1257 } 1259 /* 1260 * Feature definitions 1261 */ 1262 feature single-minimum-interval { 1263 description 1264 "This feature indicates that the server supports configuration 1265 of one minimum interval value which is used for both transmit and 1266 receive minimum intervals."; 1267 } 1269 feature authentication { 1270 description 1271 "This feature indicates that the server supports BFD 1272 authentication."; 1273 reference 1274 "RFC 5880: Bidirectional Forwarding Detection (BFD), 1275 section 6.7."; 1276 } 1278 feature demand-mode { 1279 description 1280 "This feature indicates that the server supports BFD demand 1281 mode."; 1282 reference 1283 "RFC 5880: Bidirectional Forwarding Detection (BFD), 1284 section 6.6."; 1285 } 1287 feature echo-mode { 1288 description 1289 "This feature indicates that the server supports BFD echo 1290 mode."; 1291 reference 1292 "RFC 5880: Bidirectional Forwarding Detection (BFD), 1293 section 6.4."; 1294 } 1296 /* 1297 * Identity definitions 1298 */ 1299 identity bfdv1 { 1300 base "rt:control-plane-protocol"; 1301 description "BFD protocol version 1."; 1302 reference 1303 "RFC 5880: Bidirectional Forwarding Detection (BFD)."; 1304 } 1306 identity path-type { 1307 description 1308 "Base identity for BFD path type. The path type indicates 1309 the type of path on which BFD is running."; 1310 } 1311 identity path-ip-sh { 1312 base path-type; 1313 description "BFD on IP single hop."; 1314 reference 1315 "RFC 5881: Bidirectional Forwarding Detection (BFD) 1316 for IPv4 and IPv6 (Single Hop)."; 1317 } 1318 identity path-ip-mh { 1319 base path-type; 1320 description "BFD on IP multihop paths."; 1321 reference 1322 "RFC 5883: Bidirectional Forwarding Detection (BFD) for 1323 Multihop Paths."; 1324 } 1325 identity path-mpls-te { 1326 base path-type; 1327 description 1328 "BFD on MPLS Traffic Engineering."; 1329 reference 1330 "RFC 5884: Bidirectional Forwarding Detection (BFD) 1331 for MPLS Label Switched Paths (LSPs)."; 1332 } 1333 identity path-mpls-lsp { 1334 base path-type; 1335 description 1336 "BFD on MPLS Label Switched Path."; 1338 reference 1339 "RFC 5884: Bidirectional Forwarding Detection (BFD) 1340 for MPLS Label Switched Paths (LSPs)."; 1341 } 1342 identity path-lag { 1343 base path-type; 1344 description 1345 "Micro-BFD on LAG member links."; 1346 reference 1347 "RFC 7130: Bidirectional Forwarding Detection (BFD) on 1348 Link Aggregation Group (LAG) Interfaces."; 1349 } 1351 identity encap-type { 1352 description 1353 "Base identity for BFD encapsulation type."; 1354 } 1355 identity encap-ip { 1356 base encap-type; 1357 description "BFD with IP encapsulation."; 1358 } 1360 /* 1361 * Type Definitions 1362 */ 1363 typedef discriminator { 1364 type uint32; 1365 description "BFD discriminator as described in RFC 5880."; 1366 } 1368 typedef state { 1369 type enumeration { 1370 enum adminDown { 1371 value 0; 1372 description "admindown"; 1373 } 1374 enum down { 1375 value 1; 1376 description "down"; 1377 } 1378 enum init { 1379 value 2; 1380 description "init"; 1381 } 1382 enum up { 1383 value 3; 1384 description "up"; 1385 } 1387 } 1388 description "BFD state as defined in RFC 5880."; 1389 } 1391 typedef multiplier { 1392 type uint8 { 1393 range 1..255; 1394 } 1395 description "BFD multiplier as described in RFC 5880."; 1396 } 1398 typedef hops { 1399 type uint8 { 1400 range 1..255; 1401 } 1402 description 1403 "This corresponds to Time To Live for IPv4 and corresponds to hop 1404 limit for IPv6."; 1405 } 1407 /* 1408 * Groupings 1409 */ 1410 grouping auth-parms { 1411 description 1412 "Grouping for BFD authentication parameters 1413 (see section 6.7 of RFC 5880)."; 1414 container authentication { 1415 if-feature authentication; 1416 presence 1417 "Enables BFD authentication (see section 6.7 of RFC 5880)."; 1418 description "Parameters for BFD authentication."; 1420 leaf key-chain { 1421 type kc:key-chain-ref; 1422 description "Name of the key-chain as per RFC 8177."; 1423 } 1425 leaf meticulous { 1426 type boolean; 1427 description 1428 "Enables meticulous mode as described in section 6.7 " + 1429 "of RFC 5880."; 1430 } 1431 } 1432 } 1434 grouping base-cfg-parms { 1435 description "BFD grouping for base config parameters."; 1436 leaf local-multiplier { 1437 type multiplier; 1438 default 3; 1439 description "Multiplier transmitted by local system."; 1440 } 1442 choice interval-config-type { 1443 description 1444 "Two interval values or one value used for both transmit and 1445 receive."; 1446 case tx-rx-intervals { 1447 leaf desired-min-tx-interval { 1448 type uint32; 1449 units microseconds; 1450 default 1000000; 1451 description 1452 "Desired minimum transmit interval of control packets."; 1453 } 1455 leaf required-min-rx-interval { 1456 type uint32; 1457 units microseconds; 1458 default 1000000; 1459 description 1460 "Required minimum receive interval of control packets."; 1461 } 1462 } 1463 case single-interval { 1464 if-feature single-minimum-interval; 1466 leaf min-interval { 1467 type uint32; 1468 units microseconds; 1469 default 1000000; 1470 description 1471 "Desired minimum transmit interval and required " + 1472 "minimum receive interval of control packets."; 1473 } 1474 } 1475 } 1476 } 1478 grouping client-cfg-parms { 1479 description 1480 "BFD grouping for configuration parameters 1481 used by clients of BFD, e.g. IGP or MPLS."; 1483 leaf enable { 1484 type boolean; 1485 default false; 1486 description 1487 "Indicates whether the BFD is enabled."; 1488 } 1489 uses base-cfg-parms; 1490 } 1492 grouping common-cfg-parms { 1493 description 1494 "BFD grouping for common configuration parameters."; 1496 uses base-cfg-parms; 1498 leaf demand-enabled { 1499 if-feature demand-mode; 1500 type boolean; 1501 default false; 1502 description 1503 "To enable demand mode."; 1504 } 1506 leaf admin-down { 1507 type boolean; 1508 default false; 1509 description 1510 "Is the BFD session administratively down."; 1511 } 1512 uses auth-parms; 1513 } 1515 grouping all-session { 1516 description "BFD session operational information"; 1517 leaf path-type { 1518 type identityref { 1519 base path-type; 1520 } 1521 config "false"; 1522 description 1523 "BFD path type, this indicates the path type that BFD is 1524 running on."; 1525 } 1526 leaf ip-encapsulation { 1527 type boolean; 1528 config "false"; 1529 description "Whether BFD encapsulation uses IP."; 1530 } 1531 leaf local-discriminator { 1532 type discriminator; 1533 config "false"; 1534 description "Local discriminator."; 1535 } 1536 leaf remote-discriminator { 1537 type discriminator; 1538 config "false"; 1539 description "Remote discriminator."; 1540 } 1541 leaf remote-multiplier { 1542 type multiplier; 1543 config "false"; 1544 description "Remote multiplier."; 1545 } 1546 leaf demand-capability { 1547 if-feature demand-mode; 1548 type boolean; 1549 config "false"; 1550 description "Local demand mode capability."; 1551 } 1552 leaf source-port { 1553 when "../ip-encapsulation = 'true'" { 1554 description 1555 "Source port valid only when IP encapsulation is used."; 1556 } 1557 type inet:port-number; 1558 config "false"; 1559 description "Source UDP port"; 1560 } 1561 leaf dest-port { 1562 when "../ip-encapsulation = 'true'" { 1563 description 1564 "Destination port valid only when IP encapsulation is used."; 1565 } 1566 type inet:port-number; 1567 config "false"; 1568 description "Destination UDP port."; 1569 } 1571 container session-running { 1572 config "false"; 1573 description "BFD session running information."; 1574 leaf session-index { 1575 type uint32; 1576 description 1577 "An index used to uniquely identify BFD sessions."; 1578 } 1579 leaf local-state { 1580 type state; 1581 description "Local state."; 1582 } 1583 leaf remote-state { 1584 type state; 1585 description "Remote state."; 1586 } 1587 leaf local-diagnostic { 1588 type iana-bfd-types:diagnostic; 1589 description "Local diagnostic."; 1590 } 1591 leaf remote-diagnostic { 1592 type iana-bfd-types:diagnostic; 1593 description "Remote diagnostic."; 1594 } 1595 leaf remote-authenticated { 1596 type boolean; 1597 description 1598 "Indicates whether incoming BFD control packets are 1599 authenticated."; 1600 } 1601 leaf remote-authentication-type { 1602 when "../remote-authenticated = 'true'" { 1603 description 1604 "Only valid when incoming BFD control packets are 1605 authenticated."; 1606 } 1607 if-feature authentication; 1608 type iana-bfd-types:auth-type; 1609 description 1610 "Authentication type of incoming BFD control packets."; 1611 } 1612 leaf detection-mode { 1613 type enumeration { 1614 enum async-with-echo { 1615 value "1"; 1616 description "Async with echo."; 1617 } 1618 enum async-without-echo { 1619 value "2"; 1620 description "Async without echo."; 1621 } 1622 enum demand-with-echo { 1623 value "3"; 1624 description "Demand with echo."; 1625 } 1626 enum demand-without-echo { 1627 value "4"; 1628 description "Demand without echo."; 1629 } 1630 } 1631 description "Detection mode."; 1632 } 1633 leaf negotiated-tx-interval { 1634 type uint32; 1635 units microseconds; 1636 description "Negotiated transmit interval."; 1637 } 1638 leaf negotiated-rx-interval { 1639 type uint32; 1640 units microseconds; 1641 description "Negotiated receive interval."; 1642 } 1643 leaf detection-time { 1644 type uint32; 1645 units microseconds; 1646 description "Detection time."; 1647 } 1648 leaf echo-tx-interval-in-use { 1649 when "../../path-type = 'bfd-types:path-ip-sh'" { 1650 description 1651 "Echo is supported for IP single-hop only."; 1652 } 1653 if-feature echo-mode; 1654 type uint32; 1655 units microseconds; 1656 description "Echo transmit interval in use."; 1657 } 1658 } 1660 container session-statistics { 1661 config "false"; 1662 description "BFD per-session statistics."; 1664 leaf create-time { 1665 type yang:date-and-time; 1666 description 1667 "Time and date when this session was created."; 1668 } 1669 leaf last-down-time { 1670 type yang:date-and-time; 1671 description 1672 "Time and date of last time this session went down."; 1673 } 1674 leaf last-up-time { 1675 type yang:date-and-time; 1676 description 1677 "Time and date of last time this session went up."; 1678 } 1679 leaf down-count { 1680 type yang:counter32; 1681 description 1682 "The number of times this session has transitioned in the 1683 down state."; 1684 } 1685 leaf admin-down-count { 1686 type yang:counter32; 1687 description 1688 "The number of times this session has transitioned in the 1689 admin-down state."; 1690 } 1691 leaf receive-packet-count { 1692 type yang:counter64; 1693 description 1694 "Count of received packets in this session. This includes 1695 valid and invalid received packets."; 1696 } 1697 leaf send-packet-count { 1698 type yang:counter64; 1699 description "Count of sent packets in this session."; 1700 } 1701 leaf receive-invalid-packet-count { 1702 type yang:counter64; 1703 description 1704 "Count of invalid received packets in this session."; 1705 } 1706 leaf send-failed-packet-count { 1707 type yang:counter64; 1708 description 1709 "Count of packets which failed to be sent in this session."; 1710 } 1711 } 1712 } 1714 grouping session-statistics-summary { 1715 description "Grouping for session statistics summary."; 1716 container summary { 1717 config false; 1718 description "BFD session statistics summary."; 1719 leaf number-of-sessions { 1720 type yang:gauge32; 1721 description "Number of BFD sessions."; 1722 } 1723 leaf number-of-sessions-up { 1724 type yang:gauge32; 1725 description "Number of BFD sessions currently in up state."; 1726 } 1727 leaf number-of-sessions-down { 1728 type yang:gauge32; 1729 description "Number of BFD sessions currently in down state."; 1730 } 1731 leaf number-of-sessions-admin-down { 1732 type yang:gauge32; 1733 description 1734 "Number of BFD sessions currently in admin-down state."; 1735 } 1736 } 1737 } 1739 grouping notification-parms { 1740 description 1741 "This group describes common parameters that will be sent " + 1742 "as part of BFD notification."; 1744 leaf local-discr { 1745 type discriminator; 1746 description "BFD local discriminator."; 1747 } 1749 leaf remote-discr { 1750 type discriminator; 1751 description "BFD remote discriminator."; 1752 } 1754 leaf new-state { 1755 type state; 1756 description "Current BFD state."; 1757 } 1759 leaf state-change-reason { 1760 type iana-bfd-types:diagnostic; 1761 description "BFD state change reason."; 1762 } 1764 leaf time-of-last-state-change { 1765 type yang:date-and-time; 1766 description 1767 "Calendar time of previous state change."; 1768 } 1770 leaf dest-addr { 1771 type inet:ip-address; 1772 description "BFD peer address."; 1773 } 1775 leaf source-addr { 1776 type inet:ip-address; 1777 description "BFD local address."; 1778 } 1780 leaf session-index { 1781 type uint32; 1782 description "An index used to uniquely identify BFD sessions."; 1783 } 1785 leaf path-type { 1786 type identityref { 1787 base path-type; 1788 } 1789 description "BFD path type."; 1790 } 1791 } 1792 } 1794 1796 2.14. BFD top-level YANG Module 1798 This YANG module imports and augments "/routing/control-plane- 1799 protocols/control-plane-protocol" from [RFC8349]. 1801 file "ietf-bfd@2018-03-20.yang" 1803 module ietf-bfd { 1805 yang-version 1.1; 1807 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd"; 1809 prefix "bfd"; 1811 import ietf-bfd-types { 1812 prefix "bfd-types"; 1813 // RFC Ed.: replace XXXX with actual RFC number and remove this 1814 // note 1815 reference "RFC XXXX: YANG Data Model for BFD"; 1816 } 1818 import ietf-routing { 1819 prefix "rt"; 1820 reference 1821 "RFC 8349: A YANG Data Model for Routing Management 1822 (NMDA version)"; 1823 } 1825 organization "IETF BFD Working Group"; 1827 contact 1828 "WG Web: 1829 WG List: 1831 Editors: Reshad Rahman (rrahman@cisco.com), 1832 Lianshu Zheng (vero.zheng@huawei.com), 1833 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1835 description 1836 "This module contains the YANG definition for BFD parameters as 1837 per RFC 5880. 1839 Copyright (c) 2018 IETF Trust and the persons 1840 identified as authors of the code. All rights reserved. 1842 Redistribution and use in source and binary forms, with or 1843 without modification, is permitted pursuant to, and subject 1844 to the license terms contained in, the Simplified BSD License 1845 set forth in Section 4.c of the IETF Trust's Legal Provisions 1846 Relating to IETF Documents 1847 (http://trustee.ietf.org/license-info). 1849 This version of this YANG module is part of RFC XXXX; see 1850 the RFC itself for full legal notices."; 1852 // RFC Ed.: replace XXXX with actual RFC number and remove this 1853 // note 1855 reference "RFC XXXX"; 1857 revision 2018-03-20 { 1858 description "Initial revision."; 1859 reference "RFC XXXX: YANG Data Model for BFD"; 1860 } 1862 augment "/rt:routing/rt:control-plane-protocols/" 1863 + "rt:control-plane-protocol" { 1864 when "derived-from-or-self(rt:type, 'bfd-types:bfdv1')" { 1865 description 1866 "This augmentation is only valid for a control-plane protocol 1867 instance of BFD (type 'bfdv1')."; 1868 } 1869 description "BFD augmentation."; 1871 container bfd { 1872 description "BFD top level container."; 1874 uses bfd-types:session-statistics-summary; 1875 } 1876 } 1877 } 1879 1881 2.15. BFD IP single-hop YANG Module 1883 This YANG module imports "interface-ref" from [RFC8343], typedefs 1884 from [RFC6991] and augments "/routing/control-plane-protocols/ 1885 control-plane-protocol" from [RFC8349]. 1887 file "ietf-bfd-ip-sh@2018-03-20.yang" 1889 module ietf-bfd-ip-sh { 1891 yang-version 1.1; 1893 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-ip-sh"; 1895 prefix "bfd-ip-sh"; 1897 import ietf-bfd-types { 1898 prefix "bfd-types"; 1899 } 1901 import ietf-bfd { 1902 prefix "bfd"; 1903 } 1905 import ietf-interfaces { 1906 prefix "if"; 1907 reference 1908 "RFC 8343: A YANG Data Model for Interface Management"; 1909 } 1911 import ietf-inet-types { 1912 prefix "inet"; 1913 reference "RFC 6991: Common YANG Data Types"; 1914 } 1915 import ietf-routing { 1916 prefix "rt"; 1917 reference 1918 "RFC 8349: A YANG Data Model for Routing Management 1919 (NMDA version)"; 1920 } 1922 organization "IETF BFD Working Group"; 1924 contact 1925 "WG Web: 1926 WG List: 1928 Editors: Reshad Rahman (rrahman@cisco.com), 1929 Lianshu Zheng (vero.zheng@huawei.com), 1930 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1932 description 1933 "This module contains the YANG definition for BFD IP single-hop 1934 as per RFC 5881. 1936 Copyright (c) 2018 IETF Trust and the persons 1937 identified as authors of the code. All rights reserved. 1939 Redistribution and use in source and binary forms, with or 1940 without modification, is permitted pursuant to, and subject 1941 to the license terms contained in, the Simplified BSD License 1942 set forth in Section 4.c of the IETF Trust's Legal Provisions 1943 Relating to IETF Documents 1944 (http://trustee.ietf.org/license-info). 1946 This version of this YANG module is part of RFC XXXX; see 1947 the RFC itself for full legal notices."; 1949 // RFC Ed.: replace XXXX with actual RFC number and remove this 1950 // note 1952 reference "RFC XXXX"; 1954 revision 2018-03-20 { 1955 description "Initial revision."; 1956 reference "RFC XXXX: A YANG data model for BFD IP single-hop"; 1957 } 1959 /* 1960 * Augments 1961 */ 1962 augment "/rt:routing/rt:control-plane-protocols/" 1963 + "rt:control-plane-protocol/bfd:bfd" { 1964 description "BFD augmentation for IP single-hop"; 1965 container ip-sh { 1966 description "BFD IP single-hop top level container"; 1968 uses bfd-types:session-statistics-summary; 1970 container sessions { 1971 description 1972 "BFD IP single-hop sessions."; 1973 list session { 1974 key "interface dest-addr"; 1975 description "List of IP single-hop sessions."; 1976 leaf interface { 1977 type if:interface-ref; 1978 description 1979 "Interface on which the BFD session is running."; 1980 } 1981 leaf dest-addr { 1982 type inet:ip-address; 1983 description "IP address of the peer."; 1984 } 1985 leaf source-addr { 1986 type inet:ip-address; 1987 description "Local IP address."; 1988 } 1990 uses bfd-types:common-cfg-parms; 1992 uses bfd-types:all-session; 1993 } 1994 } 1995 list interfaces { 1996 key "interface"; 1997 description "List of interfaces."; 1998 leaf interface { 1999 type if:interface-ref; 2000 description 2001 "BFD information for this interface."; 2002 } 2004 uses bfd-types:auth-parms; 2005 } 2006 } 2007 } 2009 /* 2010 * Notifications 2011 */ 2012 notification singlehop-notification { 2013 description 2014 "Notification for BFD single-hop session state change. An " + 2015 "implementation may rate-limit notifications, e.g. when a" + 2016 "session is continuously changing state."; 2018 uses bfd-types:notification-parms; 2020 leaf interface { 2021 type if:interface-ref; 2022 description "Interface to which this BFD session belongs to."; 2023 } 2025 leaf echo-enabled { 2026 type boolean; 2027 description "Was echo enabled for BFD."; 2028 } 2029 } 2031 } 2033 2035 2.16. BFD IP multihop YANG Module 2037 This YANG module imports typedefs from [RFC6991] and augments 2038 "/routing/control-plane-protocols/control-plane-protocol" from 2039 [RFC8349]. 2041 file "ietf-bfd-ip-mh@2018-03-20.yang" 2043 module ietf-bfd-ip-mh { 2045 yang-version 1.1; 2047 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-ip-mh"; 2049 prefix "bfd-ip-mh"; 2051 import ietf-bfd-types { 2052 prefix "bfd-types"; 2053 } 2055 import ietf-bfd { 2056 prefix "bfd"; 2057 } 2058 import ietf-inet-types { 2059 prefix "inet"; 2060 reference "RFC 6991: Common YANG Data Types"; 2061 } 2063 import ietf-routing { 2064 prefix "rt"; 2065 reference 2066 "RFC 8349: A YANG Data Model for Routing Management 2067 (NMDA version)"; 2068 } 2070 organization "IETF BFD Working Group"; 2072 contact 2073 "WG Web: 2074 WG List: 2076 Editors: Reshad Rahman (rrahman@cisco.com), 2077 Lianshu Zheng (vero.zheng@huawei.com), 2078 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2080 description 2081 "This module contains the YANG definition for BFD IP multi-hop 2082 as per RFC 5883. 2084 Copyright (c) 2018 IETF Trust and the persons 2085 identified as authors of the code. All rights reserved. 2087 Redistribution and use in source and binary forms, with or 2088 without modification, is permitted pursuant to, and subject 2089 to the license terms contained in, the Simplified BSD License 2090 set forth in Section 4.c of the IETF Trust's Legal Provisions 2091 Relating to IETF Documents 2092 (http://trustee.ietf.org/license-info). 2094 This version of this YANG module is part of RFC XXXX; see 2095 the RFC itself for full legal notices."; 2097 // RFC Ed.: replace XXXX with actual RFC number and remove this 2098 // note 2100 reference "RFC XXXX"; 2102 revision 2018-03-20 { 2103 description "Initial revision."; 2104 reference "RFC XXXX: A YANG data model for BFD IP multihop."; 2105 } 2106 /* 2107 * Augments 2108 */ 2109 augment "/rt:routing/rt:control-plane-protocols/" 2110 + "rt:control-plane-protocol/bfd:bfd" { 2111 description "BFD augmentation for IP multihop."; 2112 container ip-mh { 2113 description "BFD IP multihop top level container."; 2115 uses bfd-types:session-statistics-summary; 2117 container session-groups { 2118 description 2119 "BFD IP multi-hop session groups."; 2120 list session-group { 2121 key "source-addr dest-addr"; 2122 description 2123 "Group of BFD IP multi-hop sessions (for ECMP). A " + 2124 "group of sessions is between 1 source and 1 " + 2125 "destination, each session has a different field " + 2126 "in UDP/IP hdr for ECMP."; 2128 leaf source-addr { 2129 type inet:ip-address; 2130 description 2131 "Local IP address."; 2132 } 2133 leaf dest-addr { 2134 type inet:ip-address; 2135 description 2136 "IP address of the peer."; 2137 } 2138 uses bfd-types:common-cfg-parms; 2140 leaf tx-ttl { 2141 type bfd-types:hops; 2142 default 255; 2143 description "Hop count of outgoing BFD control packets."; 2144 } 2145 leaf rx-ttl { 2146 type bfd-types:hops; 2147 mandatory true; 2148 description 2149 "Minimum allowed hop count value for incoming BFD control 2150 packets. Control packets whose hop count is lower than 2151 this value are dropped."; 2152 } 2153 list sessions { 2154 config false; 2155 description 2156 "The multiple BFD sessions between a source and a " + 2157 "destination."; 2158 uses bfd-types:all-session; 2159 } 2160 } 2161 } 2162 } 2163 } 2165 /* 2166 * Notifications 2167 */ 2168 notification multihop-notification { 2169 description 2170 "Notification for BFD multi-hop session state change. An " + 2171 "implementation may rate-limit notifications, e.g. when a" + 2172 "session is continuously changing state."; 2174 uses bfd-types:notification-parms; 2175 } 2176 } 2178 2180 2.17. BFD over LAG YANG Module 2182 This YANG module imports "interface-ref" from [RFC8343], typedefs 2183 from [RFC6991] and augments "/routing/control-plane-protocols/ 2184 control-plane-protocol" from [RFC8349]. 2186 file "ietf-bfd-lag@2018-03-20.yang" 2188 module ietf-bfd-lag { 2190 yang-version 1.1; 2192 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-lag"; 2194 prefix "bfd-lag"; 2196 import ietf-bfd-types { 2197 prefix "bfd-types"; 2198 } 2200 import ietf-bfd { 2201 prefix "bfd"; 2203 } 2205 import ietf-interfaces { 2206 prefix "if"; 2207 reference 2208 "RFC 8349: A YANG Data Model for Routing Management 2209 (NMDA version)"; 2210 } 2212 import ietf-inet-types { 2213 prefix "inet"; 2214 reference "RFC 6991: Common YANG Data Types"; 2215 } 2217 import ietf-routing { 2218 prefix "rt"; 2219 // RFC Ed.: replace XXXX with actual RFC number of 2220 // draft-ietf-netmod-rfc8022bis and remove this note. 2221 reference 2222 "RFC XXXX: A YANG Data Model for Routing Management"; 2223 } 2225 organization "IETF BFD Working Group"; 2227 contact 2228 "WG Web: 2229 WG List: 2231 Editors: Reshad Rahman (rrahman@cisco.com), 2232 Lianshu Zheng vero.zheng@huawei.com), 2233 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2235 description 2236 "This module contains the YANG definition for BFD over LAG 2237 interfaces as per RFC7130. 2239 Copyright (c) 2018 IETF Trust and the persons 2240 identified as authors of the code. All rights reserved. 2242 Redistribution and use in source and binary forms, with or 2243 without modification, is permitted pursuant to, and subject 2244 to the license terms contained in, the Simplified BSD License 2245 set forth in Section 4.c of the IETF Trust's Legal Provisions 2246 Relating to IETF Documents 2247 (http://trustee.ietf.org/license-info). 2249 This version of this YANG module is part of RFC XXXX; see 2250 the RFC itself for full legal notices."; 2252 // RFC Ed.: replace XXXX with actual RFC number and remove this 2253 // note 2255 reference "RFC XXXX"; 2257 revision 2018-03-20 { 2258 description "Initial revision."; 2259 reference "RFC XXXX: A YANG data model for BFD over LAG"; 2260 } 2262 /* 2263 * Augments 2264 */ 2265 augment "/rt:routing/rt:control-plane-protocols/" 2266 + "rt:control-plane-protocol/bfd:bfd" { 2267 description "BFD augmentation for LAG"; 2268 container lag { 2269 description "BFD over LAG top level container"; 2271 container micro-bfd-ipv4-session-statistics { 2272 description "Micro-BFD IPv4 session counters."; 2273 uses bfd-types:session-statistics-summary; 2274 } 2275 container micro-bfd-ipv6-session-statistics { 2276 description "Micro-BFD IPv6 session counters."; 2277 uses bfd-types:session-statistics-summary; 2278 } 2280 container sessions { 2281 description 2282 "BFD over LAG sessions"; 2283 list session { 2284 key "lag-name"; 2285 description "List of BFD over LAG sessions."; 2286 leaf lag-name { 2287 type if:interface-ref ; 2288 description "Name of the LAG"; 2289 } 2290 leaf ipv4-dest-addr { 2291 type inet:ipv4-address; 2292 description 2293 "IPv4 address of the peer, for IPv4 micro-BFD."; 2294 } 2295 leaf ipv6-dest-addr { 2296 type inet:ipv6-address; 2297 description 2298 "IPv6 address of the peer, for IPv6 micro-BFD."; 2299 } 2300 uses bfd-types:common-cfg-parms; 2302 leaf use-ipv4 { 2303 type boolean; 2304 description "Using IPv4 micro-BFD."; 2305 } 2306 leaf use-ipv6 { 2307 type boolean; 2308 description "Using IPv6 micro-BFD."; 2309 } 2311 list member-links { 2312 key "member-link"; 2313 config false; 2314 description 2315 "Micro-BFD over LAG. This represents one member link."; 2317 leaf member-link { 2318 type if:interface-ref; 2319 description 2320 "Member link on which micro-BFD is running."; 2321 } 2322 container micro-bfd-ipv4 { 2323 when "../../use-ipv4 = 'true'" { 2324 description "Needed only if IPv4 is used."; 2325 } 2326 description 2327 "Micro-BFD IPv4 session state on member link."; 2328 uses bfd-types:all-session; 2329 } 2330 container micro-bfd-ipv6 { 2331 when "../../use-ipv6 = 'true'" { 2332 description "Needed only if IPv6 is used."; 2333 } 2334 description 2335 "Micro-BFD IPv6 session state on member link."; 2336 uses bfd-types:all-session; 2337 } 2338 } 2339 } 2340 } 2341 } 2342 } 2344 /* 2345 * Notifications 2346 */ 2347 notification lag-notification { 2348 description 2349 "Notification for BFD over LAG session state change. " + 2350 "An implementation may rate-limit notifications, e.g. when a" + 2351 "session is continuously changing state."; 2353 uses bfd-types:notification-parms; 2355 leaf lag-name { 2356 type if:interface-ref; 2357 description "LAG interface name."; 2358 } 2360 leaf member-link { 2361 type if:interface-ref; 2362 description "Member link on which BFD is running."; 2363 } 2364 } 2365 } 2367 2369 2.18. BFD over MPLS YANG Module 2371 This YANG module imports typedefs from [RFC6991] and augments 2372 "/routing/control-plane-protocols/control-plane-protocol" from 2373 [RFC8349]. 2375 file "ietf-bfd-mpls@2018-03-20.yang" 2377 module ietf-bfd-mpls { 2379 yang-version 1.1; 2381 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-mpls"; 2383 prefix "bfd-mpls"; 2385 import ietf-bfd-types { 2386 prefix "bfd-types"; 2387 } 2389 import ietf-bfd { 2390 prefix "bfd"; 2391 } 2393 import ietf-inet-types { 2394 prefix "inet"; 2395 reference "RFC 6991: Common YANG Data Types"; 2397 } 2399 import ietf-routing { 2400 prefix "rt"; 2401 reference 2402 "RFC 8349: A YANG Data Model for Routing Management 2403 (NMDA version)"; 2404 } 2406 organization "IETF BFD Working Group"; 2408 contact 2409 "WG Web: 2410 WG List: 2412 Editors: Reshad Rahman (rrahman@cisco.com), 2413 Lianshu Zheng (vero.zheng@huawei.com), 2414 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2416 description 2417 "This module contains the YANG definition for BFD parameters for 2418 MPLS LSPs as per RFC 5884. 2420 Copyright (c) 2018 IETF Trust and the persons 2421 identified as authors of the code. All rights reserved. 2423 Redistribution and use in source and binary forms, with or 2424 without modification, is permitted pursuant to, and subject 2425 to the license terms contained in, the Simplified BSD License 2426 set forth in Section 4.c of the IETF Trust's Legal Provisions 2427 Relating to IETF Documents 2428 (http://trustee.ietf.org/license-info). 2430 This version of this YANG module is part of RFC XXXX; see 2431 the RFC itself for full legal notices."; 2433 // RFC Ed.: replace XXXX with actual RFC number and remove this 2434 // note 2436 reference "RFC XXXX"; 2438 revision 2018-03-20 { 2439 description "Initial revision."; 2440 reference "RFC XXXX: A YANG data model for BFD over MPLS LSPs"; 2441 } 2443 /* 2444 * Identity definitions 2445 */ 2446 identity encap-gach { 2447 base bfd-types:encap-type; 2448 description 2449 "BFD with G-ACh encapsulation as per RFC 5586."; 2450 } 2452 identity encap-ip-gach { 2453 base bfd-types:encap-type; 2454 description 2455 "BFD with IP and G-ACh encapsulation as per RFC 5586."; 2456 } 2458 /* 2459 * Groupings 2460 */ 2461 grouping encap-cfg { 2462 description "Configuration for BFD encapsulation"; 2464 leaf encap { 2465 type identityref { 2466 base bfd-types:encap-type; 2467 } 2468 default bfd-types:encap-ip; 2469 description "BFD encapsulation"; 2470 } 2471 } 2473 grouping mpls-dest-address { 2474 description "Destination address as per RFC 5884."; 2476 leaf mpls-dest-address { 2477 type inet:ip-address; 2478 config "false"; 2479 description 2480 "Destination address as per RFC 5884. 2481 Needed if IP encapsulation is used."; 2482 } 2483 } 2485 /* 2486 * Augments 2487 */ 2488 augment "/rt:routing/rt:control-plane-protocols/" 2489 + "rt:control-plane-protocol/bfd:bfd" { 2490 description "BFD augmentation for MPLS."; 2491 container mpls { 2492 description "BFD MPLS top level container."; 2493 uses bfd-types:session-statistics-summary; 2495 container egress { 2496 description "Egress configuration."; 2498 uses bfd-types:client-cfg-parms; 2500 uses bfd-types:auth-parms; 2501 } 2503 container session-groups { 2504 description 2505 "BFD over MPLS session groups."; 2506 list session-group { 2507 key "mpls-fec"; 2508 description 2509 "Group of BFD MPLS sessions (for ECMP). A group of " + 2510 "sessions is for 1 FEC, each session has a different " + 2511 "field in UDP/IP hdr for ECMP."; 2512 leaf mpls-fec { 2513 type inet:ip-prefix; 2514 description "MPLS FEC."; 2515 } 2517 uses bfd-types:common-cfg-parms; 2519 list sessions { 2520 config false; 2521 description 2522 "The BFD sessions for an MPLS FEC. Local " + 2523 "discriminator is unique for each session in the " + 2524 "group."; 2525 uses bfd-types:all-session; 2527 uses bfd-mpls:mpls-dest-address; 2528 } 2529 } 2530 } 2531 } 2532 } 2534 /* 2535 * Notifications 2536 */ 2537 notification mpls-notification { 2538 description 2539 "Notification for BFD over MPLS FEC session state change. " + 2540 "An implementation may rate-limit notifications, e.g. when a" + 2541 "session is continuously changing state."; 2543 uses bfd-types:notification-parms; 2545 leaf mpls-dest-address { 2546 type inet:ip-address; 2547 description 2548 "Destination address as per RFC 5884. 2549 Needed if IP encapsulation is used."; 2550 } 2551 } 2552 } 2554 2556 2.19. BFD over MPLS-TE YANG Module 2558 This YANG module imports and augments "/te/tunnels/tunnel" from 2559 [I-D.ietf-teas-yang-te]. 2561 file "ietf-bfd-mpls-te@2018-03-20.yang" 2563 module ietf-bfd-mpls-te { 2565 yang-version 1.1; 2567 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-mpls-te"; 2569 prefix "bfd-mpls-te"; 2571 import ietf-bfd-types { 2572 prefix "bfd-types"; 2573 } 2575 import ietf-bfd { 2576 prefix "bfd"; 2577 } 2579 import ietf-bfd-mpls { 2580 prefix "bfd-mpls"; 2581 } 2583 import ietf-te { 2584 prefix "te"; 2585 } 2587 import ietf-routing { 2588 prefix "rt"; 2589 reference 2590 "RFC 8349: A YANG Data Model for Routing Management 2591 (NMDA version)"; 2592 } 2594 organization "IETF BFD Working Group"; 2596 contact 2597 "WG Web: 2598 WG List: 2600 Editors: Reshad Rahman (rrahman@cisco.com), 2601 Lianshu Zheng (vero.zheng@huawei.com), 2602 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2604 description 2605 "This module contains the YANG definition for BFD parameters for 2606 MPLS Traffic Engineering as per RFC 5884. 2608 Copyright (c) 2018 IETF Trust and the persons 2609 identified as authors of the code. All rights reserved. 2611 Redistribution and use in source and binary forms, with or 2612 without modification, is permitted pursuant to, and subject 2613 to the license terms contained in, the Simplified BSD License 2614 set forth in Section 4.c of the IETF Trust's Legal Provisions 2615 Relating to IETF Documents 2616 (http://trustee.ietf.org/license-info). 2618 This version of this YANG module is part of RFC XXXX; see 2619 the RFC itself for full legal notices."; 2621 // RFC Ed.: replace XXXX with actual RFC number and remove this 2622 // note 2624 reference "RFC XXXX"; 2626 revision 2018-03-20 { 2627 description "Initial revision."; 2628 reference "RFC XXXX: A YANG data model for BFD over MPLS-TE"; 2629 } 2631 /* 2632 * Augments 2633 */ 2634 augment "/rt:routing/rt:control-plane-protocols/" 2635 + "rt:control-plane-protocol/bfd:bfd" { 2636 description "BFD augmentation for MPLS-TE."; 2637 container mpls-te { 2638 description "BFD MPLS-TE top level container."; 2640 container egress { 2641 description "Egress configuration."; 2643 uses bfd-types:client-cfg-parms; 2645 uses bfd-types:auth-parms; 2646 } 2648 uses bfd-types:session-statistics-summary; 2649 } 2650 } 2652 augment "/te:te/te:tunnels/te:tunnel" { 2653 description "BFD configuration on MPLS-TE tunnel."; 2655 uses bfd-types:common-cfg-parms; 2657 uses bfd-mpls:encap-cfg; 2658 } 2660 augment "/te:te/te:lsps-state/te:lsp" { 2661 when "/te:te/te:lsps-state/te:lsp/te:origin-type != 'transit'" { 2662 description "BFD information not needed at transit points."; 2663 } 2664 description "BFD state information on MPLS-TE LSP."; 2666 uses bfd-types:all-session; 2668 uses bfd-mpls:mpls-dest-address; 2669 } 2671 /* 2672 * Notifications 2673 */ 2674 notification mpls-te-notification { 2675 description 2676 "Notification for BFD over MPLS-TE session state change. " + 2677 "An implementation may rate-limit notifications, e.g. when a" + 2678 "session is continuously changing state."; 2680 uses bfd-types:notification-parms; 2682 uses bfd-mpls:mpls-dest-address; 2684 leaf tunnel-name { 2685 type string; 2686 description "MPLS-TE tunnel on which BFD was running."; 2687 } 2688 } 2689 } 2691 2693 3. Data Model examples 2695 This section presents some simple and illustrative examples on how to 2696 configure BFD. 2698 3.1. IP single-hop 2700 The following is an example configuration for a BFD IP single-hop 2701 session. The desired transmit interval and the required receive 2702 interval are both set to 10ms. 2704 2705 2706 2707 2708 eth0 2709 2710 ianaift:ethernetCsmacd 2711 2712 2713 2714 2715 2716 2717 2719 bfd-types:bfdv1 2720 2721 name:BFD 2722 2723 2724 2725 2726 eth0 2727 2001:db8:0:113::101 2728 10000 2729 2730 10000 2731 2732 2733 2734 2735 2736 2737 2738 2739 2741 3.2. IP multihop 2743 The following is an example configuration for a BFD IP multihop 2744 session group. The desired transmit interval and the required 2745 receive interval are both set to 150ms. 2747 2748 2749 2750 2751 2752 2754 bfd-types:bfdv1 2755 2756 name:BFD 2757 2758 2759 2760 2761 2001:db8:0:113::103 2762 2001:db8:0:114::100 2763 2764 150000 2765 2766 2767 150000 2768 2769 240 2770 2771 2772 2773 2774 2775 2776 2777 2779 3.3. LAG 2781 The following is an example of BFD configuration for a LAG session. 2782 In this case, an interface named "Bundle-Ether1" of interface type 2783 "ieee802eadLag" has a desired transmit and required receive interval 2784 set to 10ms. 2786 2787 2788 2789 2790 Bundle-Ether1 2791 2792 ianaift:ieee8023adLag 2793 2794 2795 2796 2797 2798 2799 2801 bfd-types:bfdv1 2802 2803 name:BFD 2804 2805 2806 2807 2808 Bundle-Ether1 2809 2001:db8:112::16 2810 2811 100000 2812 2813 2814 100000 2815 2816 true 2817 2818 2819 2820 2821 2822 2823 2824 2826 3.4. MPLS 2828 The following is an example of BFD configured for an MPLS LSP. In 2829 this case, the desired transmit and required receive interval set to 2830 250ms. 2832 2833 2834 2835 2836 2837 2839 bfd-types:bfdv1 2840 2841 name:BFD 2842 2843 2844 2845 2846 2001:db8:114::/116 2847 2848 250000 2849 2850 2851 250000 2852 2853 2854 2855 2856 2857 2858 2859 2860 2862 4. Security Considerations 2864 The YANG module specified in this document defines a schema for data 2865 that is designed to be accessed via network management protocols such 2866 as NETCONF [RFC6241] or RESTCONF [RFC8040]. The lowest NETCONF layer 2867 is the secure transport layer, and the mandatory-to-implement secure 2868 transport is Secure Shell (SSH) [RFC6242]. The lowest RESTCONF layer 2869 is HTTPS, and the mandatory-to-implement secure transport is TLS 2870 [RFC5246]. 2872 The NETCONF access control model [RFC6536] provides the means to 2873 restrict access for particular NETCONF or RESTCONF users to a 2874 preconfigured subset of all available NETCONF or RESTCONF protocol 2875 operations and content. 2877 There are a number of data nodes defined in this YANG module that are 2878 writable/creatable/deletable (i.e., config true, which is the 2879 default). These data nodes may be considered sensitive or vulnerable 2880 in some network environments. Write operations (e.g., edit-config) 2881 to these data nodes without proper protection can have a negative 2882 effect on network operations. These are the subtrees and data nodes 2883 and their sensitivity/vulnerability: 2885 /routing/control-plane-protocols/control-plane-protocol/bfd/ip-sh/ 2886 sessions: the list specifies the IP single-hop BFD sessions. 2888 /routing/control-plane-protocols/control-plane-protocol/bfd/ip-sh/ 2889 sessions: data nodes local-multiplier, desired-min-tx-interval, 2890 required-min-rx-interval, min-interval and authentication all impact 2891 the BFD IP single-hop session. 2893 /routing/control-plane-protocols/control-plane-protocol/bfd/ip-mh/ 2894 session-group: the list specifies the IP multi-hop BFD session 2895 groups. 2897 /routing/control-plane-protocols/control-plane-protocol/bfd/ip-mh/ 2898 session-group: data nodes local-multiplier, desired-min-tx-interval, 2899 required-min-rx-interval, min-interval and authentication all impact 2900 the BFD IP multi-hop session. 2902 /routing/control-plane-protocols/control-plane-protocol/bfd/lag/ 2903 sessions: the list specifies the BFD sessions over LAG. 2905 /routing/control-plane-protocols/control-plane-protocol/bfd/lag/ 2906 sessions: data nodes local-multiplier, desired-min-tx-interval, 2907 required-min-rx-interval, min-interval and authentication all impact 2908 the BFD over LAG session. 2910 /routing/control-plane-protocols/control-plane-protocol/bfd/mpls/ 2911 session-group: the list specifies the session groups for BFD over 2912 MPLS. 2914 /routing/control-plane-protocols/control-plane-protocol/bfd/mpls/ 2915 session-group: data nodes local-multiplier, desired-min-tx-interval, 2916 required-min-rx-interval, min-interval and authentication all impact 2917 the BFD over MPLS LSPs session. 2919 /routing/control-plane-protocols/control-plane-protocol/bfd/mpls/ 2920 egress: data nodes local-multiplier, desired-min-tx-interval, 2921 required-min-rx-interval, min-interval and authentication all impact 2922 the BFD over MPLS LSPs sessions for which this device is an MPLS LSP 2923 egress node. 2925 /te/tunnels/tunnel: data nodes local-multiplier, desired-min-tx- 2926 interval, required-min-rx-interval, min-interval and authentication 2927 all impact the BFD session over the MPLS-TE tunnel. 2929 /routing/control-plane-protocols/control-plane-protocol/bfd/mpls-te/ 2930 egress: data nodes local-multiplier, desired-min-tx-interval, 2931 required-min-rx-interval, min-interval and authentication all impact 2932 the BFD over MPLS-TE sessions for which this device is an MPLS-TE 2933 egress node. 2935 The YANG module has writeable data nodes which can be used for 2936 creation of BFD sessions and modification of BFD session parameters. 2937 The system should "police" creation of BFD sessions to prevent new 2938 sessions from causing existing BFD sessions to fail. For BFD session 2939 modification, the BFD protocol has mechanisms in place which allow 2940 for in service modification. 2942 Some of the readable data nodes in this YANG module may be considered 2943 sensitive or vulnerable in some network environments. It is thus 2944 important to control read access (e.g., via get, get-config, or 2945 notification) to these data nodes. These are the subtrees and data 2946 nodes and their sensitivity/vulnerability: 2948 /routing/control-plane-protocols/control-plane-protocol/bfd/ip-sh/ 2949 summary: access to this information discloses the number of BFD IP 2950 single-hop sessions which are up, down and admin-down. The counters 2951 include BFD sessions for which the user does not have read-access. 2953 /routing/control-plane-protocols/control-plane-protocol/bfd/ip-mh/ 2954 summary: access to this information discloses the number of BFD IP 2955 multi-hop sessions which are up, down and admin-down. The counters 2956 include BFD sessions for which the user does not have read-access. 2958 /routing/control-plane-protocols/control-plane-protocol/bfd/lag/ 2959 micro-bfd-ipv4-session-statistics/summary: access to this information 2960 discloses the number of micro BFD IPv4 LAG sessions which are up, 2961 down and admin-down. The counters include BFD sessions for which the 2962 user does not have read-access. 2964 /routing/control-plane-protocols/control-plane-protocol/bfd/lag/ 2965 micro-bfd-ipv6-session-statistics/summary: access to this information 2966 discloses the number of micro BFD IPv6 LAG sessions which are up, 2967 down and admin-down. The counters include BFD sessions for which the 2968 user does not have read-access. 2970 /routing/control-plane-protocols/control-plane-protocol/bfd/mpls/ 2971 summary: access to this information discloses the number of BFD 2972 sessions over MPLS LSPs which are up, down and admin-down. The 2973 counters include BFD sessions for which the user does not have read- 2974 access. 2976 /routing/control-plane-protocols/control-plane-protocol/bfd/mpls-te/ 2977 summary: access to this information discloses the number of BFD 2978 sessions over MPLS-TE which are up, down and admin-down. The 2979 counters include BFD sessions for which the user does not have read- 2980 access. 2982 5. IANA Considerations 2984 The IANA is requested to as assign a new namespace URI from the IETF 2985 XML registry. 2987 This document registers the following namesace URIs in the IETF XML 2988 registry [RFC3688]: 2990 -------------------------------------------------------------------- 2992 URI: urn:ietf:params:xml:ns:yang:ietf-bfd 2994 Registrant Contact: The IESG. 2996 XML: N/A, the requested URI is an XML namespace. 2998 -------------------------------------------------------------------- 3000 -------------------------------------------------------------------- 3002 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-ip-sh 3004 Registrant Contact: The IESG. 3006 XML: N/A, the requested URI is an XML namespace. 3008 -------------------------------------------------------------------- 3010 -------------------------------------------------------------------- 3012 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-mh 3014 Registrant Contact: The IESG. 3016 XML: N/A, the requested URI is an XML namespace. 3018 -------------------------------------------------------------------- 3020 -------------------------------------------------------------------- 3021 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-lag 3023 Registrant Contact: The IESG. 3025 XML: N/A, the requested URI is an XML namespace. 3027 -------------------------------------------------------------------- 3029 -------------------------------------------------------------------- 3031 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-mpls 3033 Registrant Contact: The IESG. 3035 XML: N/A, the requested URI is an XML namespace. 3037 -------------------------------------------------------------------- 3039 -------------------------------------------------------------------- 3041 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-mpls-te 3043 Registrant Contact: The IESG. 3045 XML: N/A, the requested URI is an XML namespace. 3047 -------------------------------------------------------------------- 3049 5.1. IANA-Maintained iana-bfd-types module 3051 This document defines the initial version of the IANA-maintained 3052 iana-bfd-types YANG module. 3054 The iana-bfd-types YANG module mirrors the "BFD Diagnostic Codes" 3055 registry and "BFD Authentication Types" registry at 3056 https://www.iana.org/assignments/bfd-parameters/bfd-parameters.xhtml. 3057 Whenever that registry changes, IANA must update the iana-bfd-types 3058 YANG module. 3060 6. Acknowledgements 3062 We would also like to thank Nobo Akiya and Jeff Haas for their 3063 encouragement on this work. We would also like to thank Rakesh 3064 Gandhi and Tarek Saad for their help on the MPLS-TE model. We would 3065 also like to thank Acee Lindem for his guidance. 3067 7. References 3069 7.1. Normative References 3071 [I-D.ietf-mpls-base-yang] 3072 Saad, T., Raza, K., Gandhi, R., Liu, X., and V. Beeram, "A 3073 YANG Data Model for MPLS Base", draft-ietf-mpls-base- 3074 yang-06 (work in progress), February 2018. 3076 [I-D.ietf-netmod-rfc7277bis] 3077 Bjorklund, M., "A YANG Data Model for IP Management", 3078 draft-ietf-netmod-rfc7277bis-03 (work in progress), 3079 January 2018. 3081 [I-D.ietf-netmod-yang-tree-diagrams] 3082 Bjorklund, M. and L. Berger, "YANG Tree Diagrams", draft- 3083 ietf-netmod-yang-tree-diagrams-06 (work in progress), 3084 February 2018. 3086 [I-D.ietf-teas-yang-te] 3087 Saad, T., Gandhi, R., Liu, X., Beeram, V., Shah, H., and 3088 I. Bryskin, "A YANG Data Model for Traffic Engineering 3089 Tunnels and Interfaces", draft-ietf-teas-yang-te-14 (work 3090 in progress), March 2018. 3092 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 3093 Requirement Levels", BCP 14, RFC 2119, 3094 DOI 10.17487/RFC2119, March 1997, . 3097 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 3098 DOI 10.17487/RFC3688, January 2004, . 3101 [RFC5246] Dierks, T. and E. Rescorla, "The Transport Layer Security 3102 (TLS) Protocol Version 1.2", RFC 5246, 3103 DOI 10.17487/RFC5246, August 2008, . 3106 [RFC5586] Bocci, M., Ed., Vigoureux, M., Ed., and S. Bryant, Ed., 3107 "MPLS Generic Associated Channel", RFC 5586, 3108 DOI 10.17487/RFC5586, June 2009, . 3111 [RFC5880] Katz, D. and D. Ward, "Bidirectional Forwarding Detection 3112 (BFD)", RFC 5880, DOI 10.17487/RFC5880, June 2010, 3113 . 3115 [RFC5881] Katz, D. and D. Ward, "Bidirectional Forwarding Detection 3116 (BFD) for IPv4 and IPv6 (Single Hop)", RFC 5881, 3117 DOI 10.17487/RFC5881, June 2010, . 3120 [RFC5882] Katz, D. and D. Ward, "Generic Application of 3121 Bidirectional Forwarding Detection (BFD)", RFC 5882, 3122 DOI 10.17487/RFC5882, June 2010, . 3125 [RFC5883] Katz, D. and D. Ward, "Bidirectional Forwarding Detection 3126 (BFD) for Multihop Paths", RFC 5883, DOI 10.17487/RFC5883, 3127 June 2010, . 3129 [RFC5884] Aggarwal, R., Kompella, K., Nadeau, T., and G. Swallow, 3130 "Bidirectional Forwarding Detection (BFD) for MPLS Label 3131 Switched Paths (LSPs)", RFC 5884, DOI 10.17487/RFC5884, 3132 June 2010, . 3134 [RFC5885] Nadeau, T., Ed. and C. Pignataro, Ed., "Bidirectional 3135 Forwarding Detection (BFD) for the Pseudowire Virtual 3136 Circuit Connectivity Verification (VCCV)", RFC 5885, 3137 DOI 10.17487/RFC5885, June 2010, . 3140 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 3141 and A. Bierman, Ed., "Network Configuration Protocol 3142 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 3143 . 3145 [RFC6242] Wasserman, M., "Using the NETCONF Protocol over Secure 3146 Shell (SSH)", RFC 6242, DOI 10.17487/RFC6242, June 2011, 3147 . 3149 [RFC6536] Bierman, A. and M. Bjorklund, "Network Configuration 3150 Protocol (NETCONF) Access Control Model", RFC 6536, 3151 DOI 10.17487/RFC6536, March 2012, . 3154 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 3155 RFC 6991, DOI 10.17487/RFC6991, July 2013, 3156 . 3158 [RFC7130] Bhatia, M., Ed., Chen, M., Ed., Boutros, S., Ed., 3159 Binderberger, M., Ed., and J. Haas, Ed., "Bidirectional 3160 Forwarding Detection (BFD) on Link Aggregation Group (LAG) 3161 Interfaces", RFC 7130, DOI 10.17487/RFC7130, February 3162 2014, . 3164 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 3165 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 3166 . 3168 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 3169 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 3170 May 2017, . 3172 [RFC8177] Lindem, A., Ed., Qu, Y., Yeung, D., Chen, I., and J. 3173 Zhang, "YANG Data Model for Key Chains", RFC 8177, 3174 DOI 10.17487/RFC8177, June 2017, . 3177 [RFC8343] Bjorklund, M., "A YANG Data Model for Interface 3178 Management", RFC 8343, DOI 10.17487/RFC8343, March 2018, 3179 . 3181 [RFC8349] Lhotka, L., Lindem, A., and Y. Qu, "A YANG Data Model for 3182 Routing Management (NMDA Version)", RFC 8349, 3183 DOI 10.17487/RFC8349, March 2018, . 3186 7.2. Informative References 3188 [I-D.ietf-lime-yang-connectionless-oam] 3189 Kumar, D., Wang, Z., Wu, Q., Rahman, R., and S. Raghavan, 3190 "Generic YANG Data Model for the Management of Operations, 3191 Administration, and Maintenance (OAM) Protocols that use 3192 Connectionless Communications", draft-ietf-lime-yang- 3193 connectionless-oam-18 (work in progress), November 2017. 3195 [I-D.ietf-netmod-revised-datastores] 3196 Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 3197 and R. Wilton, "Network Management Datastore 3198 Architecture", draft-ietf-netmod-revised-datastores-10 3199 (work in progress), January 2018. 3201 [I-D.ietf-rtgwg-lne-model] 3202 Berger, L., Hopps, C., Lindem, A., Bogdanovic, D., and X. 3203 Liu, "YANG Model for Logical Network Elements", draft- 3204 ietf-rtgwg-lne-model-09 (work in progress), March 2018. 3206 [I-D.ietf-rtgwg-ni-model] 3207 Berger, L., Hopps, C., Lindem, A., Bogdanovic, D., and X. 3208 Liu, "YANG Model for Network Instances", draft-ietf-rtgwg- 3209 ni-model-11 (work in progress), March 2018. 3211 Appendix A. Echo function configuration example 3213 As mentioned in Section 2.1.2, the mechanism to start and stop the 3214 echo function, as defined in [RFC5880] and [RFC5881], is 3215 implementation specific. In this section we provide an example of 3216 how the echo function can be implemented via configuration. 3218 module: example-bfd-echo 3219 augment /rt:routing/rt:control-plane-protocols 3220 /rt:control-plane-protocol/bfd:bfd 3221 /bfd-ip-sh:ip-sh/bfd-ip-sh:sessions: 3222 +--rw echo {bfd-types:echo-mode}? 3223 +--rw desired-min-echo-tx-interval? uint32 3224 +--rw required-min-echo-rx-interval? uint32 3226 A.1. Example YANG module for BFD echo function configuration 3228 module example-bfd-echo { 3229 namespace "tag:example.com,2018:example-bfd-echo"; 3231 prefix "example-bfd-echo"; 3233 import ietf-bfd-types { 3234 prefix "bfd-types"; 3235 } 3237 import ietf-bfd { 3238 prefix "bfd"; 3239 } 3241 import ietf-bfd-ip-sh { 3242 prefix "bfd-ip-sh"; 3243 } 3245 import ietf-routing { 3246 prefix "rt"; 3247 } 3249 organization "IETF BFD Working Group"; 3251 contact 3252 "WG Web: 3253 WG List: 3255 Editors: Reshad Rahman (rrahman@cisco.com), 3256 Lianshu Zheng (vero.zheng@huawei.com), 3257 Mahesh Jethanandani (mjethanandani@gmail.com)"; 3259 description 3260 "This module contains an example YANG augmentation for configuration 3261 of BFD echo function. 3263 Copyright (c) 2018 IETF Trust and the persons 3264 identified as authors of the code. All rights reserved. 3266 Redistribution and use in source and binary forms, with or 3267 without modification, is permitted pursuant to, and subject 3268 to the license terms contained in, the Simplified BSD License 3269 set forth in Section 4.c of the IETF Trust's Legal Provisions 3270 Relating to IETF Documents 3271 (http://trustee.ietf.org/license-info). 3273 This version of this YANG module is part of RFC XXXX; see 3274 the RFC itself for full legal notices."; 3276 revision 2018-03-20 { 3277 description "Initial revision."; 3278 reference 3279 "RFC XXXX: A YANG data model example augmentation for BFD echo 3280 function"; 3281 } 3283 // RFC Ed.: replace XXXX with actual RFC number and remove this 3284 // note 3286 /* 3287 * Groupings 3288 */ 3289 grouping echo-cfg-parms { 3290 description "BFD grouping for echo config parameters"; 3291 leaf desired-min-echo-tx-interval { 3292 type uint32; 3293 units microseconds; 3294 default 0; 3295 description 3296 "This is the minimum interval that the local system would like 3297 to use when transmitting BFD echo packets. If 0, the echo 3298 function as defined in BFD [RFC5880] is disabled."; 3299 } 3301 leaf required-min-echo-rx-interval { 3302 type uint32; 3303 units microseconds; 3304 default 0; 3305 description 3306 "This is the Required Min Echo RX Interval as defined in BFD 3308 [RFC5880]."; 3309 } 3310 } 3312 augment "/rt:routing/rt:control-plane-protocols/" 3313 + "rt:control-plane-protocol/bfd:bfd/bfd-ip-sh:ip-sh/" 3314 + "bfd-ip-sh:sessions" { 3315 description "Augmentation for BFD echo function."; 3317 container echo { 3318 if-feature bfd-types:echo-mode; 3320 description "BFD echo function container"; 3322 uses echo-cfg-parms; 3323 } 3324 } 3325 } 3327 Appendix B. Change log 3329 RFC Editor: Remove this section upon publication as an RFC. 3331 B.1. Changes between versions -11 and -12 3333 o Addressed comments from YANG Doctor review of rev11. 3335 B.2. Changes between versions -10 and -11 3337 o Added 2 examples. 3339 o Added a container around some lists. 3341 o Fixed some indentation nits. 3343 B.3. Changes between versions -09 and -10 3345 o Addressed comments from YANG Doctor review. 3347 o Addressed comments from WGLC. 3349 B.4. Changes between versions -08 and -09 3351 o Mostly cosmetic changes to abide by draft-ietf-netmod-rfc6087bis. 3353 o Specified yang-version 1.1. 3355 o Added data model examples. 3357 o Some minor changes. 3359 B.5. Changes between versions -07 and -08 3361 o Timer intervals in client-cfg-parms are not mandatory anymore. 3363 o Added list of interfaces under "ip-sh" node for authentication 3364 parameters. 3366 o Renamed replay-protection to meticulous. 3368 B.6. Changes between versions -06 and -07 3370 o New ietf-bfd-types module. 3372 o Grouping for BFD clients to have BFD multiplier and interval 3373 values. 3375 o Change in ietf-bfd-mpls-te since MPLS-TE model changed. 3377 o Removed bfd- prefix from many names. 3379 B.7. Changes between versions -05 and -06 3381 o Adhere to NMDA-guidelines. 3383 o Echo function config moved to appendix as example. 3385 o Added IANA YANG modules. 3387 o Addressed various comments. 3389 B.8. Changes between versions -04 and -05 3391 o "bfd" node in augment of control-plane-protocol. 3393 o Removed augment of network-instance. Replaced by schema-mount. 3395 o Added information on interaction with other YANG modules. 3397 B.9. Changes between versions -03 and -04 3399 o Updated author information. 3401 o Fixed YANG compile error in ietf-bfd-lag.yang which was due to 3402 incorrect when statement. 3404 B.10. Changes between versions -02 and -03 3406 o Fixed YANG compilation warning due to incorrect revision date in 3407 ietf-bfd-ip-sh module. 3409 B.11. Changes between versions -01 and -02 3411 o Replace routing-instance with network-instance from YANG Network 3412 Instances [I-D.ietf-rtgwg-ni-model] 3414 B.12. Changes between versions -00 and -01 3416 o Remove BFD configuration parameters from BFD clients, all BFD 3417 configuration parameters in BFD 3419 o YANG module split in multiple YANG modules (one per type of 3420 forwarding path) 3422 o For BFD over MPLS-TE we augment MPLS-TE model 3424 o For BFD authentication we now use YANG Data Model for Key Chains 3425 [RFC8177] 3427 Authors' Addresses 3429 Reshad Rahman (editor) 3430 Cisco Systems 3431 Canada 3433 Email: rrahman@cisco.com 3435 Lianshu Zheng (editor) 3436 Huawei Technologies 3437 China 3439 Email: vero.zheng@huawei.com 3441 Mahesh Jethanandani (editor) 3443 Email: mjethanandani@gmail.com 3445 Santosh Pallagatti 3446 India 3448 Email: santosh.pallagatti@gmail.com 3449 Greg Mirsky 3450 ZTE Corporation 3452 Email: gregimirsky@gmail.com