idnits 2.17.1 draft-clemm-netconf-nmda-diff-01.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** There are 2 instances of too long lines in the document, the longest one being 3 characters in excess of 72. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (October 30, 2017) is 2363 days in the past. Is this intentional? Checking references for intended status: Informational ---------------------------------------------------------------------------- No issues found here. Summary: 1 error (**), 0 flaws (~~), 1 warning (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group A. Clemm 3 Internet-Draft Y. Qu 4 Intended status: Informational J. Tantsura 5 Expires: May 3, 2018 Futurewei Technologies, Inc. 6 October 30, 2017 8 Discrepancy detection between NMDA datastores 9 draft-clemm-netconf-nmda-diff-01 11 Abstract 13 This document defines a capability that allows to report 14 discrepancies between management datastores in Netconf or Restconf 15 servers that comply with the NMDA architecture. The capability is 16 based on a set of RPCs that are defined as part of a YANG data model 17 and that are intended to be used in conjunction with Netconf and 18 Restconf. 20 Status of This Memo 22 This Internet-Draft is submitted in full conformance with the 23 provisions of BCP 78 and BCP 79. 25 Internet-Drafts are working documents of the Internet Engineering 26 Task Force (IETF). Note that other groups may also distribute 27 working documents as Internet-Drafts. The list of current Internet- 28 Drafts is at https://datatracker.ietf.org/drafts/current/. 30 Internet-Drafts are draft documents valid for a maximum of six months 31 and may be updated, replaced, or obsoleted by other documents at any 32 time. It is inappropriate to use Internet-Drafts as reference 33 material or to cite them other than as "work in progress." 35 This Internet-Draft will expire on May 3, 2018. 37 Copyright Notice 39 Copyright (c) 2017 IETF Trust and the persons identified as the 40 document authors. All rights reserved. 42 This document is subject to BCP 78 and the IETF Trust's Legal 43 Provisions Relating to IETF Documents 44 (https://trustee.ietf.org/license-info) in effect on the date of 45 publication of this document. Please review these documents 46 carefully, as they describe your rights and restrictions with respect 47 to this document. Code Components extracted from this document must 48 include Simplified BSD License text as described in Section 4.e of 49 the Trust Legal Provisions and are provided without warranty as 50 described in the Simplified BSD License. 52 Table of Contents 54 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 55 2. Key Words . . . . . . . . . . . . . . . . . . . . . . . . . . 3 56 3. Definitions and Acronyms . . . . . . . . . . . . . . . . . . 3 57 4. Data Model Overview . . . . . . . . . . . . . . . . . . . . . 4 58 5. YANG Data Model . . . . . . . . . . . . . . . . . . . . . . . 5 59 6. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 8 60 6.1. Updates to the IETF XML Registry . . . . . . . . . . . . 8 61 6.2. Updates to the YANG Module Names Registry . . . . . . . . 8 62 7. Security Considerations . . . . . . . . . . . . . . . . . . . 8 63 8. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 8 64 9. Normative References . . . . . . . . . . . . . . . . . . . . 9 65 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 10 67 1. Introduction 69 The revised Network Management Datastore Architecture (NMDA) [NMDA] 70 introduces a set of new datastores that each hold YANG-defined data 71 [RFC7950] and represent a different "viewpoint" on the data that is 72 maintained by a server. New YANG datastores that are introduced 73 include , which contains validated configuration data that 74 a client application intends to be in effect, and , 75 which contains at least conceptually operational state data (such as 76 statistics) as well as configuration data that is actually in effect. 78 NMDA introduces in effect a concept of "lifecycle" for management 79 data, allowing to clearly distinguish between data that is part of a 80 configuration that was supplied by a user, configuration data that 81 has actually been successfully applied and that is part of the 82 operational state, and overall operational state that includes both 83 applied configuration data as well as status and statistics. 85 As a result, data from the same management model can be reflected in 86 multiple datastores. Clients need to specify the target datastore to 87 be specific about which viewpoint of the data they want to access. 88 This way, an application can differentiate whether they are (for 89 example) interested in the configuration that has been applied and is 90 actually in effect, or in the configuration that was supplied by a 91 client and that is supposed to be in effect. 93 Due to the fact that data can propagate from one datastore to 94 another, it is possibly for discrepancies to occur. Some of this is 95 entirely expected, as there may be a time lag between when a 96 configuration is given to the device and reflected in , 97 until when it actually takes effect and is reflected in 98 . However, there may be cases when a configuration item 99 that was to be applied may not actually take effect at all or needs 100 an unusually long time to do so. This can be the case due to certain 101 conditions not being met, resource dependencies not being resolved, 102 or even implementation errors in corner conditions. 104 When configuration that is in effect is different from configuration 105 that was applied, many issues can result. It becomes more difficult 106 to operate the network properly due to limited visibility of actual 107 status which makes it more difficult to analyze and understand what 108 is going on in the network. Services may be negatively affected (for 109 example, breaking a service instance resulting in service is not 110 properly delivered to a customer) and network resources be 111 misallocated. 113 Applications can potentially analyze any discrepancies between two 114 datastores by retrieving the contents from both datastores and 115 comparing them. However, in many cases this will be at the same time 116 costly and extremely wasteful. It will also not be an effective 117 approach to discover changes that are only "fleeting", or for that 118 matter to distinguish between changes that are only fleeting from 119 ones that are not and that may represent a real operational issue and 120 inconsistency within the device. 122 This document introduces a YANG data model which defines RPCs, 123 intended to be used in conjunction with NETCONF [RFC6241] or RESTCONF 124 [RFC8040], that allow a client to request a server to compare two 125 NMDA datastores and report any discepancies. It also features a 126 dampening option that allows to exclude discrepancies that are only 127 fleeting from the report. 129 2. Key Words 131 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 132 "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and 133 "OPTIONAL" in this document are to be interpreted as described in BCP 134 14 [RFC2119] [RFC8174] when, and only when, they appear in all 135 capitals, as shown here. 137 3. Definitions and Acronyms 139 NMDA: Network Management Datastore Architecture 141 RPC: Remote Procedure Call 143 4. Data Model Overview 145 At the core of the solution is a new management operation, , 146 that allows to compare two datastores for the same data. The 147 operation checks whether there are any discrepancies in values or in 148 objects that are contained in either datastore, and returns any 149 discrepancies as output. The output is returned in the format 150 specified in YANG-Patch [RFC8072]. 152 The YANG data model defines the operation as a new RPC. 153 The operation takes the following input parameters: 155 o source: The source identifies the datastore that will serve as 156 reference for the comparison, for example . 158 o target: The target identifies the datastore to compare against the 159 source. 161 o filter-spec: This is a choice between different filter constructs 162 to identify the portions of the datastore to be retrieved. It 163 acts as a node selector that specifies which data nodes are within 164 the scope of the comparison and which nodes are outside the scope. 165 This allows a comparison operation to be applied only to a 166 specific portion of the datastore that is of interest, such as a 167 particular subtree. (The filter dow not contain expressions that 168 would match values data nodes, as this is not required by most use 169 cases and would complicate the scheme, from implementation to 170 dealing with race conditions.) 172 o dampening: Identifies the minimum time period for which a 173 discrepancy must persist for it to be reported. The reporting of 174 the output MAY correspondingly delayed by the dampening period. 175 Implementations MAY thus run a comparison when the RPC is first 176 invoked, then wait until after the dampening period to check 177 whether any differences still persist. This parameter is 178 conditional of a dampening being supported as a feature. 180 The operation provides the following output parameter: 182 o differences: This parameter contains the list of differences, 183 encoded per RFC8072, i.e. specifying which patches would need to 184 be applied to the source to produce the target. 186 As part of the differences, it will be useful to include "origin" 187 metadata where applicable, specifically when the target datastore is 188 . This can help explain the cause of a discrepancy, for 189 example when a data item is part of but the origin in 190 is reported as "system". How to best report "origin" 191 metadata is an item for further study, specifically whether it should 192 be automatically returned per default or whether its reporting should 193 be controlled using another RPC parameter. 195 The data model is defined in the ietf-nmda-compare YANG module. Its 196 structure is shown in the following figure. The notation syntax 197 follows [I-D.draft-ietf-netmod-yang-tree-diagrams]. 199 module: ietf-nmda-compare 201 rpcs: 202 +---x compare 203 +---w input 204 | +---w source identityref 205 | +---w target identityref 206 | +---w (filter-spec)? 207 | | +--:(subtree-filter) 208 | | | +---w subtree-filter? 209 | | +--:(xpath-filter) 210 | | +---w xpath-filter? yang:xpath1.0 {nc:xpath}? 211 | +---w dampening? yang:timeticks {cmp-dampening}? 212 +--ro output 213 +--ro differences 215 Structure of ietf-nmda-compare 217 5. YANG Data Model 219 file "ietf-nmda-compare@2017-10-30.yang" 220 module ietf-nmda-compare { 222 yang-version 1.1; 223 namespace "urn:ietf:params:xml:ns:yang:ietf-nmda-compare"; 225 prefix cp; 227 import ietf-yang-types { 228 prefix yang; 229 } 230 import ietf-datastores { 231 prefix ds; 232 } 233 import ietf-yang-patch { 234 prefix ypatch; 235 } 236 import ietf-netconf { 237 prefix nc; 239 } 241 organization "IETF"; 242 contact 243 "WG Web: 244 WG List: 246 Author: Alexander Clemm 247 249 Author: Yingzhen Qu 250 252 Author: Jeff Tantsura 253 "; 255 description 256 "The YANG data model defines a new operation, , that 257 can be used to compare NMDA datastores."; 259 revision 2017-10-30 { 260 description 261 "Initial revision"; 262 reference 263 "RFC XXXX: Discrepancy detection between NMDA datastores"; 264 } 266 feature cmp-dampening { 267 description 268 "This feature indicates that the ability to only report 269 differences that pertain for a certain amount of time, 270 as indicated through a dampening period, is supported."; 271 } 273 /* RPC */ 274 rpc compare { 275 description 276 "NMDA compare operation."; 277 input { 278 leaf source { 279 type identityref { 280 base ds:datastore; 281 } 282 mandatory true; 283 description 284 "The source datastore to be compared."; 285 } 286 leaf target { 287 type identityref { 288 base ds:datastore; 289 } 290 mandatory true; 291 description 292 "The target datastore to be compared."; 293 } 294 choice filter-spec { 295 description 296 "Identifies the portions of the datastores to be 297 compared."; 299 anydata subtree-filter { 300 description 301 "This parameter identifies the portions of the 302 target datastore to retrieve."; 303 reference "RFC 6241, Section 6."; 304 } 305 leaf xpath-filter { 306 if-feature nc:xpath; 307 type yang:xpath1.0; 308 description 309 "This parameter contains an XPath expression 310 identifying the portions of the target 311 datastore to retrieve."; 312 } 313 } 314 leaf dampening { 315 if-feature cmp-dampening; 316 type yang:timeticks; 317 default "0"; 318 description 319 "The dampening period, in hundredths of a second, for the 320 reporting of differences. Only differences that pertain 321 for at least the dampening time are reported. Reporting 322 of differences may be deferred by the dampening time. 323 A value of 0 or omission of the leaf indicates no 324 dampening."; 325 } 326 } 327 output { 328 container differences { 329 uses ypatch:yang-patch; 330 description 331 "The list of differences, encoded per RFC8072."; 332 } 333 } 334 } 336 } 337 339 6. IANA Considerations 341 6.1. Updates to the IETF XML Registry 343 This document registers one URI in the IETF XML registry [RFC3688]. 344 Following the format in [RFC3688], the following registration is 345 requested: 347 URI: urn:ietf:params:xml:ns:yang:ietf-nmda-compare 349 Registrant Contact: The IESG. 351 XML: N/A, the requested URI is an XML namespace. 353 6.2. Updates to the YANG Module Names Registry 355 This document registers a YANG module in the YANG Module Names 356 registry [RFC6020]. Following the format in [RFC6020], the following 357 registration is requested: 359 name: ietf-nmda-compare 361 namespace: urn:ietf:params:xml:ns:yang:ietf-nmda-compare 363 prefix: cp 365 reference: RFC XXXX 367 7. Security Considerations 369 Comparing discrepancies between datastores requires a certain amount 370 of processing resources at the server. An attacker could attempt to 371 attack a server by making a high volume of discrepancy detection 372 requests. Server implementations can guard against such scenarios in 373 several ways. For one, they can implement NACM in order to require 374 proper authorization for requests to be made. Second, server 375 implementations can limit the number of requests that they serve in 376 any one time interval, potentially rejecting requests made at a 377 higher frequency than the implementation can reasonably sustain. 379 8. Acknowledgments 381 We thank Rob Wilton for valuable feedback and suggestions on an 382 earlier revision of this document. 384 9. Normative References 386 [I-D.draft-ietf-netmod-yang-tree-diagrams] 387 Bjorklund, M. and L. Berger, "YANG Tree Diagrams", I-D 388 draft-ietf-netmod-yang-tree-diagrams, June 2017. 390 [NMDA] Bjorklund, M., Schoenwaelder, J., Shafer, P., Watsen, K., 391 and R. Wilton, "Network Management Datastore 392 Architecture", October 2017, 393 . 396 [notif-sub] 397 Voit, E., Clemm, A., Gonzalez Prieto, A., Nilsen-Nygaard, 398 E., and A. Tripathy, "Custom subscription to event 399 notifications", October 2017, 400 . 403 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 404 Requirement Levels", BCP 14, RFC 2119, 405 DOI 10.17487/RFC2119, March 1997, 406 . 408 [RFC3688] Mealling, M., "The IETF XML Registry", BCP 81, RFC 3688, 409 DOI 10.17487/RFC3688, January 2004, 410 . 412 [RFC6020] Bjorklund, M., Ed., "YANG - A Data Modeling Language for 413 the Network Configuration Protocol (NETCONF)", RFC 6020, 414 DOI 10.17487/RFC6020, October 2010, 415 . 417 [RFC6241] Enns, R., Ed., Bjorklund, M., Ed., Schoenwaelder, J., Ed., 418 and A. Bierman, Ed., "Network Configuration Protocol 419 (NETCONF)", RFC 6241, DOI 10.17487/RFC6241, June 2011, 420 . 422 [RFC7950] Bjorklund, M., Ed., "The YANG 1.1 Data Modeling Language", 423 RFC 7950, DOI 10.17487/RFC7950, August 2016, 424 . 426 [RFC8040] Bierman, A., Bjorklund, M., and K. Watsen, "RESTCONF 427 Protocol", RFC 8040, DOI 10.17487/RFC8040, January 2017, 428 . 430 [RFC8072] Bierman, A., Bjorklund, M., and K. Watsen, "YANG Patch 431 Media Type", RFC 8072, DOI 10.17487/RFC8072, February 432 2017, . 434 [RFC8174] Leiba, B., "Ambiguity of Uppercase vs Lowercase in RFC 435 2119 Key Words", BCP 14, RFC 8174, DOI 10.17487/RFC8174, 436 May 2017, . 438 [yang-push] 439 Clemm, A., Voit, E., Gonzalez Prieto, A., Tripathy, A., 440 Nilsen-Nygaard, E., Bierman, A., and B. Lengyel, 441 "Subscribing to YANG datastore push updates", October 442 2017, . 445 Authors' Addresses 447 Alexander Clemm 448 Futurewei Technologies, Inc. 449 2330 Central Expressway 450 Santa Clara, CA 95050 451 USA 453 Email: ludwig@clemm.org 455 Yingzhen Qu 456 Futurewei Technologies, Inc. 457 2330 Central Expressway 458 Santa Clara, CA 95050 459 USA 461 Email: yingzhen.qu@huawei.com 463 Jeff Tantsura 464 Futurewei Technologies, Inc. 465 2330 Central Expressway 466 Santa Clara, CA 95050 467 USA 469 Email: jefftant.ietf@gmail.com