idnits 2.17.1 draft-ietf-bfd-yang-09.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** There is 1 instance of too long lines in the document, the longest one being 1 character in excess of 72. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year == Line 2925 has weird spacing: '...terface if:...' == The document doesn't use any RFC 2119 keywords, yet seems to have RFC 2119 boilerplate text. -- The document date (January 22, 2018) is 2285 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) == Missing Reference: 'RFC6241' is mentioned on line 2573, but not defined == Missing Reference: 'RFC6242' is mentioned on line 2575, but not defined == Missing Reference: 'RFC6536' is mentioned on line 2576, but not defined ** Obsolete undefined reference: RFC 6536 (Obsoleted by RFC 8341) == Unused Reference: 'RFC6991' is defined on line 2717, but no explicit reference was found in the text ** Obsolete normative reference: RFC 7223 (Obsoleted by RFC 8343) ** Obsolete normative reference: RFC 7277 (Obsoleted by RFC 8344) ** Obsolete normative reference: RFC 8022 (Obsoleted by RFC 8349) == Outdated reference: A later version (-17) exists of draft-ietf-mpls-base-yang-05 == Outdated reference: A later version (-12) exists of draft-ietf-netmod-schema-mount-08 == Outdated reference: A later version (-10) exists of draft-ietf-rtgwg-lne-model-05 == Outdated reference: A later version (-12) exists of draft-ietf-rtgwg-ni-model-05 == Outdated reference: A later version (-36) exists of draft-ietf-teas-yang-te-10 Summary: 5 errors (**), 0 flaws (~~), 12 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: July 26, 2018 Huawei Technologies 6 M. Jethanandani, Ed. 8 S. Pallagatti 10 G. Mirsky 11 ZTE Corporation 12 January 22, 2018 14 YANG Data Model for Bidirectional Forwarding Detection (BFD) 15 draft-ietf-bfd-yang-09.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 Requirements Language 24 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 25 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 26 document are to be interpreted as described in RFC 2119 [RFC2119]. 28 Status of This Memo 30 This Internet-Draft is submitted in full conformance with the 31 provisions of BCP 78 and BCP 79. 33 Internet-Drafts are working documents of the Internet Engineering 34 Task Force (IETF). Note that other groups may also distribute 35 working documents as Internet-Drafts. The list of current Internet- 36 Drafts is at http://datatracker.ietf.org/drafts/current/. 38 Internet-Drafts are draft documents valid for a maximum of six months 39 and may be updated, replaced, or obsoleted by other documents at any 40 time. It is inappropriate to use Internet-Drafts as reference 41 material or to cite them other than as "work in progress." 43 This Internet-Draft will expire on July 26, 2018. 45 Copyright Notice 47 Copyright (c) 2018 IETF Trust and the persons identified as the 48 document authors. All rights reserved. 50 This document is subject to BCP 78 and the IETF Trust's Legal 51 Provisions Relating to IETF Documents 52 (http://trustee.ietf.org/license-info) in effect on the date of 53 publication of this document. Please review these documents 54 carefully, as they describe your rights and restrictions with respect 55 to this document. Code Components extracted from this document must 56 include Simplified BSD License text as described in Section 4.e of 57 the Trust Legal Provisions and are provided without warranty as 58 described in the Simplified BSD License. 60 Table of Contents 62 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 63 2. Design of the Data Model . . . . . . . . . . . . . . . . . . 4 64 2.1. Design of Configuration Model . . . . . . . . . . . . . . 5 65 2.1.1. Common BFD configuration parameters . . . . . . . . . 5 66 2.1.2. Single-hop IP . . . . . . . . . . . . . . . . . . . . 6 67 2.1.3. Multihop IP . . . . . . . . . . . . . . . . . . . . . 7 68 2.1.4. MPLS Traffic Engineering Tunnels . . . . . . . . . . 7 69 2.1.5. MPLS Label Switched Paths . . . . . . . . . . . . . . 8 70 2.1.6. Link Aggregation Groups . . . . . . . . . . . . . . . 8 71 2.2. Design of Operational Model . . . . . . . . . . . . . . . 8 72 2.3. Notifications . . . . . . . . . . . . . . . . . . . . . . 9 73 2.4. RPC Operations . . . . . . . . . . . . . . . . . . . . . 9 74 2.5. BFD top level hierarchy . . . . . . . . . . . . . . . . . 9 75 2.6. BFD IP single-hop hierarchy . . . . . . . . . . . . . . . 10 76 2.7. BFD IP multihop hierarchy . . . . . . . . . . . . . . . . 12 77 2.8. BFD over LAG hierarchy . . . . . . . . . . . . . . . . . 13 78 2.9. BFD over MPLS LSPs hierarchy . . . . . . . . . . . . . . 16 79 2.10. BFD over MPLS-TE hierarchy . . . . . . . . . . . . . . . 18 80 2.11. Interaction with other YANG modules . . . . . . . . . . . 20 81 2.11.1. Module ietf-interfaces . . . . . . . . . . . . . . . 20 82 2.11.2. Module ietf-ip . . . . . . . . . . . . . . . . . . . 20 83 2.11.3. Module ietf-mpls . . . . . . . . . . . . . . . . . . 21 84 2.11.4. Module ietf-te . . . . . . . . . . . . . . . . . . . 21 85 2.12. IANA BFD YANG Module . . . . . . . . . . . . . . . . . . 21 86 2.13. BFD types YANG Module . . . . . . . . . . . . . . . . . . 24 87 2.14. BFD top-level YANG Module . . . . . . . . . . . . . . . . 36 88 2.15. BFD IP single-hop YANG Module . . . . . . . . . . . . . . 37 89 2.16. BFD IP multihop YANG Module . . . . . . . . . . . . . . . 40 90 2.17. BFD over LAG YANG Module . . . . . . . . . . . . . . . . 43 91 2.18. BFD over MPLS YANG Module . . . . . . . . . . . . . . . . 47 92 2.19. BFD over MPLS-TE YANG Module . . . . . . . . . . . . . . 51 94 3. Data Model examples . . . . . . . . . . . . . . . . . . . . . 53 95 3.1. IP single-hop . . . . . . . . . . . . . . . . . . . . . . 53 96 3.2. IP multihop . . . . . . . . . . . . . . . . . . . . . . . 54 97 4. Security Considerations . . . . . . . . . . . . . . . . . . . 55 98 5. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 55 99 5.1. IANA-Maintained iana-bfd-types module . . . . . . . . . . 56 100 6. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 57 101 7. References . . . . . . . . . . . . . . . . . . . . . . . . . 57 102 7.1. Normative References . . . . . . . . . . . . . . . . . . 57 103 7.2. Informative References . . . . . . . . . . . . . . . . . 58 104 Appendix A. Echo function configuration example . . . . . . . . 59 105 A.1. Example YANG module for BFD echo function . . . . . . . . 60 106 Appendix B. BFD client configuration example . . . . . . . . . . 62 107 B.1. Example YANG module for BFD client . . . . . . . . . . . 62 108 Appendix C. Change log . . . . . . . . . . . . . . . . . . . . . 64 109 C.1. Changes between versions -08 and -09 . . . . . . . . . . 64 110 C.2. Changes between versions -07 and -08 . . . . . . . . . . 65 111 C.3. Changes between versions -06 and -07 . . . . . . . . . . 65 112 C.4. Changes between versions -05 and -06 . . . . . . . . . . 65 113 C.5. Changes between versions -04 and -05 . . . . . . . . . . 65 114 C.6. Changes between versions -03 and -04 . . . . . . . . . . 65 115 C.7. Changes between versions -02 and -03 . . . . . . . . . . 66 116 C.8. Changes between versions -01 and -02 . . . . . . . . . . 66 117 C.9. Changes between versions -00 and -01 . . . . . . . . . . 66 118 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 66 120 1. Introduction 122 This document defines a YANG data model that can be used to configure 123 and manage Bidirectional Forwarding Detection (BFD) [RFC5880]. BFD 124 is a network protocol which is used for liveness detection of 125 arbitrary paths between systems. Some examples of different types of 126 paths over which we have BFD: 128 1) Two systems directly connected via IP. This is known as BFD over 129 single-hop IP, a.k.a. BFD for IPv4 and IPv6 [RFC5881] 131 2) Two systems connected via multiple hops as described in BFD for 132 Multiple Hops. [RFC5883] 134 3) Two systems connected via MPLS Label Switched Paths (LSPs) as 135 described in BFD for MPLS LSP [RFC5884] 137 4) Two systems connected via a Link Aggregation Group (LAG) interface 138 as described in BFD on LAG Interfaces [RFC7130] 139 5) Two systems connected via pseudowires (PWs), this is known as 140 Virtual Circuit Connectivity Verification (VCCV) as described in BFD 141 for PW VCCV [RFC5885]. This is not addressed in this document. 143 BFD typically does not operate on its own. Various control 144 protocols, also known as BFD clients, use the services provided by 145 BFD for their own operation as described in Generic Application of 146 BFD [RFC5882]. The obvious candidates which use BFD are those which 147 do not have "hellos" to detect failures, e.g. static routes, and 148 routing protocols whose "hellos" do not support sub-second failure 149 detection, e.g. OSPF and IS-IS. 151 2. Design of the Data Model 153 Since BFD is used for liveliness detection of various forwarding 154 paths, there is no uniform key to identify a BFD session. So the BFD 155 data model is split in multiple YANG modules where each module 156 corresponds to one type of forwarding path. For example, BFD for IP 157 single-hop is in one YANG module and BFD for MPLS-TE is in another 158 YANG module. The main difference between these modules is how a BFD 159 session is uniquely identified, i.e the key for the list containing 160 the BFD sessions for that forwarding path. To avoid duplication of 161 BFD definitions, we have common types and groupings which are used by 162 all the modules. 164 A new control-plane protocol "bfdv1" is defined and a "bfd" container 165 is created under control-plane-protocol as specified in A YANG Data 166 Model for Routing Management [RFC8022]. This new "bfd" node is 167 augmented by all the YANG modules for their respective specific 168 information. 170 BFD can operate in the following contexts: 172 1. Network devices as described in Network Device YANG 173 Organizational Models [I-D.ietf-rtgwg-device-model] 175 2. Logical Network Elements as described in YANG Logical Network 176 Element [I-D.ietf-rtgwg-lne-model] 178 3. Network instances as described in YANG Logical Network Element 179 [I-D.ietf-rtgwg-ni-model] 181 The approach taken is to do a schema-mount (see Schema Mount 182 [I-D.ietf-netmod-schema-mount]) of the BFD model in the appropriate 183 locations. For example, if an implementation supports BFD IP 184 multihop in network instances, the implementation would do schema- 185 mount of the BFD IP multihop model in a mount-point which resides in 186 a network instance. 188 The data models in this document strive to follow the "Network 189 Management Datastore Architecture" (NMDA) guidelines described in 190 [I-D.dsdt-nmda-guidelines]. This means that the data models do NOT 191 have separate top-level or sibling containers for configuration and 192 operational data. 194 2.1. Design of Configuration Model 196 The configuration model consists mainly of the parameters specified 197 in BFD [RFC5880]. Some examples are desired minimum transmit 198 interval, required minimum receive interval, detection multiplier, 199 etc 201 BFD clients are applications that use BFD for fast detection of 202 failures. Some implementations have BFD session configuration under 203 the BFD clients. For example, BFD session configuration under 204 routing applications such as OSPF, IS-IS, BGP etc. Other 205 implementations have BFD session configuration centralized under BFD, 206 i.e. outside the multiple BFD clients. 208 The BFD parameters of interest to a BFD client are mainly the 209 multiplier and interval(s) since those parameters impact the 210 convergence time of the BFD clients when a failure occurs. Other 211 parameters such as BFD authentication are not specific to the 212 requirements of the BFD client. Ideally all configuration should be 213 centralized under BFD. However, this is a problem for clients of BFD 214 which auto-discover their peers. For example, IGPs do not have the 215 peer address configured, instead the IGP is enabled on an interface 216 and the IGP peers are auto-discovered. So for an operator to 217 configure BFD to an IGP peer, the operator would first have to 218 determine the peer addresses. And when a new peer is discovered, BFD 219 configuration would need to be added. To avoid this issue, we define 220 grouping client-cfg-parms in Section 2.13 for BFD clients to 221 configure BFD: this allows BFD clients such as the IGPs to have 222 configuration (multiplier and intervals) for the BFD sessions they 223 need. The mechanism how the BFD sessions are created by the BFD 224 clients is outside the scope of this document. For BFD clients which 225 create BFD sessions via their own configuration, authentication 226 parameters (if required) are still specified in BFD. 228 2.1.1. Common BFD configuration parameters 230 The basic BFD configuration parameters are: 232 local-multiplier 233 This is the detection time multiplier as defined in BFD 234 [RFC5880]. 236 desired-min-tx-interval 237 This is the Desired Min TX Interval as defined in BFD 238 [RFC5880]. 240 required-min-rx-interval 241 This is the Required Min RX Interval as defined in BFD 242 [RFC5880]. 244 Although BFD [RFC5880] allows for different values for transmit and 245 receive intervals, some implementations allow users to specify just 246 one interval which is used for both transmit and receive intervals or 247 separate values for transmit and receive intervals. The BFD YANG 248 model supports this: there is a choice between "min-interval", used 249 for both transmit and receive intervals, and "desired-min-tx- 250 interval" and "required-min-rx-interval". This is supported via a 251 grouping which is used by the YANG modules for the various forwarding 252 paths. 254 For BFD authentication we have: 256 key-chain 257 This is a reference to key-chain defined in YANG Data Model 258 for Key Chains [RFC8177]. The keys, cryptographic 259 algorithms, key lifetime etc are all defined in the key-chain 260 model. 262 meticulous 263 This enables meticulous mode as per BFD [RFC5880]. 265 2.1.2. Single-hop IP 267 For single-hop IP, there is an augment of the "bfd" data node in 268 Section 2. The "ip-sh" node contains a list of IP single-hop 269 sessions where each session is uniquely identified by the interface 270 and destination address pair. For the configuration parameters we 271 use what is defined in Section 2.1.1. The "ip-sh" node also contains 272 a list of interfaces, this is used to specify authentication 273 parameters for BFD sessions which are created by BFD clients, see 274 Section 2.1. 276 [RFC5880] and [RFC5881] do not specify whether echo function is 277 continuous or on demand. Therefore the mechanism used to start and 278 stop echo function is implementation specific and should be done by 279 augmentation: 281 1) Configuration. This is suitable for continuous echo function. 282 An example is provided in Appendix A. 284 2) RPC. This is suitable for on-demand echo function. 286 2.1.3. Multihop IP 288 For multihop IP, there is an augment of the "bfd" data node in 289 Section 2. 291 Because of multiple paths, there could be multiple multihop IP 292 sessions between a source and a destination address. We identify 293 this as a "session-group". The key for each "session-group" consists 294 of: 296 source address 297 Address belonging to the local system as per BFD for Multiple 298 Hops [RFC5883] 300 destination address 301 Address belonging to the remote system as per BFD for 302 Multiple Hops [RFC5883] 304 For the configuration parameters we use what is defined in 305 Section 2.1.1 307 Here are some extra parameters: 309 tx-ttl 310 TTL of outgoing BFD control packets. 312 rx-ttl 313 Minimum TTL of incoming BFD control packets. 315 2.1.4. MPLS Traffic Engineering Tunnels 317 For MPLS-TE tunnels, BFD is configured under the MPLS-TE tunnel since 318 the desired failure detection parameters is a property of the MPLS-TE 319 tunnel. This is achieved by augmenting the MPLS-TE data model in 320 YANG Data Model for TE Topologies [I-D.ietf-teas-yang-te]. For BFD 321 parameters which are specific to the TE application, e.g. whether to 322 tear down the tunnel in the event of a BFD session failure, these 323 parameters will be defined in the YANG model of the MPLS-TE 324 application. 326 On top of the usual BFD parameters, we have the following per MPLS-TE 327 tunnel: 329 encap 330 Encapsulation for the BFD packets: choice between IP, G-ACh 331 and IP with G-ACh as per MPLS Generic Associated Channel 332 [RFC5586] 334 For general MPLS-TE data, "mpls-te" data node is added under the 335 "bfd" node in Section 2. Since some MPLS-TE tunnels are uni- 336 directional there is no MPLS-TE configuration for these tunnels on 337 the egress node (note that this does not apply to bi-directional 338 MPLS-TP tunnels). The BFD parameters for the egress node are added 339 under "mpls-te". 341 2.1.5. MPLS Label Switched Paths 343 Here we address MPLS LSPs whose FEC is an IP address. The "bfd" node 344 in Section 2 is augmented with "mpls" which contains a list of 345 sessions uniquely identified by an IP prefix. Because of multiple 346 paths, there could be multiple MPLS sessions to an MPLS FEC. We 347 identify this as a "session-group". 349 Since these LSPs are uni-directional there is no LSP configuration on 350 the egress node. 352 The BFD parameters for the egress node are added under "mpls". 354 2.1.6. Link Aggregation Groups 356 Per BFD on LAG Interfaces [RFC7130], configuring BFD on LAG consists 357 of having micro-BFD sessions on each LAG member link. Since the BFD 358 parameters are an attribute of the LAG, they should be under the LAG. 359 However there is no LAG YANG model which we can augment. So a "lag" 360 data node is added to the "bfd" node in Section 2, the configuration 361 is per-LAG: we have a list of LAGs. The destination IP address of 362 the micro-BFD sessions is configured per-LAG and per address-family 363 (IPv4 and IPv6) 365 2.2. Design of Operational Model 367 The operational model contains both the overall statistics of BFD 368 sessions running on the device and the per session operational 369 information. 371 The overall statistics of BFD sessions consist of number of BFD 372 sessions, number of BFD sessions up etc. This information is 373 available globally (i.e. for all BFD sessions) under the "bfd" node 374 in Section 2 and also per type of forwarding path. 376 For each BFD session, mainly three categories of operational items 377 are shown. The fundamental information of a BFD session such as the 378 local discriminator, remote discriminator and the capability of 379 supporting demand detect mode are shown in the first category. The 380 second category includes a BFD session running information, e.g. the 381 remote BFD state and the diagnostic code received. Another example 382 is the actual transmit interval between the control packets, which 383 may be different from the desired minimum transmit interval 384 configured, is shown in this category. Similar examples are actual 385 received interval between the control packets and the actual transmit 386 interval between the echo packets. The third category contains the 387 detailed statistics of the session, e.g. when the session 388 transitioned up/down and how long it has been in that state. 390 For some path types, there may be more than 1 session on the virtual 391 path to the destination. For example, with IP multihop and MPLS 392 LSPs, there could be multiple BFD sessions from the source to the 393 same destination to test the various paths (ECMP) to the destination. 394 This is represented by having multiple "sessions" under each 395 "session-group". 397 2.3. Notifications 399 This YANG model defines notifications to inform clients of BFD of 400 important events detected during the protocol operation. Pair of 401 local and remote discriminator identifies a BFD session on local 402 system. Notifications also give more important details about BFD 403 sessions; e.g. new state, time in previous state, network-instance 404 and the reason that the BFD session state changed. The notifications 405 are defined for each type of forwarding path but use groupings for 406 common information. 408 2.4. RPC Operations 410 None. 412 2.5. BFD top level hierarchy 414 At the "bfd" node under control-plane-protocol, there is no 415 configuration data, only operational data. The operational data 416 consist of overall BFD session statistics, i.e. for BFD on all types 417 of forwarding paths. The "bfd" node under control-plane-protocol can 418 be used in a network device (top-level), or mounted in an LNE or in a 419 network instance. 421 module: ietf-bfd 422 augment /rt:routing/rt:control-plane-protocols 423 /rt:control-plane-protocol: 424 +--rw bfd 425 +--ro session-statistics 426 +--ro session-count? uint32 427 +--ro session-up-count? uint32 428 +--ro session-down-count? uint32 429 +--ro session-admin-down-count? uint32 431 2.6. BFD IP single-hop hierarchy 433 An "ip-sh" node is added under "bfd" node in control-plane-protocol. 434 The configuration and operational data for each BFD IP single-hop 435 session is under this "ip-sh" node. The "ip-sh" node can be used in 436 a network device (top-level), or mounted in an LNE or in a network 437 instance. 439 module: ietf-bfd-ip-sh 440 augment /rt:routing/rt:control-plane-protocols 441 /rt:control-plane-protocol/bfd:bfd: 442 +--rw ip-sh 443 +--ro session-statistics 444 | +--ro session-count? uint32 445 | +--ro session-up-count? uint32 446 | +--ro session-down-count? uint32 447 | +--ro session-admin-down-count? uint32 448 +--rw sessions* [interface dest-addr] 449 | +--rw interface if:interface-ref 450 | +--rw dest-addr inet:ip-address 451 | +--rw source-addr? inet:ip-address 452 | +--rw local-multiplier? multiplier 453 | +--rw (interval-config-type)? 454 | | +--:(tx-rx-intervals) 455 | | | +--rw desired-min-tx-interval? uint32 456 | | | +--rw required-min-rx-interval? uint32 457 | | +--:(single-interval) 458 | | +--rw min-interval? uint32 459 | +--rw demand-enabled? boolean {demand-mode}? 460 | +--rw admin-down? boolean 461 | +--rw authentication! {authentication}? 462 | | +--rw key-chain? kc:key-chain-ref 463 | | +--rw meticulous? boolean 464 | +--ro path-type? identityref 465 | +--ro ip-encapsulation? boolean 466 | +--ro local-discriminator? discriminator 467 | +--ro remote-discriminator? discriminator 468 | +--ro remote-multiplier? multiplier 469 | +--ro demand-capability? boolean {demand-mode}? 470 | +--ro source-port? inet:port-number 471 | +--ro dest-port? inet:port-number 472 | +--ro session-running 473 | | +--ro session-index? uint32 474 | | +--ro local-state? state 475 | | +--ro remote-state? state 476 | | +--ro local-diagnostic? 477 | | | iana-bfd-types:diagnostic 478 | | +--ro remote-diagnostic? 479 | | | iana-bfd-types:diagnostic 480 | | +--ro remote-authenticated? boolean 481 | | +--ro remote-authentication-type? iana-bfd-types: 482 auth-type 483 | | | {authentication}? 484 | | +--ro detection-mode? enumeration 485 | | +--ro negotiated-tx-interval? uint32 486 | | +--ro negotiated-rx-interval? uint32 487 | | +--ro detection-time? uint32 488 | | +--ro echo-tx-interval-in-use? uint32 {echo-mode}? 489 | +--ro sesssion-statistics 490 | +--ro create-time? yang:date-and-time 491 | +--ro last-down-time? yang:date-and-time 492 | +--ro last-up-time? yang:date-and-time 493 | +--ro down-count? uint32 494 | +--ro admin-down-count? uint32 495 | +--ro receive-packet-count? uint64 496 | +--ro send-packet-count? uint64 497 | +--ro receive-bad-packet? uint64 498 | +--ro send-failed-packet? uint64 499 +--rw interfaces* [interface] 500 +--rw interface if:interface-ref 501 +--rw authentication! {authentication}? 502 +--rw key-chain? kc:key-chain-ref 503 +--rw meticulous? boolean 505 notifications: 506 +---n singlehop-notification 507 +--ro local-discr? discriminator 508 +--ro remote-discr? discriminator 509 +--ro new-state? state 510 +--ro state-change-reason? iana-bfd-types:diagnostic 511 +--ro time-of-last-state-change? yang:date-and-time 512 +--ro dest-addr? inet:ip-address 513 +--ro source-addr? inet:ip-address 514 +--ro session-index? uint32 515 +--ro path-type? identityref 516 +--ro interface? if:interface-ref 517 +--ro echo-enabled? boolean 519 2.7. BFD IP multihop hierarchy 521 An "ip-mh" node is added under the "bfd" node in cntrol-plane- 522 protocol. The configuration and operational data for each BFD IP 523 multihop session is under this "ip-mh" node. In the operational 524 model we support multiple BFD multihop sessions per remote address 525 (ECMP), the local discriminator is used as key. The "ip-mh" node can 526 be used in a network device (top-level), or mounted in an LNE or in a 527 network instance. 529 module: ietf-bfd-ip-mh 530 augment /rt:routing/rt:control-plane-protocols 531 /rt:control-plane-protocol/bfd:bfd: 532 +--rw ip-mh 533 +--ro session-statistics 534 | +--ro session-count? uint32 535 | +--ro session-up-count? uint32 536 | +--ro session-down-count? uint32 537 | +--ro session-admin-down-count? uint32 538 +--rw session-group* [source-addr dest-addr] 539 +--rw source-addr inet:ip-address 540 +--rw dest-addr inet:ip-address 541 +--rw local-multiplier? multiplier 542 +--rw (interval-config-type)? 543 | +--:(tx-rx-intervals) 544 | | +--rw desired-min-tx-interval? uint32 545 | | +--rw required-min-rx-interval? uint32 546 | +--:(single-interval) 547 | +--rw min-interval? uint32 548 +--rw demand-enabled? boolean {demand-mode}? 549 +--rw admin-down? boolean 550 +--rw authentication! {authentication}? 551 | +--rw key-chain? kc:key-chain-ref 552 | +--rw meticulous? boolean 553 +--rw tx-ttl? bfd-types:hops 554 +--rw rx-ttl bfd-types:hops 555 +--ro sessions* 556 +--ro path-type? identityref 557 +--ro ip-encapsulation? boolean 558 +--ro local-discriminator? discriminator 559 +--ro remote-discriminator? discriminator 560 +--ro remote-multiplier? multiplier 561 +--ro demand-capability? boolean {demand-mode}? 562 +--ro source-port? inet:port-number 563 +--ro dest-port? inet:port-number 564 +--ro session-running 565 | +--ro session-index? uint32 566 | +--ro local-state? state 567 | +--ro remote-state? state 568 | +--ro local-diagnostic? 569 | | iana-bfd-types:diagnostic 570 | +--ro remote-diagnostic? 571 | | iana-bfd-types:diagnostic 572 | +--ro remote-authenticated? boolean 573 | +--ro remote-authentication-type? 574 | | iana-bfd-types:auth-type {authentication}? 575 | +--ro detection-mode? enumeration 576 | +--ro negotiated-tx-interval? uint32 577 | +--ro negotiated-rx-interval? uint32 578 | +--ro detection-time? uint32 579 | +--ro echo-tx-interval-in-use? uint32 580 | {echo-mode}? 581 +--ro sesssion-statistics 582 +--ro create-time? yang:date-and-time 583 +--ro last-down-time? yang:date-and-time 584 +--ro last-up-time? yang:date-and-time 585 +--ro down-count? uint32 586 +--ro admin-down-count? uint32 587 +--ro receive-packet-count? uint64 588 +--ro send-packet-count? uint64 589 +--ro receive-bad-packet? uint64 590 +--ro send-failed-packet? uint64 592 notifications: 593 +---n multihop-notification 594 +--ro local-discr? discriminator 595 +--ro remote-discr? discriminator 596 +--ro new-state? state 597 +--ro state-change-reason? iana-bfd-types:diagnostic 598 +--ro time-of-last-state-change? yang:date-and-time 599 +--ro dest-addr? inet:ip-address 600 +--ro source-addr? inet:ip-address 601 +--ro session-index? uint32 602 +--ro path-type? identityref 604 2.8. BFD over LAG hierarchy 606 A "lag" node is added under the "bfd" node in control-plane-protocol. 607 The configuration and operational data for each BFD LAG session is 608 under this "lag" node. The "lag" node can be used in a network 609 device (top-level), or mounted in an LNE or in a network instance. 611 module: ietf-bfd-lag 612 augment /rt:routing/rt:control-plane-protocols 613 /rt:control-plane-protocol/bfd:bfd: 614 +--rw lag 615 +--rw micro-bfd-ipv4-session-statistics 616 | +--ro session-statistics 617 | +--ro session-count? uint32 618 | +--ro session-up-count? uint32 619 | +--ro session-down-count? uint32 620 | +--ro session-admin-down-count? uint32 621 +--rw micro-bfd-ipv6-session-statistics 622 | +--ro session-statistics 623 | +--ro session-count? uint32 624 | +--ro session-up-count? uint32 625 | +--ro session-down-count? uint32 626 | +--ro session-admin-down-count? uint32 627 +--rw sessions* [lag-name] 628 +--rw lag-name if:interface-ref 629 +--rw ipv4-dest-addr? inet:ipv4-address 630 +--rw ipv6-dest-addr? inet:ipv6-address 631 +--rw local-multiplier? multiplier 632 +--rw (interval-config-type)? 633 | +--:(tx-rx-intervals) 634 | | +--rw desired-min-tx-interval? uint32 635 | | +--rw required-min-rx-interval? uint32 636 | +--:(single-interval) 637 | +--rw min-interval? uint32 638 +--rw demand-enabled? boolean {demand-mode}? 639 +--rw admin-down? boolean 640 +--rw authentication! {authentication}? 641 | +--rw key-chain? kc:key-chain-ref 642 | +--rw meticulous? boolean 643 +--rw use-ipv4? boolean 644 +--rw use-ipv6? boolean 645 +--ro member-links* [member-link] 646 +--ro member-link if:interface-ref 647 +--ro micro-bfd-ipv4 648 | +--ro path-type? identityref 649 | +--ro ip-encapsulation? boolean 650 | +--ro local-discriminator? discriminator 651 | +--ro remote-discriminator? discriminator 652 | +--ro remote-multiplier? multiplier 653 | +--ro demand-capability? boolean {demand-mode}? 654 | +--ro source-port? inet:port-number 655 | +--ro dest-port? inet:port-number 656 | +--ro session-running 657 | | +--ro session-index? uint32 658 | | +--ro local-state? state 659 | | +--ro remote-state? state 660 | | +--ro local-diagnostic? 661 | | | iana-bfd-types:diagnostic 662 | | +--ro remote-diagnostic? 663 | | | iana-bfd-types:diagnostic 664 | | +--ro remote-authenticated? boolean 665 | | +--ro remote-authentication-type? 666 | | | iana-bfd-types:auth-type {authentication}? 667 | | +--ro detection-mode? enumeration 668 | | +--ro negotiated-tx-interval? uint32 669 | | +--ro negotiated-rx-interval? uint32 670 | | +--ro detection-time? uint32 671 | | +--ro echo-tx-interval-in-use? uint32 672 | | {echo-mode}? 673 | +--ro sesssion-statistics 674 | +--ro create-time? yang:date-and-time 675 | +--ro last-down-time? yang:date-and-time 676 | +--ro last-up-time? yang:date-and-time 677 | +--ro down-count? uint32 678 | +--ro admin-down-count? uint32 679 | +--ro receive-packet-count? uint64 680 | +--ro send-packet-count? uint64 681 | +--ro receive-bad-packet? uint64 682 | +--ro send-failed-packet? uint64 683 +--ro micro-bfd-ipv6 684 +--ro path-type? identityref 685 +--ro ip-encapsulation? boolean 686 +--ro local-discriminator? discriminator 687 +--ro remote-discriminator? discriminator 688 +--ro remote-multiplier? multiplier 689 +--ro demand-capability? boolean {demand-mode}? 690 +--ro source-port? inet:port-number 691 +--ro dest-port? inet:port-number 692 +--ro session-running 693 | +--ro session-index? uint32 694 | +--ro local-state? state 695 | +--ro remote-state? state 696 | +--ro local-diagnostic? 697 | | iana-bfd-types:diagnostic 698 | +--ro remote-diagnostic? 699 | | iana-bfd-types:diagnostic 700 | +--ro remote-authenticated? boolean 701 | +--ro remote-authentication-type? 702 | | iana-bfd-types:auth-type {authentication}? 703 | +--ro detection-mode? enumeration 704 | +--ro negotiated-tx-interval? uint32 705 | +--ro negotiated-rx-interval? uint32 706 | +--ro detection-time? uint32 707 | +--ro echo-tx-interval-in-use? uint32 708 | {echo-mode}? 709 +--ro sesssion-statistics 710 +--ro create-time? yang:date-and-time 711 +--ro last-down-time? yang:date-and-time 712 +--ro last-up-time? yang:date-and-time 713 +--ro down-count? uint32 714 +--ro admin-down-count? uint32 715 +--ro receive-packet-count? uint64 716 +--ro send-packet-count? uint64 717 +--ro receive-bad-packet? uint64 718 +--ro send-failed-packet? uint64 720 notifications: 721 +---n lag-notification 722 +--ro local-discr? discriminator 723 +--ro remote-discr? discriminator 724 +--ro new-state? state 725 +--ro state-change-reason? iana-bfd-types:diagnostic 726 +--ro time-of-last-state-change? yang:date-and-time 727 +--ro dest-addr? inet:ip-address 728 +--ro source-addr? inet:ip-address 729 +--ro session-index? uint32 730 +--ro path-type? identityref 731 +--ro lag-name? if:interface-ref 732 +--ro member-link? if:interface-ref 734 2.9. BFD over MPLS LSPs hierarchy 736 An "mpls" node is added under the "bfd" node in control-plane- 737 protocol. The configuration is per MPLS FEC under this "mpls" node. 738 In the operational model we support multiple BFD sessions per MPLS 739 FEC (ECMP), the local discriminator is used as key. The "mpls" node 740 can be used in a network device (top-level), or mounted in an LNE or 741 in a network instance. 743 module: ietf-bfd-mpls 744 augment /rt:routing/rt:control-plane-protocols 745 /rt:control-plane-protocol/bfd:bfd: 746 +--rw mpls 747 +--ro session-statistics 748 | +--ro session-count? uint32 749 | +--ro session-up-count? uint32 750 | +--ro session-down-count? uint32 751 | +--ro session-admin-down-count? uint32 752 +--rw egress 753 | +--rw enable? boolean 754 | +--rw local-multiplier? multiplier 755 | +--rw (interval-config-type)? 756 | | +--:(tx-rx-intervals) 757 | | | +--rw desired-min-tx-interval? uint32 758 | | | +--rw required-min-rx-interval? uint32 759 | | +--:(single-interval) 760 | | +--rw min-interval? uint32 761 | +--rw authentication! {authentication}? 762 | +--rw key-chain? kc:key-chain-ref 763 | +--rw meticulous? boolean 764 +--rw session-group* [mpls-fec] 765 +--rw mpls-fec inet:ip-prefix 766 +--rw local-multiplier? multiplier 767 +--rw (interval-config-type)? 768 | +--:(tx-rx-intervals) 769 | | +--rw desired-min-tx-interval? uint32 770 | | +--rw required-min-rx-interval? uint32 771 | +--:(single-interval) 772 | +--rw min-interval? uint32 773 +--rw demand-enabled? boolean {demand-mode}? 774 +--rw admin-down? boolean 775 +--rw authentication! {authentication}? 776 | +--rw key-chain? kc:key-chain-ref 777 | +--rw meticulous? boolean 778 +--ro sessions* 779 +--ro path-type? identityref 780 +--ro ip-encapsulation? boolean 781 +--ro local-discriminator? discriminator 782 +--ro remote-discriminator? discriminator 783 +--ro remote-multiplier? multiplier 784 +--ro demand-capability? boolean {demand-mode}? 785 +--ro source-port? inet:port-number 786 +--ro dest-port? inet:port-number 787 +--ro session-running 788 | +--ro session-index? uint32 789 | +--ro local-state? state 790 | +--ro remote-state? state 791 | +--ro local-diagnostic? 792 | | iana-bfd-types:diagnostic 793 | +--ro remote-diagnostic? 794 | | iana-bfd-types:diagnostic 795 | +--ro remote-authenticated? boolean 796 | +--ro remote-authentication-type? 797 | | iana-bfd-types:auth-type {authentication}? 798 | +--ro detection-mode? enumeration 799 | +--ro negotiated-tx-interval? uint32 800 | +--ro negotiated-rx-interval? uint32 801 | +--ro detection-time? uint32 802 | +--ro echo-tx-interval-in-use? uint32 803 | {echo-mode}? 804 +--ro sesssion-statistics 805 | +--ro create-time? yang:date-and-time 806 | +--ro last-down-time? yang:date-and-time 807 | +--ro last-up-time? yang:date-and-time 808 | +--ro down-count? uint32 809 | +--ro admin-down-count? uint32 810 | +--ro receive-packet-count? uint64 811 | +--ro send-packet-count? uint64 812 | +--ro receive-bad-packet? uint64 813 | +--ro send-failed-packet? uint64 814 +--ro mpls-dest-address? inet:ip-address 816 notifications: 817 +---n mpls-notification 818 +--ro local-discr? discriminator 819 +--ro remote-discr? discriminator 820 +--ro new-state? state 821 +--ro state-change-reason? iana-bfd-types:diagnostic 822 +--ro time-of-last-state-change? yang:date-and-time 823 +--ro dest-addr? inet:ip-address 824 +--ro source-addr? inet:ip-address 825 +--ro session-index? uint32 826 +--ro path-type? identityref 827 +--ro mpls-dest-address? inet:ip-address 829 2.10. BFD over MPLS-TE hierarchy 831 YANG Data Model for TE Topologies [I-D.ietf-teas-yang-te] is 832 augmented. BFD is configured per MPLS-TE tunnel, and BFD session 833 operational data is provided per MPLS-TE LSP. 835 module: ietf-bfd-mpls-te 836 augment /rt:routing/rt:control-plane-protocols 837 /rt:control-plane-protocol/bfd:bfd: 838 +--rw mpls-te 839 +--rw egress 840 | +--rw enable? boolean 841 | +--rw local-multiplier? multiplier 842 | +--rw (interval-config-type)? 843 | | +--:(tx-rx-intervals) 844 | | | +--rw desired-min-tx-interval? uint32 845 | | | +--rw required-min-rx-interval? uint32 846 | | +--:(single-interval) 847 | | +--rw min-interval? uint32 848 | +--rw authentication! {authentication}? 849 | +--rw key-chain? kc:key-chain-ref 850 | +--rw meticulous? boolean 851 +--ro session-statistics 852 +--ro session-count? uint32 853 +--ro session-up-count? uint32 854 +--ro session-down-count? uint32 855 +--ro session-admin-down-count? uint32 856 augment /te:te/te:tunnels/te:tunnel: 857 +--rw local-multiplier? multiplier 858 +--rw (interval-config-type)? 859 | +--:(tx-rx-intervals) 860 | | +--rw desired-min-tx-interval? uint32 861 | | +--rw required-min-rx-interval? uint32 862 | +--:(single-interval) 863 | +--rw min-interval? uint32 864 +--rw demand-enabled? boolean {demand-mode}? 865 +--rw admin-down? boolean 866 +--rw authentication! {authentication}? 867 | +--rw key-chain? kc:key-chain-ref 868 | +--rw meticulous? boolean 869 +--rw encap? identityref 870 augment /te:te/te:lsps-state/te:lsp: 871 +--ro path-type? identityref 872 +--ro ip-encapsulation? boolean 873 +--ro local-discriminator? discriminator 874 +--ro remote-discriminator? discriminator 875 +--ro remote-multiplier? multiplier 876 +--ro demand-capability? boolean {demand-mode}? 877 +--ro source-port? inet:port-number 878 +--ro dest-port? inet:port-number 879 +--ro session-running 880 | +--ro session-index? uint32 881 | +--ro local-state? state 882 | +--ro remote-state? state 883 | +--ro local-diagnostic? iana-bfd-types:diagnostic 884 | +--ro remote-diagnostic? iana-bfd-types:diagnostic 885 | +--ro remote-authenticated? boolean 886 | +--ro remote-authentication-type? iana-bfd-types:auth-type 887 | | {authentication}? 888 | +--ro detection-mode? enumeration 889 | +--ro negotiated-tx-interval? uint32 890 | +--ro negotiated-rx-interval? uint32 891 | +--ro detection-time? uint32 892 | +--ro echo-tx-interval-in-use? uint32 {echo-mode}? 893 +--ro sesssion-statistics 894 | +--ro create-time? yang:date-and-time 895 | +--ro last-down-time? yang:date-and-time 896 | +--ro last-up-time? yang:date-and-time 897 | +--ro down-count? uint32 898 | +--ro admin-down-count? uint32 899 | +--ro receive-packet-count? uint64 900 | +--ro send-packet-count? uint64 901 | +--ro receive-bad-packet? uint64 902 | +--ro send-failed-packet? uint64 903 +--ro mpls-dest-address? inet:ip-address 905 notifications: 906 +---n mpls-te-notification 907 +--ro local-discr? discriminator 908 +--ro remote-discr? discriminator 909 +--ro new-state? state 910 +--ro state-change-reason? iana-bfd-types:diagnostic 911 +--ro time-of-last-state-change? yang:date-and-time 912 +--ro dest-addr? inet:ip-address 913 +--ro source-addr? inet:ip-address 914 +--ro session-index? uint32 915 +--ro path-type? identityref 916 +--ro mpls-dest-address? inet:ip-address 917 +--ro tunnel-name? string 919 2.11. Interaction with other YANG modules 921 Generic YANG Data Model for Connectionless OAM protocols 922 [I-D.ietf-lime-yang-connectionless-oam] describes how the LIME 923 connectionless OAM model could be extended to support BFD. 925 Also, the operation of the BFD data model depends on configuration 926 parameters that are defined in other YANG modules. 928 2.11.1. Module ietf-interfaces 930 The following boolean configuration is defined in A YANG Data Model 931 for Interface Management [RFC7223]: 933 /if:interfaces/if:interface/if:enabled 934 If this configuration is set to "false", no BFD packets can 935 be transmitted or received on that interface. 937 2.11.2. Module ietf-ip 939 The following boolean configuration is defined in A YANG Data Model 940 for IP Management [RFC7277]: 942 /if:interfaces/if:interface/ip:ipv4/ip:enabled 943 If this configuration is set to "false", no BFD IPv4 packets 944 can be transmitted or received on that interface. 946 /if:interfaces/if:interface/ip:ipv4/ip:forwarding 947 If this configuration is set to "false", no BFD IPv4 packets 948 can be transmitted or received on that interface. 950 /if:interfaces/if:interface/ip:ipv6/ip:enabled 951 If this configuration is set to "false", no BFD IPv6 packets 952 can be transmitted or received on that interface. 954 /if:interfaces/if:interface/ip:ipv6/ip:forwarding 955 If this configuration is set to "false", no BFD IPv6 packets 956 can be transmitted or received on that interface. 958 2.11.3. Module ietf-mpls 960 The following boolean configuration is defined in A YANG Data Model 961 for MPLS Base [I-D.ietf-mpls-base-yang]: 963 /rt:routing/mpls:mpls/mpls:interface/mpls:config/mpls:enabled 964 If this configuration is set to "false", no BFD MPLS packets 965 can be transmitted or received on that interface. 967 2.11.4. Module ietf-te 969 The following configuration is defined in the "ietf-te" YANG module 970 YANG Data Model for TE Topology [I-D.ietf-teas-yang-te]: 972 /ietf-te:te/ietf-te:tunnels/ietf-te:tunnel/ietf-te:config/ietf- 973 te:admin-status 974 If this configuration is not set to "state-up", no BFD MPLS 975 packets can be transmitted or received on that tunnel. 977 2.12. IANA BFD YANG Module 979 file "iana-bfd-types@2018-01-22.yang" 981 module iana-bfd-types { 983 yang-version 1.1; 985 namespace "urn:ietf:params:xml:ns:yang:iana-bfd-types"; 987 prefix "iana-bfd-types"; 989 organization "IANA"; 991 contact 992 " Internet Assigned Numbers Authority 994 Postal: ICANN 995 4676 Admiralty Way, Suite 330 996 Marina del Rey, CA 90292 998 Tel: +1 310 823 9358 999 "; 1001 description 1002 "This module contains a collection of YANG data types 1003 considered defined by IANA and used for BFD. 1005 Copyright (c) 2018 IETF Trust and the persons 1006 identified as authors of the code. All rights reserved. 1008 Redistribution and use in source and binary forms, with or 1009 without modification, is permitted pursuant to, and subject 1010 to the license terms contained in, the Simplified BSD License 1011 set forth in Section 4.c of the IETF Trust's Legal Provisions 1012 Relating to IETF Documents 1013 (http://trustee.ietf.org/license-info). 1015 This version of this YANG module is part of RFC XXXX; see 1016 the RFC itself for full legal notices."; 1018 // RFC Ed.: replace XXXX with actual RFC number and remove 1019 // this note 1021 reference "RFC XXXX"; 1023 revision 2018-01-22 { 1024 description "Initial revision."; 1025 reference "RFC XXXX: IANA BFD YANG Data Types."; 1026 } 1028 /* 1029 * Type Definitions 1030 */ 1031 typedef diagnostic { 1032 type enumeration { 1033 enum none { 1034 value 0; 1035 description "None"; 1036 } 1037 enum control-expiry { 1038 value 1; 1039 description "Control timer expiry"; 1040 } 1041 enum echo-failed { 1042 value 2; 1043 description "Echo failure"; 1044 } 1045 enum neighbor-down { 1046 value 3; 1047 description "Neighbor down"; 1048 } 1049 enum forwarding-reset { 1050 value 4; 1051 description "Forwarding reset"; 1052 } 1053 enum path-down { 1054 value 5; 1055 description "Path down"; 1056 } 1057 enum concatenated-path-down { 1058 value 6; 1059 description "Concatenated path down"; 1060 } 1061 enum admin-down { 1062 value 7; 1063 description "Admin down"; 1064 } 1065 enum reverse-concatenated-path-down { 1066 value 8; 1067 description "Reverse concatenated path down"; 1068 } 1069 enum mis-connectivity-defect { 1070 value 9; 1071 description "Mis-connectivity defect as specified in RFC6428"; 1072 } 1073 } 1074 description 1075 "BFD diagnostic as defined in RFC 5880. Range is 0 to 31."; 1076 } 1078 typedef auth-type { 1079 type enumeration { 1080 enum reserved { 1081 value 0; 1082 description "Reserved"; 1083 } 1084 enum simple-password { 1085 value 1; 1086 description "Simple password"; 1087 } 1088 enum keyed-md5 { 1089 value 2; 1090 description "Keyed MD5"; 1092 } 1093 enum meticulous-keyed-md5 { 1094 value 3; 1095 description "Meticulous keyed MD5"; 1096 } 1097 enum keyed-sha1 { 1098 value 4; 1099 description "Keyed SHA1"; 1100 } 1101 enum meticulous-keyed-sha1 { 1102 value 5; 1103 description "Meticulous keyed SHA1"; 1104 } 1105 } 1106 description 1107 "BFD authentication type as defined in RFC 5880. Range is 0 to 1108 255."; 1109 } 1110 } 1112 1114 2.13. BFD types YANG Module 1116 file "ietf-bfd-types@2018-01-22.yang" 1118 module ietf-bfd-types { 1120 yang-version 1.1; 1122 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-types"; 1124 prefix "bfd-types"; 1126 import iana-bfd-types { 1127 prefix "iana-bfd-types"; 1128 } 1130 import ietf-inet-types { 1131 prefix "inet"; 1132 reference "RFC 6991"; 1133 } 1135 import ietf-yang-types { 1136 prefix "yang"; 1137 reference "RFC 6991"; 1138 } 1139 import ietf-routing { 1140 prefix "rt"; 1141 reference "RFC 8022"; 1142 } 1144 import ietf-key-chain { 1145 prefix "kc"; 1146 reference "RFC 8177"; 1147 } 1149 organization "IETF BFD Working Group"; 1151 contact 1152 "WG Web: 1153 WG List: 1155 Editors: Reshad Rahman (rrahman@cisco.com), 1156 Lianshu Zheng (vero.zheng@huawei.com), 1157 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1159 description 1160 "This module contains a collection of BFD specific YANG data type 1161 definitions, as per RFC 5880. 1163 Copyright (c) 2017 IETF Trust and the persons 1164 identified as authors of the code. All rights reserved. 1166 Redistribution and use in source and binary forms, with or 1167 without modification, is permitted pursuant to, and subject 1168 to the license terms contained in, the Simplified BSD License 1169 set forth in Section 4.c of the IETF Trust's Legal Provisions 1170 Relating to IETF Documents 1171 (http://trustee.ietf.org/license-info). 1173 This version of this YANG module is part of RFC XXXX; see 1174 the RFC itself for full legal notices."; 1176 // RFC Ed.: replace XXXX with actual RFC number and remove this 1177 // note 1179 reference "RFC XXXX"; 1181 revision 2018-01-22 { 1182 description "Initial revision."; 1183 reference "RFC XXXX: A YANG data model for BFD"; 1184 } 1186 /* 1187 * Feature definitions 1188 */ 1189 feature authentication { 1190 description 1191 "This feature indicates that the server supports BFD 1192 authentication as defined in RFC 5880."; 1193 } 1195 feature demand-mode { 1196 description 1197 "This feature indicates that the server supports BFD demand mode 1198 as defined in RFC 5880."; 1199 } 1201 feature echo-mode { 1202 description 1203 "This feature indicates that the server supports BFD echo mode 1204 as defined in RFC 5880."; 1205 } 1207 /* 1208 * Identity definitions 1209 */ 1210 identity bfdv1 { 1211 base "rt:control-plane-protocol"; 1212 description "BFD protocol version 1 as per RFC 5880."; 1213 } 1215 identity path-type { 1216 description 1217 "Base identity for BFD path type. The path type indicates 1218 the type of path on which BFD is running."; 1219 } 1220 identity path-ip-sh { 1221 base path-type; 1222 description "BFD on IP single hop as described in RFC 5881."; 1223 } 1224 identity path-ip-mh { 1225 base path-type; 1226 description "BFD on IP multihop paths as described in RFC 5883."; 1227 } 1228 identity path-mpls-te { 1229 base path-type; 1230 description 1231 "BFD on MPLS Traffic Engineering as described in RFC 5884."; 1232 } 1233 identity path-mpls-lsp { 1234 base path-type; 1235 description 1236 "BFD on MPLS Label Switched Path as described in RFC 5884."; 1237 } 1238 identity path-lag { 1239 base path-type; 1240 description 1241 "Micro-BFD on LAG member links as described in RFC 7130."; 1242 } 1244 identity encap-type { 1245 description 1246 "Base identity for BFD encapsulation type."; 1247 } 1248 identity encap-ip { 1249 base encap-type; 1250 description "BFD with IP encapsulation."; 1251 } 1253 /* 1254 * Type Definitions 1255 */ 1256 typedef discriminator { 1257 type uint32; 1258 description "BFD discriminator as described in RFC 5880."; 1259 } 1261 typedef state { 1262 type enumeration { 1263 enum adminDown { 1264 value 0; 1265 description "admindown"; 1266 } 1267 enum down { 1268 value 1; 1269 description "down"; 1270 } 1271 enum init { 1272 value 2; 1273 description "init"; 1274 } 1275 enum up { 1276 value 3; 1277 description "up"; 1278 } 1279 } 1280 description "BFD state as defined in RFC 5880."; 1281 } 1282 typedef multiplier { 1283 type uint8 { 1284 range 1..255; 1285 } 1286 description "BFD multiplier as described in RFC 5880."; 1287 } 1289 typedef hops { 1290 type uint8 { 1291 range 1..255; 1292 } 1293 description 1294 "This corresponds to Time To Live for IPv4 and corresponds to hop 1295 limit for IPv6."; 1296 } 1298 /* 1299 * Groupings 1300 */ 1301 grouping auth-parms { 1302 description 1303 "Grouping for BFD authentication parameters 1304 (see section 6.7 of RFC 5880)."; 1305 container authentication { 1306 if-feature authentication; 1307 presence 1308 "Enables BFD authentication (see section 6.7 of RFC 5880)."; 1309 description "Parameters for BFD authentication."; 1311 leaf key-chain { 1312 type kc:key-chain-ref; 1313 description "Name of the key-chain as per RFC 8177."; 1314 } 1316 leaf meticulous { 1317 type boolean; 1318 description 1319 "Enables meticulous mode as described in section 6.7 " + 1320 "of RFC 5880."; 1321 } 1322 } 1323 } 1325 grouping base-cfg-parms { 1326 description "BFD grouping for base config parameters."; 1327 leaf local-multiplier { 1328 type multiplier; 1329 default 3; 1330 description "Multiplier transmitted by local system."; 1331 } 1333 choice interval-config-type { 1334 description 1335 "Two interval values or 1 value used for both transmit and 1336 receive."; 1337 case tx-rx-intervals { 1338 leaf desired-min-tx-interval { 1339 type uint32; 1340 units microseconds; 1341 default 1000000; 1342 description 1343 "Desired minimum transmit interval of control packets."; 1344 } 1346 leaf required-min-rx-interval { 1347 type uint32; 1348 units microseconds; 1349 default 1000000; 1350 description 1351 "Required minimum receive interval of control packets."; 1352 } 1353 } 1354 case single-interval { 1355 leaf min-interval { 1356 type uint32; 1357 units microseconds; 1358 default 1000000; 1359 description 1360 "Desired minimum transmit interval and required " + 1361 "minimum receive interval of control packets."; 1362 } 1363 } 1364 } 1365 } 1367 grouping client-cfg-parms { 1368 description 1369 "BFD grouping for configuration parameters 1370 used by clients of BFD, e.g. IGP or MPLS."; 1372 leaf enable { 1373 type boolean; 1374 default false; 1375 description 1376 "Indicates whether the BFD is enabled."; 1377 } 1378 uses base-cfg-parms; 1379 } 1381 grouping common-cfg-parms { 1382 description 1383 "BFD grouping for common configuration parameters."; 1385 uses base-cfg-parms; 1387 leaf demand-enabled { 1388 if-feature demand-mode; 1389 type boolean; 1390 default false; 1391 description 1392 "To enable demand mode."; 1393 } 1395 leaf admin-down { 1396 type boolean; 1397 default false; 1398 description 1399 "Is the BFD session administratively down."; 1400 } 1401 uses auth-parms; 1402 } 1404 grouping all-session { 1405 description "BFD session operational information"; 1406 leaf path-type { 1407 type identityref { 1408 base path-type; 1409 } 1410 config "false"; 1411 description 1412 "BFD path type, this indicates the path type that BFD is 1413 running on."; 1414 } 1415 leaf ip-encapsulation { 1416 type boolean; 1417 config "false"; 1418 description "Whether BFD encapsulation uses IP."; 1419 } 1420 leaf local-discriminator { 1421 type discriminator; 1422 config "false"; 1423 description "Local discriminator."; 1424 } 1425 leaf remote-discriminator { 1426 type discriminator; 1427 config "false"; 1428 description "Remote discriminator."; 1429 } 1430 leaf remote-multiplier { 1431 type multiplier; 1432 config "false"; 1433 description "Remote multiplier."; 1434 } 1435 leaf demand-capability { 1436 if-feature demand-mode; 1437 type boolean; 1438 config "false"; 1439 description "Local demand mode capability."; 1440 } 1441 leaf source-port { 1442 when "../ip-encapsulation = 'true'" { 1443 description 1444 "Source port valid only when IP encapsulation is used."; 1445 } 1446 type inet:port-number; 1447 config "false"; 1448 description "Source UDP port"; 1449 } 1450 leaf dest-port { 1451 when "../ip-encapsulation = 'true'" { 1452 description 1453 "Destination port valid only when IP encapsulation is used."; 1454 } 1455 type inet:port-number; 1456 config "false"; 1457 description "Destination UDP port."; 1458 } 1460 container session-running { 1461 config "false"; 1462 description "BFD session running information."; 1463 leaf session-index { 1464 type uint32; 1465 description 1466 "An index used to uniquely identify BFD sessions."; 1467 } 1468 leaf local-state { 1469 type state; 1470 description "Local state."; 1471 } 1472 leaf remote-state { 1473 type state; 1474 description "Remote state."; 1475 } 1476 leaf local-diagnostic { 1477 type iana-bfd-types:diagnostic; 1478 description "Local diagnostic."; 1479 } 1480 leaf remote-diagnostic { 1481 type iana-bfd-types:diagnostic; 1482 description "Remote diagnostic."; 1483 } 1484 leaf remote-authenticated { 1485 type boolean; 1486 description 1487 "Indicates whether incoming BFD control packets are 1488 authenticated."; 1489 } 1490 leaf remote-authentication-type { 1491 when "../remote-authenticated = 'true'" { 1492 description 1493 "Only valid when incoming BFD control packets are 1494 authenticated."; 1495 } 1496 if-feature authentication; 1497 type iana-bfd-types:auth-type; 1498 description 1499 "Authentication type of incoming BFD control packets."; 1500 } 1501 leaf detection-mode { 1502 type enumeration { 1503 enum async-with-echo { 1504 value "1"; 1505 description "Async with echo."; 1506 } 1507 enum async-without-echo { 1508 value "2"; 1509 description "Async without echo."; 1510 } 1511 enum demand-with-echo { 1512 value "3"; 1513 description "Demand with echo."; 1514 } 1515 enum demand-without-echo { 1516 value "4"; 1517 description "Demand without echo."; 1518 } 1519 } 1520 description "Detection mode."; 1521 } 1522 leaf negotiated-tx-interval { 1523 type uint32; 1524 units microseconds; 1525 description "Negotiated transmit interval."; 1526 } 1527 leaf negotiated-rx-interval { 1528 type uint32; 1529 units microseconds; 1530 description "Negotiated receive interval."; 1531 } 1532 leaf detection-time { 1533 type uint32; 1534 units microseconds; 1535 description "Detection time."; 1536 } 1537 leaf echo-tx-interval-in-use { 1538 when "../../path-type = 'bfd-types:path-ip-sh'" { 1539 description 1540 "Echo is supported for IP single-hop only."; 1541 } 1542 if-feature echo-mode; 1543 type uint32; 1544 units microseconds; 1545 description "Echo transmit interval in use."; 1546 } 1547 } 1549 container sesssion-statistics { 1550 config "false"; 1551 description "BFD per-session statistics."; 1553 leaf create-time { 1554 type yang:date-and-time; 1555 description 1556 "Time and date when session was created."; 1557 } 1558 leaf last-down-time { 1559 type yang:date-and-time; 1560 description 1561 "Time and date of last time the session went down."; 1562 } 1563 leaf last-up-time { 1564 type yang:date-and-time; 1565 description 1566 "Time and date of last time the session went up."; 1567 } 1568 leaf down-count { 1569 type uint32; 1570 description "Session Down Count."; 1571 } 1572 leaf admin-down-count { 1573 type uint32; 1574 description "Session Admin-Down Count."; 1575 } 1576 leaf receive-packet-count { 1577 type uint64; 1578 description "Received Packet Count."; 1579 } 1580 leaf send-packet-count { 1581 type uint64; 1582 description "Sent Packet Count."; 1583 } 1584 leaf receive-bad-packet { 1585 type uint64; 1586 description "Received bad packet count."; 1587 } 1588 leaf send-failed-packet { 1589 type uint64; 1590 description "Packet Failed to Send Count."; 1591 } 1592 } 1593 } 1595 grouping session-statistics { 1596 description "Grouping for session counters."; 1597 container session-statistics { 1598 config false; 1599 description "BFD session counters."; 1600 leaf session-count { 1601 type uint32; 1602 description "Number of sessions."; 1603 } 1604 leaf session-up-count { 1605 type uint32; 1606 description "Count of sessions which are up."; 1607 } 1608 leaf session-down-count { 1609 type uint32; 1610 description "Count of sessions which are down."; 1611 } 1612 leaf session-admin-down-count { 1613 type uint32; 1614 description "Count of sessions which are admin-down."; 1615 } 1616 } 1617 } 1618 grouping notification-parms { 1619 description 1620 "This group describes common parameters that will be sent " + 1621 "as part of BFD notification."; 1623 leaf local-discr { 1624 type discriminator; 1625 description "BFD local discriminator."; 1626 } 1628 leaf remote-discr { 1629 type discriminator; 1630 description "BFD remote discriminator."; 1631 } 1633 leaf new-state { 1634 type state; 1635 description "Current BFD state."; 1636 } 1638 leaf state-change-reason { 1639 type iana-bfd-types:diagnostic; 1640 description "BFD state change reason."; 1641 } 1643 leaf time-of-last-state-change { 1644 type yang:date-and-time; 1645 description 1646 "Calendar time of previous state change."; 1647 } 1649 leaf dest-addr { 1650 type inet:ip-address; 1651 description "BFD peer address."; 1652 } 1654 leaf source-addr { 1655 type inet:ip-address; 1656 description "BFD local address."; 1657 } 1659 leaf session-index { 1660 type uint32; 1661 description "An index used to uniquely identify BFD sessions."; 1662 } 1664 leaf path-type { 1665 type identityref { 1666 base path-type; 1667 } 1668 description "BFD path type."; 1669 } 1670 } 1671 } 1673 1675 2.14. BFD top-level YANG Module 1677 file "ietf-bfd@2018-01-22.yang" 1679 module ietf-bfd { 1681 yang-version 1.1; 1683 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd"; 1685 prefix "bfd"; 1687 import ietf-bfd-types { 1688 prefix "bfd-types"; 1689 } 1691 import ietf-routing { 1692 prefix "rt"; 1693 reference "RFC 8022"; 1694 } 1696 organization "IETF BFD Working Group"; 1698 contact 1699 "WG Web: 1700 WG List: 1702 Editors: Reshad Rahman (rrahman@cisco.com), 1703 Lianshu Zheng (vero.zheng@huawei.com), 1704 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1706 description 1707 "This module contains the YANG definition for BFD parameters as 1708 per RFC 5880. 1710 Copyright (c) 2017 IETF Trust and the persons 1711 identified as authors of the code. All rights reserved. 1713 Redistribution and use in source and binary forms, with or 1714 without modification, is permitted pursuant to, and subject 1715 to the license terms contained in, the Simplified BSD License 1716 set forth in Section 4.c of the IETF Trust's Legal Provisions 1717 Relating to IETF Documents 1718 (http://trustee.ietf.org/license-info). 1720 This version of this YANG module is part of RFC XXXX; see 1721 the RFC itself for full legal notices."; 1723 // RFC Ed.: replace XXXX with actual RFC number and remove this 1724 // note 1726 reference "RFC XXXX"; 1728 revision 2018-01-22 { 1729 description "Initial revision."; 1730 reference "RFC XXXX: A YANG data model for BFD"; 1731 } 1733 augment "/rt:routing/rt:control-plane-protocols/" 1734 + "rt:control-plane-protocol" { 1735 when "rt:type = 'bfd-types:bfdv1'" { 1736 description 1737 "This augmentation is only valid for a control-plane protocol 1738 instance of BFD (type 'bfdv1')."; 1739 } 1740 description "BFD augmentation."; 1742 container bfd { 1743 description "BFD top level container."; 1745 uses bfd-types:session-statistics; 1746 } 1747 } 1748 } 1750 1752 2.15. BFD IP single-hop YANG Module 1754 file "ietf-bfd-ip-sh@2018-01-22.yang" 1756 module ietf-bfd-ip-sh { 1758 yang-version 1.1; 1760 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-ip-sh"; 1761 prefix "bfd-ip-sh"; 1763 import ietf-bfd-types { 1764 prefix "bfd-types"; 1765 } 1767 import ietf-bfd { 1768 prefix "bfd"; 1769 } 1771 import ietf-interfaces { 1772 prefix "if"; 1773 reference "RFC 7223"; 1774 } 1776 import ietf-inet-types { 1777 prefix "inet"; 1778 reference "RFC 6991"; 1779 } 1781 import ietf-routing { 1782 prefix "rt"; 1783 reference "RFC 8022"; 1784 } 1786 organization "IETF BFD Working Group"; 1788 contact 1789 "WG Web: 1790 WG List: 1792 Editors: Reshad Rahman (rrahman@cisco.com), 1793 Lianshu Zheng (vero.zheng@huawei.com), 1794 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1796 description 1797 "This module contains the YANG definition for BFD IP single-hop 1798 as per RFC 5881. 1800 Copyright (c) 2018 IETF Trust and the persons 1801 identified as authors of the code. All rights reserved. 1803 Redistribution and use in source and binary forms, with or 1804 without modification, is permitted pursuant to, and subject 1805 to the license terms contained in, the Simplified BSD License 1806 set forth in Section 4.c of the IETF Trust's Legal Provisions 1807 Relating to IETF Documents 1808 (http://trustee.ietf.org/license-info). 1809 This version of this YANG module is part of RFC XXXX; see 1810 the RFC itself for full legal notices."; 1812 // RFC Ed.: replace XXXX with actual RFC number and remove this 1813 // note 1815 reference "RFC XXXX"; 1817 revision 2018-01-22 { 1818 description "Initial revision."; 1819 reference "RFC XXXX: A YANG data model for BFD IP single-hop"; 1820 } 1822 /* 1823 * Augments 1824 */ 1825 augment "/rt:routing/rt:control-plane-protocols/" 1826 + "rt:control-plane-protocol/bfd:bfd" { 1827 description "BFD augmentation for IP single-hop"; 1828 container ip-sh { 1829 description "BFD IP single-hop top level container"; 1831 uses bfd-types:session-statistics; 1833 list sessions { 1834 key "interface dest-addr"; 1835 description "List of IP single-hop sessions"; 1836 leaf interface { 1837 type if:interface-ref; 1838 description 1839 "Interface on which the BFD session is running."; 1840 } 1841 leaf dest-addr { 1842 type inet:ip-address; 1843 description "IP address of the peer."; 1844 } 1845 leaf source-addr { 1846 type inet:ip-address; 1847 description "Local IP address."; 1848 } 1850 uses bfd-types:common-cfg-parms; 1852 uses bfd-types:all-session; 1853 } 1854 list interfaces { 1855 key "interface"; 1856 description "List of interfaces."; 1857 leaf interface { 1858 type if:interface-ref; 1859 description 1860 "BFD information for this interface."; 1861 } 1863 uses bfd-types:auth-parms; 1864 } 1865 } 1866 } 1868 /* 1869 * Notifications 1870 */ 1871 notification singlehop-notification { 1872 description 1873 "Notification for BFD single-hop session state change. An " + 1874 "implementation may rate-limit notifications, e.g. when a" + 1875 "session is continuously changing state."; 1877 uses bfd-types:notification-parms; 1879 leaf interface { 1880 type if:interface-ref; 1881 description "Interface to which this BFD session belongs to."; 1882 } 1884 leaf echo-enabled { 1885 type boolean; 1886 description "Was echo enabled for BFD."; 1887 } 1888 } 1890 } 1892 1894 2.16. BFD IP multihop YANG Module 1896 file "ietf-bfd-ip-mh@2018-01-22.yang" 1898 module ietf-bfd-ip-mh { 1900 yang-version 1.1; 1902 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-ip-mh"; 1904 prefix "bfd-ip-mh"; 1905 import ietf-bfd-types { 1906 prefix "bfd-types"; 1907 } 1909 import ietf-bfd { 1910 prefix "bfd"; 1911 } 1913 import ietf-inet-types { 1914 prefix "inet"; 1915 reference "RFC 6991"; 1916 } 1918 import ietf-routing { 1919 prefix "rt"; 1920 reference "RFC 8022"; 1921 } 1923 organization "IETF BFD Working Group"; 1925 contact 1926 "WG Web: 1927 WG List: 1929 Editors: Reshad Rahman (rrahman@cisco.com), 1930 Lianshu Zheng (vero.zheng@huawei.com), 1931 Mahesh Jethanandani (mjethanandani@gmail.com)"; 1933 description 1934 "This module contains the YANG definition for BFD IP multi-hop 1935 as per RFC 5883. 1937 Copyright (c) 2018 IETF Trust and the persons 1938 identified as authors of the code. All rights reserved. 1940 Redistribution and use in source and binary forms, with or 1941 without modification, is permitted pursuant to, and subject 1942 to the license terms contained in, the Simplified BSD License 1943 set forth in Section 4.c of the IETF Trust's Legal Provisions 1944 Relating to IETF Documents 1945 (http://trustee.ietf.org/license-info). 1947 This version of this YANG module is part of RFC XXXX; see 1948 the RFC itself for full legal notices."; 1950 // RFC Ed.: replace XXXX with actual RFC number and remove this 1951 // note 1952 reference "RFC XXXX"; 1954 revision 2018-01-22 { 1955 description "Initial revision."; 1956 reference "RFC XXXX: A YANG data model for BFD IP multihop."; 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 multihop."; 1965 container ip-mh { 1966 description "BFD IP multihop top level container."; 1968 uses bfd-types:session-statistics; 1970 list session-group { 1971 key "source-addr dest-addr"; 1972 description 1973 "Group of BFD IP multi-hop sessions (for ECMP). A " + 1974 "group of sessions is between 1 source and 1 " + 1975 "destination, each session has a different field " + 1976 "in UDP/IP hdr for ECMP."; 1978 leaf source-addr { 1979 type inet:ip-address; 1980 description 1981 "Local IP address."; 1982 } 1983 leaf dest-addr { 1984 type inet:ip-address; 1985 description 1986 "IP address of the peer."; 1987 } 1988 uses bfd-types:common-cfg-parms; 1990 leaf tx-ttl { 1991 type bfd-types:hops; 1992 default 255; 1993 description "Hop count of outgoing BFD control packets."; 1994 } 1995 leaf rx-ttl { 1996 type bfd-types:hops; 1997 mandatory true; 1998 description 1999 "Minimum allowed hop count value for incoming BFD control 2000 packets. Control packets whose hop count is lower than this 2001 value are dropped."; 2002 } 2003 list sessions { 2004 config false; 2005 description 2006 "The multiple BFD sessions between a source and a " + 2007 "destination."; 2008 uses bfd-types:all-session; 2009 } 2010 } 2011 } 2012 } 2014 /* 2015 * Notifications 2016 */ 2017 notification multihop-notification { 2018 description 2019 "Notification for BFD multi-hop session state change. An " + 2020 "implementation may rate-limit notifications, e.g. when a" + 2021 "session is continuously changing state."; 2023 uses bfd-types:notification-parms; 2024 } 2025 } 2027 2029 2.17. BFD over LAG YANG Module 2031 file "ietf-bfd-lag@2018-01-22.yang" 2033 module ietf-bfd-lag { 2035 yang-version 1.1; 2037 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-lag"; 2039 prefix "bfd-lag"; 2041 import ietf-bfd-types { 2042 prefix "bfd-types"; 2043 } 2045 import ietf-bfd { 2046 prefix "bfd"; 2047 } 2048 import ietf-interfaces { 2049 prefix "if"; 2050 reference "RFC 7223"; 2051 } 2053 import ietf-inet-types { 2054 prefix "inet"; 2055 reference "RFC 6991"; 2056 } 2058 import ietf-routing { 2059 prefix "rt"; 2060 reference "RFC 8022"; 2061 } 2063 organization "IETF BFD Working Group"; 2065 contact 2066 "WG Web: 2067 WG List: 2069 Editors: Reshad Rahman (rrahman@cisco.com), 2070 Lianshu Zheng vero.zheng@huawei.com), 2071 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2073 description 2074 "This module contains the YANG definition for BFD over LAG 2075 interfaces as per RFC7130. 2077 Copyright (c) 2018 IETF Trust and the persons 2078 identified as authors of the code. All rights reserved. 2080 Redistribution and use in source and binary forms, with or 2081 without modification, is permitted pursuant to, and subject 2082 to the license terms contained in, the Simplified BSD License 2083 set forth in Section 4.c of the IETF Trust's Legal Provisions 2084 Relating to IETF Documents 2085 (http://trustee.ietf.org/license-info). 2087 This version of this YANG module is part of RFC XXXX; see 2088 the RFC itself for full legal notices."; 2090 // RFC Ed.: replace XXXX with actual RFC number and remove this 2091 // note 2093 reference "RFC XXXX"; 2095 revision 2018-01-22 { 2096 description "Initial revision."; 2097 reference "RFC XXXX: A YANG data model for BFD over LAG"; 2098 } 2100 /* 2101 * Augments 2102 */ 2103 augment "/rt:routing/rt:control-plane-protocols/" 2104 + "rt:control-plane-protocol/bfd:bfd" { 2105 description "BFD augmentation for LAG"; 2106 container lag { 2107 description "BFD over LAG top level container"; 2109 container micro-bfd-ipv4-session-statistics { 2110 description "Micro-BFD IPv4 session counters."; 2111 uses bfd-types:session-statistics; 2112 } 2113 container micro-bfd-ipv6-session-statistics { 2114 description "Micro-BFD IPv6 session counters."; 2115 uses bfd-types:session-statistics; 2116 } 2118 list sessions { 2119 key "lag-name"; 2120 description "A LAG interface on which BFD is running."; 2121 leaf lag-name { 2122 type if:interface-ref ; 2123 description "Name of the LAG"; 2124 } 2125 leaf ipv4-dest-addr { 2126 type inet:ipv4-address; 2127 description 2128 "IPv4 address of the peer, for IPv4 micro-BFD."; 2129 } 2130 leaf ipv6-dest-addr { 2131 type inet:ipv6-address; 2132 description 2133 "IPv6 address of the peer, for IPv6 micro-BFD."; 2134 } 2135 uses bfd-types:common-cfg-parms; 2137 leaf use-ipv4 { 2138 type boolean; 2139 description "Using IPv4 micro-BFD."; 2140 } 2141 leaf use-ipv6 { 2142 type boolean; 2143 description "Using IPv6 micro-BFD."; 2145 } 2147 list member-links { 2148 key "member-link"; 2149 config false; 2150 description 2151 "Micro-BFD over LAG. This represents one member link."; 2153 leaf member-link { 2154 type if:interface-ref; 2155 description 2156 "Member link on which micro-BFD is running."; 2157 } 2158 container micro-bfd-ipv4 { 2159 when "../../use-ipv4 = 'true'" { 2160 description "Needed only if IPv4 is used."; 2161 } 2162 description 2163 "Micro-BFD IPv4 session state on member link."; 2164 uses bfd-types:all-session; 2165 } 2166 container micro-bfd-ipv6 { 2167 when "../../use-ipv6 = 'true'" { 2168 description "Needed only if IPv6 is used."; 2169 } 2170 description 2171 "Micro-BFD IPv6 session state on member link."; 2172 uses bfd-types:all-session; 2173 } 2174 } 2175 } 2176 } 2177 } 2179 /* 2180 * Notifications 2181 */ 2182 notification lag-notification { 2183 description 2184 "Notification for BFD over LAG session state change. " + 2185 "An implementation may rate-limit notifications, e.g. when a" + 2186 "session is continuously changing state."; 2188 uses bfd-types:notification-parms; 2190 leaf lag-name { 2191 type if:interface-ref; 2192 description "LAG interface name."; 2194 } 2196 leaf member-link { 2197 type if:interface-ref; 2198 description "Member link on which BFD is running."; 2199 } 2200 } 2201 } 2203 2205 2.18. BFD over MPLS YANG Module 2207 file "ietf-bfd-mpls@2018-01-22.yang" 2209 module ietf-bfd-mpls { 2211 yang-version 1.1; 2213 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-mpls"; 2215 prefix "bfd-mpls"; 2217 import ietf-bfd-types { 2218 prefix "bfd-types"; 2219 } 2221 import ietf-bfd { 2222 prefix "bfd"; 2223 } 2225 import ietf-inet-types { 2226 prefix "inet"; 2227 reference "RFC 6991"; 2228 } 2230 import ietf-routing { 2231 prefix "rt"; 2232 reference "RFC 8022"; 2233 } 2235 organization "IETF BFD Working Group"; 2237 contact 2238 "WG Web: 2239 WG List: 2241 Editors: Reshad Rahman (rrahman@cisco.com), 2242 Lianshu Zheng (vero.zheng@huawei.com), 2243 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2245 description 2246 "This module contains the YANG definition for BFD parameters for 2247 MPLS LSPs as per RFC 5884. 2249 Copyright (c) 2018 IETF Trust and the persons 2250 identified as authors of the code. All rights reserved. 2252 Redistribution and use in source and binary forms, with or 2253 without modification, is permitted pursuant to, and subject 2254 to the license terms contained in, the Simplified BSD License 2255 set forth in Section 4.c of the IETF Trust's Legal Provisions 2256 Relating to IETF Documents 2257 (http://trustee.ietf.org/license-info). 2259 This version of this YANG module is part of RFC XXXX; see 2260 the RFC itself for full legal notices."; 2262 // RFC Ed.: replace XXXX with actual RFC number and remove this 2263 // note 2265 reference "RFC XXXX"; 2267 revision 2018-01-22 { 2268 description "Initial revision."; 2269 reference "RFC XXXX: A YANG data model for BFD over MPLS LSPs"; 2270 } 2272 /* 2273 * Identity definitions 2274 */ 2275 identity encap-gach { 2276 base bfd-types:encap-type; 2277 description 2278 "BFD with G-ACh encapsulation as per RFC 5586."; 2279 } 2281 identity encap-ip-gach { 2282 base bfd-types:encap-type; 2283 description 2284 "BFD with IP and G-ACh encapsulation as per RFC 5586."; 2285 } 2287 /* 2288 * Groupings 2289 */ 2291 grouping encap-cfg { 2292 description "Configuration for BFD encapsulation"; 2294 leaf encap { 2295 type identityref { 2296 base bfd-types:encap-type; 2297 } 2298 default bfd-types:encap-ip; 2299 description "BFD encapsulation"; 2300 } 2301 } 2303 grouping mpls-dest-address { 2304 description "Destination address as per RFC 5884."; 2306 leaf mpls-dest-address { 2307 type inet:ip-address; 2308 config "false"; 2309 description 2310 "Destination address as per RFC 5884. 2311 Needed if IP encapsulation is used."; 2312 } 2313 } 2315 /* 2316 * Augments 2317 */ 2318 augment "/rt:routing/rt:control-plane-protocols/" 2319 + "rt:control-plane-protocol/bfd:bfd" { 2320 description "BFD augmentation for MPLS."; 2321 container mpls { 2322 description "BFD MPLS top level container."; 2324 uses bfd-types:session-statistics; 2326 container egress { 2327 description "Egress configuration."; 2329 uses bfd-types:client-cfg-parms; 2331 uses bfd-types:auth-parms; 2332 } 2334 list session-group { 2335 key "mpls-fec"; 2336 description 2337 "Group of BFD MPLS sessions (for ECMP). A group of " + 2338 "sessions is for 1 FEC, each session has a different " + 2339 "field in UDP/IP hdr for ECMP."; 2340 leaf mpls-fec { 2341 type inet:ip-prefix; 2342 description "MPLS FEC."; 2343 } 2345 uses bfd-types:common-cfg-parms; 2347 list sessions { 2348 config false; 2349 description 2350 "The BFD sessions for an MPLS FEC. Local " + 2351 "discriminator is unique for each session in the " + 2352 "group."; 2353 uses bfd-types:all-session; 2355 uses bfd-mpls:mpls-dest-address; 2356 } 2357 } 2358 } 2359 } 2361 /* 2362 * Notifications 2363 */ 2364 notification mpls-notification { 2365 description 2366 "Notification for BFD over MPLS FEC session state change. " + 2367 "An implementation may rate-limit notifications, e.g. when a" + 2368 "session is continuously changing state."; 2370 uses bfd-types:notification-parms; 2372 leaf mpls-dest-address { 2373 type inet:ip-address; 2374 description 2375 "Destination address as per RFC 5884. 2376 Needed if IP encapsulation is used."; 2377 } 2378 } 2379 } 2381 2383 2.19. BFD over MPLS-TE YANG Module 2385 file "ietf-bfd-mpls-te@2018-01-22.yang" 2387 module ietf-bfd-mpls-te { 2389 yang-version 1.1; 2391 namespace "urn:ietf:params:xml:ns:yang:ietf-bfd-mpls-te"; 2393 prefix "bfd-mpls-te"; 2395 import ietf-bfd-types { 2396 prefix "bfd-types"; 2397 } 2399 import ietf-bfd { 2400 prefix "bfd"; 2401 } 2403 import ietf-bfd-mpls { 2404 prefix "bfd-mpls"; 2405 } 2407 import ietf-te { 2408 prefix "te"; 2409 } 2411 import ietf-routing { 2412 prefix "rt"; 2413 reference "RFC 8022"; 2414 } 2416 organization "IETF BFD Working Group"; 2418 contact 2419 "WG Web: 2420 WG List: 2422 Editors: Reshad Rahman (rrahman@cisco.com), 2423 Lianshu Zheng (vero.zheng@huawei.com), 2424 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2426 description 2427 "This module contains the YANG definition for BFD parameters for 2428 MPLS Traffic Engineering as per RFC 5884. 2430 Copyright (c) 2018 IETF Trust and the persons 2431 identified as authors of the code. All rights reserved. 2433 Redistribution and use in source and binary forms, with or 2434 without modification, is permitted pursuant to, and subject 2435 to the license terms contained in, the Simplified BSD License 2436 set forth in Section 4.c of the IETF Trust's Legal Provisions 2437 Relating to IETF Documents 2438 (http://trustee.ietf.org/license-info). 2440 This version of this YANG module is part of RFC XXXX; see 2441 the RFC itself for full legal notices."; 2443 // RFC Ed.: replace XXXX with actual RFC number and remove this 2444 // note 2446 reference "RFC XXXX"; 2448 revision 2018-01-22 { 2449 description "Initial revision."; 2450 reference "RFC XXXX: A YANG data model for BFD over MPLS-TE"; 2451 } 2453 /* 2454 * Augments 2455 */ 2456 augment "/rt:routing/rt:control-plane-protocols/" 2457 + "rt:control-plane-protocol/bfd:bfd" { 2458 description "BFD augmentation for MPLS-TE."; 2459 container mpls-te { 2460 description "BFD MPLS-TE top level container."; 2462 container egress { 2463 description "Egress configuration."; 2465 uses bfd-types:client-cfg-parms; 2467 uses bfd-types:auth-parms; 2468 } 2470 uses bfd-types:session-statistics; 2471 } 2472 } 2474 augment "/te:te/te:tunnels/te:tunnel" { 2475 description "BFD configuration on MPLS-TE tunnel."; 2477 uses bfd-types:common-cfg-parms; 2478 uses bfd-mpls:encap-cfg; 2479 } 2481 augment "/te:te/te:lsps-state/te:lsp" { 2482 when "/te:te/te:lsps-state/te:lsp/te:origin-type != 'transit'" { 2483 description "BFD information not needed at transit points."; 2484 } 2485 description "BFD state information on MPLS-TE LSP."; 2487 uses bfd-types:all-session; 2489 uses bfd-mpls:mpls-dest-address; 2490 } 2492 /* 2493 * Notifications 2494 */ 2495 notification mpls-te-notification { 2496 description 2497 "Notification for BFD over MPLS-TE session state change. " + 2498 "An implementation may rate-limit notifications, e.g. when a" + 2499 "session is continuously changing state."; 2501 uses bfd-types:notification-parms; 2503 uses bfd-mpls:mpls-dest-address; 2505 leaf tunnel-name { 2506 type string; 2507 description "MPLS-TE tunnel on which BFD was running."; 2508 } 2509 } 2510 } 2512 2514 3. Data Model examples 2516 This section presents some simple and illustrative examples on how to 2517 configure BFD. 2519 3.1. IP single-hop 2521 The following is an example configuration for a BFD IP single-hop 2522 session. The desired transmit interval and the required receive 2523 interval are both set to 10ms. 2525 2526 2527 2528 2529 2530 2531 2532 2533 eth0 2534 2001:203:0:113::101 2535 10000 2536 10000 2537 2538 2539 2540 2541 2542 2543 2545 3.2. IP multihop 2547 The following is an example configuration for a BFD IP multihop 2548 session group. The desired transmit interval and the required 2549 receive interval are both set to 150ms. 2551 2552 2553 2554 2555 2556 2557 2558 2559 2001:202:0:114::100 2560 2001:204:0:113::103 2561 150000 2562 150000 2563 2564 2565 2566 2567 2568 2569 2570 4. Security Considerations 2572 The YANG module defined in this memo is designed to be accessed via 2573 the NETCONF protocol [RFC6241]. The lowest NETCONF layer is the 2574 secure transport layer and the mandatory to implement secure 2575 transport is SSH [RFC6242]. The NETCONF access control model 2576 [RFC6536] provides the means to restrict access for particular 2577 NETCONF users to a pre-configured subset of all available NETCONF 2578 protocol operations and content. 2580 The YANG module has writeable data nodes which can be used for 2581 creation of BFD sessions and modification of BFD session parameters. 2582 The system should "police" creation of BFD sessions to prevent new 2583 sessions from causing existing BFD sessions to fail. For BFD session 2584 modification, the BFD protocol has mechanisms in place which allow 2585 for in service modification. 2587 5. IANA Considerations 2589 The IANA is requested to as assign a new namespace URI from the IETF 2590 XML registry. 2592 This document registers the following namesace URIs in the IETF XML 2593 registry [RFC3688]: 2595 -------------------------------------------------------------------- 2597 URI: urn:ietf:params:xml:ns:yang:ietf-bfd 2599 Registrant Contact: The IESG. 2601 XML: N/A, the requested URI is an XML namespace. 2603 -------------------------------------------------------------------- 2605 -------------------------------------------------------------------- 2607 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-ip-sh 2609 Registrant Contact: The IESG. 2611 XML: N/A, the requested URI is an XML namespace. 2613 -------------------------------------------------------------------- 2615 -------------------------------------------------------------------- 2617 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-mh 2618 Registrant Contact: The IESG. 2620 XML: N/A, the requested URI is an XML namespace. 2622 -------------------------------------------------------------------- 2624 -------------------------------------------------------------------- 2626 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-lag 2628 Registrant Contact: The IESG. 2630 XML: N/A, the requested URI is an XML namespace. 2632 -------------------------------------------------------------------- 2634 -------------------------------------------------------------------- 2636 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-mpls 2638 Registrant Contact: The IESG. 2640 XML: N/A, the requested URI is an XML namespace. 2642 -------------------------------------------------------------------- 2644 -------------------------------------------------------------------- 2646 URI: urn:ietf:params:xml:ns:yang:ietf-bfd-mpls-te 2648 Registrant Contact: The IESG. 2650 XML: N/A, the requested URI is an XML namespace. 2652 -------------------------------------------------------------------- 2654 5.1. IANA-Maintained iana-bfd-types module 2656 This document defines the initial version of the IANA-maintained 2657 iana-bfd-types YANG module. 2659 The iana-bfd-types YANG module is intended to reflect the "BFD 2660 Diagnostic Codes" registry and "BFD Authentication Types" registry at 2661 https://www.iana.org/assignments/bfd-parameters/bfd-parameters.xhtml 2663 6. Acknowledgements 2665 We would also like to thank Nobo Akiya and Jeff Haas for their 2666 encouragement on this work. We would also like to thank Rakesh 2667 Gandhi and Tarek Saad for their help on the MPLS-TE model. We would 2668 also like to thank Acee Lindem for his guidance. 2670 7. References 2672 7.1. Normative References 2674 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 2675 Requirement Levels", BCP 14, RFC 2119, 2676 DOI 10.17487/RFC2119, March 1997, . 2679 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 2680 DOI 10.17487/RFC3688, January 2004, . 2683 [RFC5586] Bocci, M., Ed., Vigoureux, M., Ed., and S. Bryant, Ed., 2684 "MPLS Generic Associated Channel", RFC 5586, 2685 DOI 10.17487/RFC5586, June 2009, . 2688 [RFC5880] Katz, D. and D. Ward, "Bidirectional Forwarding Detection 2689 (BFD)", RFC 5880, DOI 10.17487/RFC5880, June 2010, 2690 . 2692 [RFC5881] Katz, D. and D. Ward, "Bidirectional Forwarding Detection 2693 (BFD) for IPv4 and IPv6 (Single Hop)", RFC 5881, 2694 DOI 10.17487/RFC5881, June 2010, . 2697 [RFC5882] Katz, D. and D. Ward, "Generic Application of 2698 Bidirectional Forwarding Detection (BFD)", RFC 5882, 2699 DOI 10.17487/RFC5882, June 2010, . 2702 [RFC5883] Katz, D. and D. Ward, "Bidirectional Forwarding Detection 2703 (BFD) for Multihop Paths", RFC 5883, DOI 10.17487/RFC5883, 2704 June 2010, . 2706 [RFC5884] Aggarwal, R., Kompella, K., Nadeau, T., and G. Swallow, 2707 "Bidirectional Forwarding Detection (BFD) for MPLS Label 2708 Switched Paths (LSPs)", RFC 5884, DOI 10.17487/RFC5884, 2709 June 2010, . 2711 [RFC5885] Nadeau, T., Ed. and C. Pignataro, Ed., "Bidirectional 2712 Forwarding Detection (BFD) for the Pseudowire Virtual 2713 Circuit Connectivity Verification (VCCV)", RFC 5885, 2714 DOI 10.17487/RFC5885, June 2010, . 2717 [RFC6991] Schoenwaelder, J., Ed., "Common YANG Data Types", 2718 RFC 6991, DOI 10.17487/RFC6991, July 2013, 2719 . 2721 [RFC7130] Bhatia, M., Ed., Chen, M., Ed., Boutros, S., Ed., 2722 Binderberger, M., Ed., and J. Haas, Ed., "Bidirectional 2723 Forwarding Detection (BFD) on Link Aggregation Group (LAG) 2724 Interfaces", RFC 7130, DOI 10.17487/RFC7130, February 2725 2014, . 2727 [RFC7223] Bjorklund, M., "A YANG Data Model for Interface 2728 Management", RFC 7223, DOI 10.17487/RFC7223, May 2014, 2729 . 2731 [RFC7277] Bjorklund, M., "A YANG Data Model for IP Management", 2732 RFC 7277, DOI 10.17487/RFC7277, June 2014, 2733 . 2735 [RFC8022] Lhotka, L. and A. Lindem, "A YANG Data Model for Routing 2736 Management", RFC 8022, DOI 10.17487/RFC8022, November 2737 2016, . 2739 [RFC8177] Lindem, A., Ed., Qu, Y., Yeung, D., Chen, I., and J. 2740 Zhang, "YANG Data Model for Key Chains", RFC 8177, 2741 DOI 10.17487/RFC8177, June 2017, . 2744 7.2. Informative References 2746 [I-D.dsdt-nmda-guidelines] 2747 Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 2748 and R. Wilton, "Guidelines for YANG Module Authors 2749 (NMDA)", draft-dsdt-nmda-guidelines-01 (work in progress), 2750 May 2017. 2752 [I-D.ietf-lime-yang-connectionless-oam] 2753 Kumar, D., Wang, Z., Wu, Q., Rahman, R., and S. Raghavan, 2754 "Generic YANG Data Model for the Management of Operations, 2755 Administration, and Maintenance (OAM) Protocols that use 2756 Connectionless Communications", draft-ietf-lime-yang- 2757 connectionless-oam-18 (work in progress), November 2017. 2759 [I-D.ietf-mpls-base-yang] 2760 Raza, K., Gandhi, R., Liu, X., Beeram, V., Saad, T., 2761 Bryskin, I., Chen, X., Jones, R., and B. Wen, "A YANG Data 2762 Model for MPLS Base", draft-ietf-mpls-base-yang-05 (work 2763 in progress), July 2017. 2765 [I-D.ietf-netmod-schema-mount] 2766 Bjorklund, M. and L. Lhotka, "YANG Schema Mount", draft- 2767 ietf-netmod-schema-mount-08 (work in progress), October 2768 2017. 2770 [I-D.ietf-rtgwg-device-model] 2771 Lindem, A., Berger, L., Bogdanovic, D., and C. Hopps, 2772 "Network Device YANG Logical Organization", draft-ietf- 2773 rtgwg-device-model-02 (work in progress), March 2017. 2775 [I-D.ietf-rtgwg-lne-model] 2776 Berger, L., Hopps, C., Lindem, A., Bogdanovic, D., and X. 2777 Liu, "YANG Logical Network Elements", draft-ietf-rtgwg- 2778 lne-model-05 (work in progress), December 2017. 2780 [I-D.ietf-rtgwg-ni-model] 2781 Berger, L., Hopps, C., Lindem, A., Bogdanovic, D., and X. 2782 Liu, "YANG Network Instances", draft-ietf-rtgwg-ni- 2783 model-05 (work in progress), December 2017. 2785 [I-D.ietf-teas-yang-te] 2786 Saad, T., Gandhi, R., Liu, X., Beeram, V., Shah, H., and 2787 I. Bryskin, "A YANG Data Model for Traffic Engineering 2788 Tunnels and Interfaces", draft-ietf-teas-yang-te-10 (work 2789 in progress), December 2017. 2791 Appendix A. Echo function configuration example 2793 The following intervals are added for the echo function (if 2794 supported): 2796 desired-min-echo-tx-interval 2797 This is the minimum interval that the local system would like 2798 to use when transmitting BFD echo packets. If 0, the echo 2799 function as defined in BFD [RFC5880] is disabled. 2801 required-min-echo-rx-interval 2802 This is the Required Min Echo RX Interval as defined in BFD 2803 [RFC5880]. 2805 module: example-bfd-echo 2806 augment /rt:routing/rt:control-plane-protocols 2807 /rt:control-plane-protocol/bfd:bfd/bfd-ip-sh:ip-sh 2808 /bfd-ip-sh:sessions: 2809 +--rw echo {bfd-types:echo-mode}? 2810 +--rw desired-min-echo-tx-interval? uint32 2811 +--rw required-min-echo-rx-interval? uint32 2813 A.1. Example YANG module for BFD echo function 2815 module example-bfd-echo { 2816 namespace "tag:example.com,2017:example-bfd-echo"; 2818 prefix "example-bfd-echo"; 2820 import ietf-bfd-types { 2821 prefix "bfd-types"; 2822 } 2824 import ietf-bfd { 2825 prefix "bfd"; 2826 } 2828 import ietf-bfd-ip-sh { 2829 prefix "bfd-ip-sh"; 2830 } 2832 import ietf-routing { 2833 prefix "rt"; 2834 } 2836 organization "IETF BFD Working Group"; 2838 contact 2839 "WG Web: 2840 WG List: 2842 Editors: Reshad Rahman (rrahman@cisco.com), 2843 Lianshu Zheng (vero.zheng@huawei.com), 2844 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2846 description 2847 "This module contains an example YANG augmentation for configuration 2848 of BFD echo function. 2850 Copyright (c) 2017 IETF Trust and the persons 2851 identified as authors of the code. All rights reserved. 2853 Redistribution and use in source and binary forms, with or 2854 without modification, is permitted pursuant to, and subject 2855 to the license terms contained in, the Simplified BSD License 2856 set forth in Section 4.c of the IETF Trust's Legal Provisions 2857 Relating to IETF Documents 2858 (http://trustee.ietf.org/license-info). 2860 This version of this YANG module is part of RFC XXXX; see 2861 the RFC itself for full legal notices."; 2863 revision 2018-01-22 { 2864 description "Initial revision."; 2865 reference 2866 "RFC XXXX: A YANG data model example augmentation for BFD echo 2867 function"; 2868 } 2870 // RFC Ed.: replace XXXX with actual RFC number and remove this 2871 // note 2873 /* 2874 * Groupings 2875 */ 2876 grouping echo-cfg-parms { 2877 description "BFD grouping for echo config parameters"; 2878 leaf desired-min-echo-tx-interval { 2879 type uint32; 2880 units microseconds; 2881 default 0; 2882 description "Desired minumum transmit interval for echo"; 2883 } 2885 leaf required-min-echo-rx-interval { 2886 type uint32; 2887 units microseconds; 2888 default 0; 2889 description "Required minimum receive interval for echo"; 2890 } 2891 } 2893 augment "/rt:routing/rt:control-plane-protocols/" 2894 + "rt:control-plane-protocol/bfd:bfd/bfd-ip-sh:ip-sh/" 2895 + "bfd-ip-sh:sessions" { 2896 description "Augmentation for BFD echo fucntion."; 2898 container echo { 2899 if-feature bfd-types:echo-mode; 2900 description "BFD echo function container"; 2902 uses echo-cfg-parms; 2903 } 2904 } 2905 } 2907 Appendix B. BFD client configuration example 2909 The following is an example of how a BFD client could use the 2910 grouping client-cfg-parms. 2912 module: example-bfd-client 2913 +--rw area* [area-id] 2914 +--rw area-id uint32 2915 +--rw bfd 2916 | +--rw enable? boolean 2917 | +--rw local-multiplier? multiplier 2918 | +--rw (interval-config-type)? 2919 | +--:(tx-rx-intervals) 2920 | | +--rw desired-min-tx-interval? uint32 2921 | | +--rw required-min-rx-interval? uint32 2922 | +--:(single-interval) 2923 | +--rw min-interval? uint32 2924 +--rw interface* [interface] 2925 +--rw interface if:interface-ref 2926 +--rw bfd 2927 +--rw enable? boolean 2928 +--rw local-multiplier? multiplier 2929 +--rw (interval-config-type)? 2930 +--:(tx-rx-intervals) 2931 | +--rw desired-min-tx-interval? uint32 2932 | +--rw required-min-rx-interval? uint32 2933 +--:(single-interval) 2934 +--rw min-interval? uint32 2936 B.1. Example YANG module for BFD client 2938 module example-bfd-client { 2939 namespace "tag:example.com,2017:example-bfd-client"; 2941 prefix "example-bfd-client"; 2943 import ietf-bfd-types { 2944 prefix "bfd-types"; 2945 } 2946 import ietf-interfaces { 2947 prefix "if"; 2948 } 2950 organization "IETF BFD Working Group"; 2952 contact 2953 "WG Web: 2954 WG List: 2956 Editors: Reshad Rahman (rrahman@cisco.com), 2957 Lianshu Zheng (vero.zheng@huawei.com), 2958 Mahesh Jethanandani (mjethanandani@gmail.com)"; 2960 description 2961 "This module contains an example of how a protocol which is a 2962 client of BFD would use BFD parameters. 2964 Copyright (c) 2017 IETF Trust and the persons 2965 identified as authors of the code. All rights reserved. 2967 Redistribution and use in source and binary forms, with or 2968 without modification, is permitted pursuant to, and subject 2969 to the license terms contained in, the Simplified BSD License 2970 set forth in Section 4.c of the IETF Trust's Legal Provisions 2971 Relating to IETF Documents 2972 (http://trustee.ietf.org/license-info). 2974 This version of this YANG module is part of RFC XXXX; see 2975 the RFC itself for full legal notices."; 2977 revision 2018-01-22 { 2978 description "Initial revision."; 2979 reference 2980 "RFC XXXX: A YANG data model example for BFD client."; 2981 } 2983 // RFC Ed.: replace XXXX with actual RFC number and remove this 2984 // note 2986 feature routing-app-bfd { 2987 description "BFD configuration under routing-app"; 2988 } 2990 list area { 2991 key "area-id"; 2993 description "Specify a routing area."; 2994 leaf area-id { 2995 type uint32; 2996 description "Area"; 2997 } 2999 container bfd { 3000 description "BFD configuration for the area."; 3001 uses bfd-types:client-cfg-parms { 3002 if-feature routing-app-bfd; 3003 } 3004 } 3006 list interface { 3007 key "interface"; 3008 description "List of interfaces"; 3009 leaf interface { 3010 type if:interface-ref; 3011 description "Interface"; 3012 } 3013 container bfd { 3014 description "BFD configuration for the interface."; 3015 uses bfd-types:client-cfg-parms { 3016 if-feature routing-app-bfd; 3017 } 3018 } 3019 } 3020 } 3022 } 3024 Appendix C. Change log 3026 RFC Editor: Remove this section upon publication as an RFC. 3028 C.1. Changes between versions -08 and -09 3030 o Mostly cosmetic changes to abide by draft-ietf-netmod-rfc6087bis. 3032 o Specified yang-version 1.1. 3034 o Added data model examples. 3036 o Some minor changes. 3038 C.2. Changes between versions -07 and -08 3040 o Timer intervals in client-cfg-parms are not mandatory anymore. 3042 o Added list of interfaces under "ip-sh" node for authentication 3043 parameters. 3045 o Renamed replay-protection to meticulous. 3047 C.3. Changes between versions -06 and -07 3049 o New ietf-bfd-types module. 3051 o Grouping for BFD clients to have BFD multiplier and interval 3052 values. 3054 o Change in ietf-bfd-mpls-te since MPLS-TE model changed. 3056 o Removed bfd- prefix from many names. 3058 C.4. Changes between versions -05 and -06 3060 o Adhere to NMDA-guidelines. 3062 o Echo function config moved to appendix as example. 3064 o Added IANA YANG modules. 3066 o Addressed various comments. 3068 C.5. Changes between versions -04 and -05 3070 o "bfd" node in augment of control-plane-protocol as per A YANG Data 3071 Model for Routing Management [RFC8022]. 3073 o Removed augment of network-instance. Replaced by schema-mount. 3075 o Added information on interaction with other YANG modules. 3077 C.6. Changes between versions -03 and -04 3079 o Updated author information. 3081 o Fixed YANG compile error in ietf-bfd-lag.yang which was due to 3082 incorrect when statement. 3084 C.7. Changes between versions -02 and -03 3086 o Fixed YANG compilation warning due to incorrect revision date in 3087 ietf-bfd-ip-sh module. 3089 C.8. Changes between versions -01 and -02 3091 o Replace routing-instance, which has been removed from A YANG Data 3092 Model for Routing Management [RFC8022], with network-instance from 3093 YANG Network Instances [I-D.ietf-rtgwg-ni-model] 3095 C.9. Changes between versions -00 and -01 3097 o Remove BFD configuration parameters from BFD clients, all BFD 3098 configuration parameters in BFD 3100 o YANG module split in multiple YANG modules (one per type of 3101 forwarding path) 3103 o For BFD over MPLS-TE we augment MPLS-TE model 3105 o For BFD authentication we now use YANG Data Model for Key Chains 3106 [RFC8177] 3108 Authors' Addresses 3110 Reshad Rahman (editor) 3111 Cisco Systems 3112 Canada 3114 Email: rrahman@cisco.com 3116 Lianshu Zheng (editor) 3117 Huawei Technologies 3118 China 3120 Email: vero.zheng@huawei.com 3122 Mahesh Jethanandani (editor) 3124 Email: mjethanandani@gmail.com 3125 Santosh Pallagatti 3126 India 3128 Email: santosh.pallagatti@gmail.com 3130 Greg Mirsky 3131 ZTE Corporation 3133 Email: gregimirsky@gmail.com