idnits 2.17.1 draft-dt-roll-rpl-01.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- ** The document seems to lack a License Notice according IETF Trust Provisions of 28 Dec 2009, Section 6.b.ii or Provisions of 12 Sep 2009 Section 6.b -- however, there's a paragraph with a matching beginning. Boilerplate error? (You're using the IETF Trust Provisions' Section 6.b License Notice from 12 Feb 2009 rather than one of the newer Notices. See https://trustee.ietf.org/license-info/.) 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 : ---------------------------------------------------------------------------- ** The abstract seems to contain references ([I-D.ietf-roll-home-routing-reqs], [I-D.ietf-roll-indus-routing-reqs], [I-D.ietf-roll-building-routing-reqs], [RFC5548]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (July 12, 2009) is 5401 days in the past. Is this intentional? Checking references for intended status: Proposed Standard ---------------------------------------------------------------------------- (See RFCs 3967 and 4897 for information about using normative references to lower-maturity documents in RFCs) -- Looks like a reference, but probably isn't: '1' on line 1012 -- Looks like a reference, but probably isn't: '2' on line 1012 -- Looks like a reference, but probably isn't: '3' on line 1012 == Unused Reference: 'I-D.tavakoli-hydro' is defined on line 2667, but no explicit reference was found in the text == Unused Reference: 'I-D.thubert-roll-fundamentals' is defined on line 2673, but no explicit reference was found in the text == Unused Reference: 'I-D.tsao-roll-security-framework' is defined on line 2679, but no explicit reference was found in the text == Outdated reference: A later version (-11) exists of draft-ietf-bfd-base-09 == Outdated reference: A later version (-15) exists of draft-ietf-manet-nhdp-10 == Outdated reference: A later version (-09) exists of draft-ietf-roll-building-routing-reqs-05 == Outdated reference: A later version (-11) exists of draft-ietf-roll-home-routing-reqs-06 == Outdated reference: A later version (-19) exists of draft-ietf-roll-routing-metrics-00 == Outdated reference: A later version (-13) exists of draft-ietf-roll-terminology-01 == Outdated reference: A later version (-02) exists of draft-tsao-roll-security-framework-00 Summary: 2 errors (**), 0 flaws (~~), 11 warnings (==), 4 comments (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Networking Working Group T. Winter, Ed. 3 Internet-Draft 4 Intended status: Standards Track ROLL Design Team 5 Expires: January 13, 2010 IETF ROLL WG 6 July 12, 2009 8 RPL: Routing Protocol for Low Power and Lossy Networks 9 draft-dt-roll-rpl-01 11 Status of this Memo 13 This Internet-Draft is submitted to IETF in full conformance with the 14 provisions of BCP 78 and BCP 79. 16 Internet-Drafts are working documents of the Internet Engineering 17 Task Force (IETF), its areas, and its working groups. Note that 18 other groups may also distribute working documents as Internet- 19 Drafts. 21 Internet-Drafts are draft documents valid for a maximum of six months 22 and may be updated, replaced, or obsoleted by other documents at any 23 time. It is inappropriate to use Internet-Drafts as reference 24 material or to cite them other than as "work in progress." 26 The list of current Internet-Drafts can be accessed at 27 http://www.ietf.org/ietf/1id-abstracts.txt. 29 The list of Internet-Draft Shadow Directories can be accessed at 30 http://www.ietf.org/shadow.html. 32 This Internet-Draft will expire on January 13, 2010. 34 Copyright Notice 36 Copyright (c) 2009 IETF Trust and the persons identified as the 37 document authors. All rights reserved. 39 This document is subject to BCP 78 and the IETF Trust's Legal 40 Provisions Relating to IETF Documents in effect on the date of 41 publication of this document (http://trustee.ietf.org/license-info). 42 Please review these documents carefully, as they describe your rights 43 and restrictions with respect to this document. 45 Abstract 47 This document specifies the Routing Protocol for Low Power and Lossy 48 Networks (RPL), in accordance with the requirements described in 50 [I-D.ietf-roll-building-routing-reqs], 51 [I-D.ietf-roll-home-routing-reqs], 52 [I-D.ietf-roll-indus-routing-reqs], and [RFC5548]. 54 Requirements Language 56 The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", 57 "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this 58 document are to be interpreted as described in RFC 2119 [RFC2119]. 60 Table of Contents 62 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 4 63 1.1. Design Principles . . . . . . . . . . . . . . . . . . . . 4 64 2. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 4 65 3. Protocol Model . . . . . . . . . . . . . . . . . . . . . . . . 6 66 3.1. Problem . . . . . . . . . . . . . . . . . . . . . . . . . 6 67 3.2. Protocol Properties Overview . . . . . . . . . . . . . . . 7 68 3.2.1. IPv6 Architecture . . . . . . . . . . . . . . . . . . 7 69 3.2.2. Path Properties for LLN Traffic Flows . . . . . . . . 7 70 3.2.3. Constraint Based Routing . . . . . . . . . . . . . . . 7 71 3.2.4. Autonomous Operation . . . . . . . . . . . . . . . . . 8 72 3.3. Protocol Operation . . . . . . . . . . . . . . . . . . . . 8 73 3.3.1. DAG Construction . . . . . . . . . . . . . . . . . . . 9 74 3.3.2. Source Routing . . . . . . . . . . . . . . . . . . . . 17 75 3.3.3. Destination Advertisement . . . . . . . . . . . . . . 17 76 3.4. Other Considerations . . . . . . . . . . . . . . . . . . . 19 77 3.4.1. DAG Depth and Loop Avoidance . . . . . . . . . . . . . 19 78 3.4.2. DAG Parent Selection, Stability, and Greediness . . . 21 79 3.4.3. Merging DAGs . . . . . . . . . . . . . . . . . . . . . 23 80 3.4.4. Local and Temporary Routing Decision . . . . . . . . . 25 81 3.4.5. Scalability . . . . . . . . . . . . . . . . . . . . . 26 82 3.4.6. Maintenance of Routing Adjacency . . . . . . . . . . . 26 83 4. Constraint Based Routing in LLNs . . . . . . . . . . . . . . . 27 84 4.1. Routing Metrics . . . . . . . . . . . . . . . . . . . . . 27 85 4.2. Routing Constraints . . . . . . . . . . . . . . . . . . . 28 86 4.3. Constraint Based Routing . . . . . . . . . . . . . . . . . 28 87 5. Specification of Core Protocol . . . . . . . . . . . . . . . . 29 88 5.1. DAG Information Option . . . . . . . . . . . . . . . . . . 29 89 5.1.1. DIO base option . . . . . . . . . . . . . . . . . . . 29 90 5.2. Neighbor Discovery . . . . . . . . . . . . . . . . . . . . 35 91 5.2.1. RA-DIO Reception . . . . . . . . . . . . . . . . . . . 35 92 5.2.2. RA-DIO Transmission . . . . . . . . . . . . . . . . . 37 93 5.2.3. Trickle Timer for RA Transmission . . . . . . . . . . 38 94 5.3. DAG Discovery . . . . . . . . . . . . . . . . . . . . . . 39 95 5.3.1. DAG Selection . . . . . . . . . . . . . . . . . . . . 41 96 5.3.2. Administrative depth . . . . . . . . . . . . . . . . . 42 97 5.3.3. DRL entries states and stability . . . . . . . . . . . 42 98 5.4. Establishing Routing State Outward Along the DAG . . . . . 45 99 5.4.1. Destination Advertisement Message Formats . . . . . . 46 100 5.4.2. Destination Advertisement Operation . . . . . . . . . 48 101 5.5. Maintenance of Routing Adjacency . . . . . . . . . . . . . 54 102 5.6. Expectations of Link Layer Behavior . . . . . . . . . . . 55 103 6. Protocol Extensions . . . . . . . . . . . . . . . . . . . . . 55 104 7. Manageability Considerations . . . . . . . . . . . . . . . . . 55 105 8. Security Considerations . . . . . . . . . . . . . . . . . . . 55 106 9. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 55 107 9.1. DAG Information Option . . . . . . . . . . . . . . . . . . 55 108 9.2. Destination Advertisement Option . . . . . . . . . . . . . 55 109 10. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 55 110 11. Contributors . . . . . . . . . . . . . . . . . . . . . . . . . 56 111 12. References . . . . . . . . . . . . . . . . . . . . . . . . . . 57 112 12.1. Normative References . . . . . . . . . . . . . . . . . . . 57 113 12.2. Informative References . . . . . . . . . . . . . . . . . . 57 114 Appendix A. Deferred Requirements . . . . . . . . . . . . . . . . 59 115 Appendix B. Examples . . . . . . . . . . . . . . . . . . . . . . 60 116 B.1. Moving Down a DAG . . . . . . . . . . . . . . . . . . . . 61 117 B.2. Link Removed . . . . . . . . . . . . . . . . . . . . . . . 62 118 B.3. Link Added . . . . . . . . . . . . . . . . . . . . . . . . 62 119 B.4. Node Removed . . . . . . . . . . . . . . . . . . . . . . . 63 120 B.5. New LBR Added . . . . . . . . . . . . . . . . . . . . . . 63 121 B.6. Destination Advertisement . . . . . . . . . . . . . . . . 64 122 Appendix C. Additional Examples . . . . . . . . . . . . . . . . . 65 123 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . . 69 125 1. Introduction 127 The defining characteristics of Low Power and Lossy Networks (LLNs) 128 offer unique challenges to a routing solution. The IETF ROLL Working 129 Group has defined application-specific routing requirements for a Low 130 Power and Lossy Network (LLN) routing protocol 131 [I-D.ietf-roll-building-routing-reqs] 132 [I-D.ietf-roll-home-routing-reqs] [I-D.ietf-roll-indus-routing-reqs] 133 [RFC5548]. RPL is a new routing protocol designed to meet these 134 requirements. 136 1.1. Design Principles 138 RPL was designed with the objective to meet the requirements spelled 139 out in [I-D.ietf-roll-building-routing-reqs], 140 [I-D.ietf-roll-home-routing-reqs], 141 [I-D.ietf-roll-indus-routing-reqs], and [RFC5548]. Because those 142 requirements are heterogeneous and sometimes incompatible in nature, 143 the approach is first taken to design a protocol capable of 144 supporting a core set of functionalities corresponding to the 145 intersection of the requirements. (Note: it is intended that as this 146 design evolves optional features may be added to address some 147 application specific requirements). All "MUST" application 148 requirements that cannot be satisfied by RPL will be specifically 149 listed in the Appendix A, accompanied by a justification. 151 The core set of functionalities is to be capable of operating in the 152 most severely constrained environments, with minimal requirements for 153 memory, energy, processing, communication, and other consumption of 154 limited resources from nodes. Trade-offs inherent in the 155 provisioning of protocol features will be exposed to the implementer 156 in the form of configurable parameters, such that the implementer can 157 further tweak and optimize the operation of RPL as appropriate to a 158 specific application and implementation. Finally, RPL is designed to 159 consult implementation specific policies to determine, for example, 160 the evaluation of routing metrics. 162 A set of companion documents to this specification will provide 163 further guidance in the form of applicability statements specifying a 164 set of operating points appropriate to the Building Automation, Home 165 Automation, Industrial, and Urban application scenarios. 167 2. Terminology 169 The terminology used in this document is consistent with and 170 incorporates that described in `Terminology in Low power And Lossy 171 Networks' [I-D.ietf-roll-terminology]. The terminology is extended 172 in this document as follows: 174 Autonomous: Refers to the ability of a routing protocol to 175 independently function without requiring any external influence 176 or guidance. Includes self-organization capabilities. 178 DAG: Directed Acyclic Graph- A directed graph having the property 179 that all edges are oriented in such a way that no cycles exist. 180 In the RPL context, all edges are contained in paths oriented 181 toward and terminating at a root node (a DAG root, or sink- 182 typically a LBR). 184 DAGID: DAG Identifier- A globally unique identifier for a DAG. All 185 nodes who are members of a DAG have knowledge of the DAGID. 186 This knowledge is used to identify peer nodes within the DAG in 187 order to coordinate DAG Maintenance while avoiding loops. 189 DAG Parent: A parent of a node within a DAG is one of the immediate 190 successors of the node on a path towards the DAG root. For 191 each DAGID that a node is a member of, the node will maintain a 192 set containing one or more DAG Parents. If a node is a member 193 of multiple DAGs then it must conceptually maintain a set of 194 DAG Parents for each DAGID. 196 DAG Sibling: A sibling of a node within a DAG is defined to be any 197 neighboring node which is located at the same depth, or rank, 198 within a DAG. Note that siblings defined in this manner do not 199 necessarily share a common parent. For each DAGID that a node 200 is a member of, the node will maintain a set of DAG Siblings. 201 If a node is a member of multiple DAGs then it must 202 conceptually maintain a set of DAG Siblings for each DAGID. 204 DAG Root: A DAG root is a sink within the DAG graph. All paths in 205 the DAG terminate at a DAG root, and all DAG edges contained in 206 the paths terminating at a DAG root are oriented toward the DAG 207 root. There must be at least one DAG Root per DAGID, and in 208 some cases there may be more than one. In many use cases, 209 source-sink represents a dominant traffic flow, where the sink 210 is a DAG root. Maintaining default routing towards DAG roots 211 is therefore a prominent functionality for RPL. 213 Grounded: A DAG is grounded if it contains a DAG Root offering a 214 default route. 216 Floating: A DAG is floating if it contains a DAG root that does not 217 offer a default route. 219 Inward: In the context of RPL, inward refers to the direction from 220 leaf nodes towards DAG roots, following the orientation of the 221 edges within the DAG. 223 Outward: In the context of RPL, outward refers to the direction from 224 DAG roots towards leaf nodes, going against the orientation of 225 the edges within the DAG. 227 P2P: Point-to-point. This refers to traffic exchanged between two 228 nodes. 230 P2MP: Point-to-Multipoint. This refers to traffic between one node 231 and a set of nodes. This is similar to the P2MP concept in 232 Multicast or MPLS Traffic Engineering ([RFC4461] and 233 [RFC4875]). 235 MP2P: Multipoint-to-Point; used to describe a particular traffic 236 pattern. A common RPL use case involves MP2P flows collecting 237 information from many nodes in the DAG, flowing inwards towards 238 DAG roots. Note that a DAG root may not be the ultimate 239 destination of the information, but it is a common transit 240 node. 242 OCP: Objective Code Point. In RPL, the Objective Code Point (OCP) 243 indicates which routing metrics, optimization objectives, and 244 related functions are in use in a DAG. It is recommended that 245 a companion document define instances of the Objective Code 246 Point and request the creation of a registry to manage them. 248 Note that in this document, the terms `node' and `LLN router' are 249 used interchangeably. 251 3. Protocol Model 253 The aim of this section is to describe RPL in the spirit of 254 [RFC4101]. An architectural protocol overview (the big picture of 255 the protocol) is provided in this section. Protocol details can be 256 found in further sections. 258 3.1. Problem 260 Some well-defined LLN application-specific scenarios are Building 261 Automation, Home Automation, Industrial, and Urban; for which the 262 unique routing requirements have been detailed respectively in 263 [I-D.ietf-roll-building-routing-reqs], 264 [I-D.ietf-roll-home-routing-reqs], 265 [I-D.ietf-roll-indus-routing-reqs], and [RFC5548]. Within these 266 application-specific scenarios there are some common elements 267 required of routing. RPL intends to address the requirements of 268 these application-specific scenarios, and it is further intended to 269 be flexible enough to extend to other application scenarios. 271 3.2. Protocol Properties Overview 273 RPL demonstrates the following properties, consistent with the 274 requirements specified by the requirements documents. 276 3.2.1. IPv6 Architecture 278 RPL is strictly compliant with layered IPv6 architecture. 280 Further, RPL is designed with consideration to the practical support 281 and implementation of IPv6 architecture on devices which may operate 282 under severe resource constraints, including but not limited to 283 memory, processing power, energy, and communication. The RPL design 284 does not presume high quality reliable links, and should be able to 285 operate over lossy links (usually low bandwidth with low packet 286 delivery success rate). 288 3.2.2. Path Properties for LLN Traffic Flows 290 Multipoint-to-point (MP2P) and Point-to-multipoint (P2MP) traffic 291 flows from nodes within the LLN from and to egress points are very 292 common in LLNs. Low power and lossy network Border Router (LBR) 293 nodes may typically be at the root of such flows, although such flows 294 are not exclusively rooted at LBRs as determined on an application- 295 specific basis. 297 As required by the aforementioned routing requirements documents, RPL 298 supports the installation of multiple paths. The use of multiple 299 paths include sending duplicated traffic along diverse paths, as well 300 as to support advanced features such as Class of Service (CoS) based 301 routing, or simple load balancing among a set of paths (which could 302 be useful for the LLN to spread traffic load and avoid fast energy 303 depletion on some nodes). 305 3.2.3. Constraint Based Routing 307 The RPL design supports constraint based routing, based on a set of 308 routing metrics. The routing metrics supported by RPL are specified 309 in a companion document to this specification, 310 [I-D.ietf-roll-routing-metrics]. RPL signals the metrics and related 311 objective functions in use in a particular implementation by means of 312 an Objective Code Point (OCP). 314 RPL supports the computation and installation of different paths in 315 support of and optimized for a set of application and implementation 316 specific constraints, as guided by an OCP. Traffic may subsequently 317 be directed along the appropriate constrained path based on traffic 318 marking within the IPv6 header. For more details on the approach 319 towards constraint-based routing, see Section 4. 321 3.2.4. Autonomous Operation 323 Nodes running RPL are able to independently and autonomously discover 324 a network topology and compute and install routes, without requiring 325 further administrative interaction. 327 3.3. Protocol Operation 329 LLN nodes running RPL will construct Directed Acyclic Graphs (DAGs) 330 rooted at designated nodes that generally provide default routes. 331 The DAG is sufficient to support inward MP2P traffic flows, flowing 332 inward along the LLN towards a sink (DAG Root), which is one of the 333 dominant traffic flows described in the requirements documents 334 ([I-D.ietf-roll-building-routing-reqs], 335 [I-D.ietf-roll-home-routing-reqs], 336 [I-D.ietf-roll-indus-routing-reqs], and [RFC5548]). 338 By utilizing a DAG for dominant MP2P flows, RPL allows each node to 339 select and maintain potentially multiple successors capable of 340 forwarding traffic inwards towards the root. The DAG does not 341 present as many single points of failure as a tree, and in addition 342 can offer a node a set of pre-computed successors in support of, e.g. 343 local route repair in case of a temporary failure, load balancing, or 344 short term fluctuations in link characteristics. 346 A DAG also serves to restrict the routing problem on the nodes when 347 it is used as a reference topology. This allows nodes to determine 348 their positions in a DAG relative to each other and provides a means 349 to coordinate route repair in a way that endeavors to avoid loops. 350 These mechanisms will be described in more detail later in this 351 specification. 353 As DAGs are organized, RPL will use a Destination Advertisement 354 mechanism to build up routing state in support of outward P2MP 355 traffic flows. This mechanism, using the DAG as a reference, 356 `paints' the underlying LLN graph, guided along the DAG, such that 357 the routes toward destination prefixes in the outward direction may 358 be set up. As the DAG undergoes modification during DAG maintenance, 359 the Destination Advertisement mechanism can be triggered to update 360 the outward routing state. 362 Arbitrary P2P traffic MAY flow inward along the DAG until a common 363 parent is reached who has stored routing state and is capable of 364 directing the traffic outward along the correct outward path. In the 365 present specification RPL does not specify nor preclude any 366 additional mechanisms that may be capable to compute and install more 367 optimal routes into LLN nodes in support of arbitrary P2P traffic. 368 (Note that in some application scenarios it may be important to 369 support arbitrary P2P traffic along more optimal paths `across' the 370 DAG). This functionality is to be investigated further in a future 371 revision. 373 This section further describes the high level operation of RPL. 375 3.3.1. DAG Construction 377 3.3.1.1. Overview of a Typical Case 379 RPL constructs one or more base routing topologies, in the form of 380 DAGs, over gradients defined by optimizing cost metrics along paths 381 rooted at designated nodes. 383 DAGs may be grounded, in which case the DAG Root is offering a 384 default route. A typical goal for a node participating in DAG 385 Construction will be to find and join a grounded DAG. 387 In the context of a particular LLN application one or more nodes will 388 be capable of offering a default route and thus be provisioned to act 389 as DAG roots. These nodes will begin the process of constructing a 390 grounded DAG by occasionally emitting Router Advertisements 391 containing the necessary information for neighboring nodes to 392 evaluate the DAG Root as a potential DAG parent. This information 393 will include a DAGID and an Objective Code Point (OCP). The OCP 394 provides information as to which metrics and optimization goals are 395 being employed across the DAG. Note that a single DAG Root may 396 conceptually root different DAGs with different OCPs as required to 397 support different sets of routing constraints. Note that if multiple 398 DAG roots are rooting the same DAG, i.e. presenting the same DAGID, 399 then they must have some means of coordinating with each other when 400 emitting Router Advertisements. This is described further below. 402 Nodes who hear Router Advertisements, advertising a specific DAGID 403 and OCP, will take into consideration several criteria when 404 processing the extracted DAG information. A node may seek a DAG 405 advertising a specific OCP, reflecting the implementation specific 406 routing constraints understood by the node. In particular, a node 407 will be seeking to find a least cost path satisfying some objective 408 function as indicated by the OCP according to some routing metrics 409 defined in [I-D.ietf-roll-routing-metrics]. For example, the least 410 cost path may be determined in part by minimizing energy along a 411 path, or latency, or avoiding the use of battery powered nodes. 412 Based on the evaluation of such criteria, a node may determine if the 413 node who emitted the Router Advertisement should be considered as a 414 potential DAG parent. If so, then the node may add the advertising 415 node to its set of DAG parents for the advertised DAGID, and can be 416 considered to have joined the DAG designated by DAGID. 418 When a node adds the first DAG parent to the set of DAG parents for a 419 particular DAGID, the node is said to have joined, or attached to, 420 the DAG designated by DAGID. Adding additional DAG parents beyond 421 the first simply increases path diversity inwards toward the DAG 422 root. When a node removes the last DAG Parent from the set of DAG 423 parents for a particular DAGID, the node is said to have left, or 424 detached from, the DAG designated by DAGID. RPL will coordinate the 425 joining, leaving, and movement of nodes within a DAGID in such a way 426 so as to avoid the formation of loops, as described further below. 428 As nodes join the DAG they are able advertise the fact by beginning 429 to multicast the DAG information in Router Advertisements. In this 430 way, nodes are able to join the DAG at ever-increasing depths outward 431 from the DAG root. As nodes continue to receive DAG multicasts they 432 may continue to expand their set of DAG parents, while employing loop 433 avoidance strategies as describe below, in order to build path 434 diversity inwards toward the DAG root. 436 Using the information conveyed in the metrics of its most preferred 437 DAG parent, its own metrics, and the conventions and functions 438 indicated by the OCP, a node is able to compute a depth value within 439 the DAG which it will use to coordinate its DAG maintenance. 441 In addition to identifying DAG parents, a node also may hear the 442 Router Advertisements of other neighboring nodes at the same depth 443 within the DAG. In this way a node can discover DAG Siblings. 445 A node may order its set of DAG parents according to some 446 implementation specific preference. To this list the node may also 447 append a similarly ordered set of DAG siblings. By forwarding 448 traffic intended for the default destination towards the DAG parents, 449 the node is able to support the main Multipoint-to-point (MP2P) 450 traffic flows required by a typical LLN application. By using the 451 ordered set of DAG parents and DAG siblings the node is able to take 452 advantage of path diversity. For example, preferring to forward 453 traffic towards parents guarantees to get the traffic inwards, closer 454 to the DAG root, by definition, regardless of which parent is 455 selected. In this example, if forwarding towards parents is not 456 possible, perhaps due to a transient phenomena, then a node may then 457 choose to forward traffic towards siblings, moving across the DAG at 458 the same level (neither inwards or outwards). When receiving traffic 459 forwarded from a sibling, the traffic should not be forwarded back to 460 the same sibling in order to avoid a 2-node loop. In a further 461 example, a forwarding implementation may choose to decrease the hop 462 limit more quickly when forwarding along sibling paths than along 463 parent paths. A forwarding engine may behave in a manner similar to 464 these examples, however the specific implementation of a forwarding 465 engine and related path diversity strategies is beyond the scope of 466 this specification. 468 Note that the further interaction of the routing solution and the 469 forwarding engine, in particular how they utilize and react to 470 changes in metrics, and how the forwarding engine may use the 471 constrained set of successors provided by the routing engine based on 472 L2 triggers and metrics, is under investigation. 474 By employing this procedure, the LLN is able to set up a path- 475 constrained DAG, rooted at designated nodes, with other nodes 476 organized along paths leading inward toward the DAG root. MP2P 477 traffic intended for the default destination flows inward along the 478 DAG towards the root, and nodes forwarding traffic are able to 479 leverage the path diversity of the DAG as necessary. 481 The DAG is then used by RPL as a reference topology, constraining the 482 LLN routing problem, on which to build additional routing mechanisms. 484 3.3.1.2. Further Operation 486 The sub-DAG of a node is the set of other nodes of greater depth in 487 the DAG that might use a path towards the DAG root that contains this 488 node. Depth in the DAG is defined such that nodes contained in the 489 sub-DAG of a specific node should tend to have a greater depth than 490 the node. Paths through siblings are not contained in this set. 492 As a further illustration, consider the DAG examples in Appendix B. 493 Consider Node (24) in the DAG Example depicted in Figure 12. In this 494 example, the sub-DAG of Node (24) is comprised of Nodes (34), (44), 495 and (45). 497 A DAG may also be floating, in which case the node rooting the DAG is 498 not offering a default route. Floating DAGs may be encountered, for 499 example, during coordinated reconfigurations of the network topology 500 wherein a node and its sub-DAG breaks off the DAG, temporarily 501 becomes a floating DAG, and reattaches to a grounded DAG at a 502 different (more optimal) location. (Such coordination endeavors to 503 avoid the construction of transient loops in the LLN). A DAG, or a 504 sub-DAG, may also become floating because of a network element 505 failure. 507 A node will generally join at least one DAG, typically (but not 508 necessarily) to or through a LBR. This specification does not 509 preclude a node from joining multiple DAGs. In one such case, a 510 particular application may require the node to maintain membership in 511 multiple DAGs in order to satisfy competing constraints, for example 512 to support different types of traffic, similar to the concept of MTR 513 (Multi-topology routing) as supported by other routing protocols such 514 as IS-IS [RFC5120] or OSPF [RFC4915], although the RPL mechanisms 515 will significantly differ from the ones specified for these 516 protocols. (Note that not all constrained traffic cases may require 517 multiple DAGs). In support of such cases the RPL implementation must 518 independently maintain requisite information and state for each DAG 519 in parallel. In cases where a competing constraints must be 520 satisfied toward the same DAG root, the OCP should differ by 521 definition and may serve to coordinate the maintenance of the 522 multiple DAGs. 524 3.3.1.3. Router Advertisement - DAG Information Option (RA-DIO) 526 The IPv6 Router Advertisement mechanism (as specified in [RFC4861]) 527 is used by RPL in order to build and maintain a DAG. 529 The IPv6 Router Advertisement message is augmented with a DAG 530 Information Option (DIO) in order to facilitate the formation and 531 maintenance of DAGs. The information conveyed in the DIO includes 532 the following: 534 o A DAGID used to identify the DAG as sourced from the DAG Root. 535 Typically the (potentially compressed) IPv6 address of the DAG 536 Root. May be tested for equality. 538 o Objective Code Point (OCP) as described below. 540 o Depth information used by nodes to determine their relationships 541 in the DAG relative to each other, i.e. parents, siblings, or 542 children. This is not a metric, although its derivation is 543 typically closely related to one or more metrics as specified by 544 the OCP. Used to support loop avoidance strategies and in support 545 of ordering alternate successors when engaged in path maintenance. 547 o Sequence number originated from the DAG root, used to aid in 548 identification of dependent sub-DAGs and coordinate topology 549 changes in a manner so as to avoid loops. 551 o Indications for the DAG, e.g. grounded or floating. 553 o DAG configuration parameters 554 o A vector of path metrics. As discussed in 555 [I-D.ietf-roll-routing-metrics] such metrics may be cumulative, 556 may report a maximum, minimum, or average scalar value, or a link 557 property. 559 o List of additional destinations prefixes reachable via the DAG 560 root. 562 The Router Advertisements are issued whenever a change is detected to 563 the DAG such that a node is able to determine that a region of the 564 DAG has become inconsistent. As the DAG stabilizes the period at 565 which Router Advertisements occur is configured to taper off, 566 reducing the steady-state overhead of DAG maintenance. The periodic 567 issue of Router Advertisements, along with the triggered Router 568 Advertisements in response to inconsistency, is one feature that 569 enables RPL to operate in the presence of unreliable links. 571 The RA-DIO and related mechanisms are described in more detail in 572 Section 5. 574 3.3.1.4. Objective Code Point (OCP) 576 The OCP is seeded by the DAG Root and serves to convey and control 577 the optimization functions used within the DAG. The OCP is envisaged 578 to serve as an reference into a TBA Registry. Each instance of an 579 allocated OCP MUST indicate: 581 o The set of metrics used within the DAG 583 o The objective functions used to determine the least cost 584 constrained paths in order to optimize the DAG 586 o The function used to compute DAG Depth 588 o The functions used to construct derived metrics for propagation 589 within a DIO 591 For example, and objective code point might indicate that the DAG is 592 using ETX, that the optimization goal is to minimize ETX, that DAG 593 Depth is equivalent to ETX, and that DIO propagation entails adding 594 the advertised ETX of the most preferred parent to the ETX of the 595 link to the most preferred parent. 597 By using defined OCPs that are understood by all nodes in a 598 particular implementation, and by conveying them in the DIO, RPL 599 nodes may work to build optimized LLN using a variety of application 600 and implementation specific metrics and goals. 602 NOTE: A NULL OCP MUST be specified with a well-defined default 603 behavior. The NULL code point will subsequently be used to define 604 RPL behaviors in the case where a node encounters a DIO containing a 605 code point that it does not support. 607 3.3.1.5. Selection of Feasible DAG Parents 609 The decision for a node to join a DAG may be optimized according to 610 implementation specific policy functions on the node as indicated by 611 one or more specific OCP values. For example, a node may be 612 configured for one goal to optimize a bandwidth metric (OCP-1), and 613 with a parallel goal to optimize for a reliability metric (OCP-2). 614 Thus two DAGs in parallel may be constructed and maintained in the 615 LLN, DAG-1 would be optimized according to OCP-1, whereas DAG-2 would 616 be optimized according to OCP-2. A node may then maintain two 617 parallel sets of DAG parents. Note that in such a case traffic may 618 directed along the appropriate constrained DAG based on traffic 619 marking within the IPv6 header. 621 As a node hears RAs from its neighbors it may process their DIOs. At 622 this time the node may be able to take into consideration, for 623 example, the following: 625 o Is the neighboring node heard reliably enough, and are the metrics 626 stable enough, that a local degree of confidence may be 627 established with respect to the neighboring node? Should the 628 neighboring node be considered in the set of candidate neighbors? 630 o In consultation with implementation specific policy (OCP goal), is 631 the neighboring node a feasible parent from a constrained-path 632 perspective? 634 o According to the implementation specific policy (OCP), does the 635 neighboring node offer a better optimized position into the DAG? 637 o Is the neighboring node a peer (sibling) within the DAG? 639 Based on such considerations, the node may incorporate the 640 neighboring node into the set of DAG parents. 642 When the node inserts the first DAG parent into the empty DAG parent 643 set, it is able to join the DAG. After the DAG parent set is 644 updated, the node will consult a depth computation function indicated 645 by the OCP for the DAG in order to determine its depth value, which 646 it will subsequently advertise when it emits its own DIOs. A general 647 property of the depth value presented by the node is that it should 648 be greater than that presented by any of its DAG parents. It is 649 recommended that a node maintain its DAG Parent set such that its 650 most preferred parent from the OCP goals also has the greatest depth 651 value in the DAG parent set. All reliable neighboring nodes of a 652 lesser depth then the node may then be considered as potential DAG 653 parents. All neighboring nodes of equal depth may come to be 654 considered as siblings within the DAG (even though they may not have 655 parents in common, they may still provide path diversity towards the 656 DAG root). 658 The computation of depth, and related properties, are further 659 described in Section 3.4.1. 661 3.3.1.5.1. Example 663 For example, suppose that a node (N) is not attached to any DAG, and 664 that it is in range of nodes (A), (B), (C), (D), and (E). Let all 665 nodes be configured to use an OCP which defines a policy such that 666 ETX is to be minimized and paths with the attribute `Blue' should be 667 avoided. Let the depth computation indicated by the OCP simply 668 reflect the ETX aggregated along the path. Let the links between 669 node (N) and its neighbors (A-E) all have an ETX of 1 (which is 670 learned by node (N) through some implementation specific method). 671 Let node (N) be configured to send Router Solicitations to probe for 672 nearby DAGs. 674 o Node (N) transmits a Router Solicitation. 676 o Node (B) responds. Node (N) investigates the DIO, and learns that 677 Node (B) is a member of DAGID 1 at depth 4, and not `Blue'. Node 678 (N) takes note of this, but is not yet confident. 680 o Similarly, Node (N) hears from Node (A) at depth 9, Node (C) at 681 depth 5, and Node (E) at depth 4. 683 o Node (D) responds. Node (D) has a DIO that indicates that it is a 684 member of DAGID 1 at depth 2, but it carries the attribute `Blue'. 685 Node (N)'s policy function rejects Node (D), and no further 686 consideration is given. 688 o This process continues until Node (N), based on implementation 689 specific policy, builds up enough confidence to trigger a decision 690 to join DAGID 1. Let Node (N) determine its most preferred parent 691 to be Node (E). 693 o Node (N) adds Node (E) (depth 4) to its set of DAG Parents for 694 DAGID 1. Following the mechanisms specified by the OCP, and given 695 that the ETX is 1 for the link between (N) and (E), Node (N) is 696 now at depth 5 in DAGID. 1. 698 o Node (N) adds Node (B) (depth 4) to its set of DAG Parents for 699 DAGID 1. 701 o Node (N) is a sibling of Node (C), both are at depth 5. 703 o Node (N) may now forward traffic intended for the default 704 destination inward along DAGID 1 via nodes (B) and (E). In some 705 cases, e.g. if nodes (B) and (E) are tried and fail, node (N) may 706 also choose to forward traffic to its sibling node (C), without 707 making inward progress but with the intention that node (C) or a 708 following successor can make inward progress. 710 3.3.1.6. DAG Maintenance 712 When a node moves within a DAG, the move is defined as updating the 713 set of DAG Parents for a particular DAGID, i.e. adding or deleting 714 DAG Parents. Not all moves entail changes in depth. 716 A jump in the context of a DAG is attaching to a new DAGID, in such a 717 way that an old DAGID is replaced by the new DAGID. In particular, 718 when an old DAGID is left, all associated parents are no longer 719 feasible, and a new DAGID is joined. 721 When a node in a DAG follows a DAG parent, it means that the DAG 722 parent has changed its DAGID (e.g. by joining a new DAG) and that the 723 node updates its own DAGID in order to keep the DAG parent. 725 A frozen sub-DAG is a subset of nodes in the sub-DAG of a node who 726 have been informed of a change to the node, and choose to follow the 727 node in a manner consistent with the change, for example in 728 preparation for a coordinated move. Nodes in the sub-DAG who hear of 729 a change and have other options than to follow the node do not have 730 to become part of the frozen sub-DAG, for example such a node may be 731 able to remain attached to the original DAG through a different DAG 732 Parent. A further example may be found in Section 3.4.1.1. 734 When the node encounters new candidate neighbors that offer higher 735 positions in the DAG, it may incorporate them directly into its set 736 of DAG parents. In this case the node may update its choice of most 737 preferred parent, discarding a deeper node and possibly causing its 738 own advertised depth to decrease. This case is `moving inwards along 739 the DAG' and does not require any additional coordination for loop 740 avoidance. 742 If the DAG parent set of the node becomes completely depleted, the 743 node will have detached from the DAG, and will become the root of its 744 own floating DAG (thus establishing the frozen sub-DAG), and then may 745 reattach to the original DAG at a lower point if it is able. 747 When the node encounters candidate parents that are in a different 748 DAG, and decides to leave the current DAG in order to join the 749 different DAG, it may do so safely without regard to loop avoidance. 750 However, it may not return immediately to the current DAG as such 751 movement may trigger the creation of loops. 753 When a node, and perhaps a related frozen sub-DAG, jumps to a 754 different DAG, the move is coordinated by a DAG Hop timer. The DAG 755 Hop timer allows the nodes who will attach closer to the sink of the 756 new DAG to `jump' first, and then drag dependent nodes behind them, 757 thus endeavoring to efficiently coordinate the attachment of the 758 frozen sub-DAG into the new DAG. A further illustration of this 759 mechanism may be found in Section 3.4.3. 761 Section 5 contains more detail on the processes and rules used for 762 DAG discovery and maintenance. 764 Appendix B provides additional examples of DAG discovery and 765 maintenance. 767 3.3.2. Source Routing 769 A Source Routing mechanism for RPL is currently under investigation. 771 3.3.3. Destination Advertisement 773 As RPL constructs DAGs, nodes are able to learn a set of default 774 routes in order to send traffic to the sink. However, this mechanism 775 alone does is not sufficient to support P2MP traffic flowing outward 776 along the DAG from the DAG root toward nodes. A Destination 777 Advertisement mechanism is employed by RPL to build up routing state 778 in support of these outward flows. 780 3.3.3.1. Destination Advertisement Option (DAO) 782 A Destination Advertisement Option (DAO) is used to convey the 783 Destination information inward along the DAG toward the DAG root. 785 The information conveyed in the DAO includes the following: 787 o A lifetime and sequence counter to determine the freshness of the 788 Destination Advertisement. 790 o Depth information used by nodes to determine how far away the 791 destination (the source of the Destination Advertisement) is 793 o Prefix information to identify the destination, which may be a 794 prefix, an individual host, or multicast listeners 796 o Reverse Route information to record the nodes visited (along the 797 outward path) when the intermediate nodes along the path cannot 798 support storing state for Hop-By-Hop routing. 800 3.3.3.2. Destination Advertisement Operation 802 As the DAG is constructed and maintained, nodes will emit messages 803 containing Destination Advertisement Options to a subset of their DAG 804 Parents. The selection of this subset is according to an 805 implementation specific policy. 807 Note that further details of the message and its triggers are still 808 under investigation, including whether or not the DAO should be a 809 IPv6 Hop-By-Hop option or a Neighbor Discovery option. 811 When a DAO reaches a node capable of storing routing state, the node 812 extracts information from the DAO and updates its local database with 813 a record of the DAO and who it was received from. When the node 814 later propagates DAOs, it selects the best (least depth) information 815 for each destination and conveys this information again in the form 816 of DAOs to a subset of its own DAG parents. At this time the node 817 may perform route aggregation if it is able, thus reducing the 818 overall number of DAOs. 820 When a DAO reaches a node incapable of storing additional state, the 821 node MUST append its own address to a Reverse Route Stack carried 822 within the DAO. The node then passes the DAO on to one or more of 823 its DAG parents without storing any additional state. 825 When a node that is capable of storing routing state encounters a DAO 826 with a Reverse Route Stack that has been populated, the node knows 827 that the DAO has traversed a region of nodes that did not record any 828 routing state. The node is able to detach and store the Reverse 829 Route State and associate it with the destination described by the 830 DAO. Subsequently the node may use this information to construct a 831 source route in order to bridge the region of nodes that are unable 832 to support Hop-By-Hop routing to reach the destination. 834 In this way the Destination Advertisement mechanism is able to 835 provision routing state in support of P2MP traffic flows outward 836 along the DAG, and as according to the available resources in the LLN 837 nodes. 839 Further aggregations of DAOs by destinations are possible in order to 840 support additional scalability. 842 A further example of the operation of the Destination Advertisement 843 mechanism is available in Appendix B.6 845 3.4. Other Considerations 847 3.4.1. DAG Depth and Loop Avoidance 849 When nodes select DAG Parents, they should select the most preferred 850 parent according to their implementation specific objectives, using 851 the cost metrics conveyed in the DIOs along the DAG in conjunction 852 with the related objective functions as specified by the OCP. 854 Based on this selection, the metrics conveyed by the most preferred 855 DAG parent, the nodes own metrics and configuration, and a related 856 function defined by the objective code point, a node will be able to 857 compute a value for its depth as a consequence of selecting a most 858 preferred DAG parent. 860 It is important to note that the DAG Depth is not itself a metric, 861 although its value is derived from and influenced by the use of 862 metrics to select DAG parents and take up a position in the DAG. The 863 computation of the DAG Depth MUST be done in such a way so as to 864 maintain the following properties for any nodes M and N who are 865 neighbors in the LLN: 867 For a node N, and its most preferred parent M, DAGDepth(N) > 868 DAGDepth(M) must hold. Further, all parents in the DAG parent set 869 must be of a depth less than or equal to DAGDepth(M). (This 870 mechanism serves to avoid loops in the case where an alternate 871 parent is used- if no alternate parent is deeper than the 872 preferred parent then loops are avoided. The risk of loops occurs 873 when an alternate parent goes deeper, and traffic then makes 874 backwards progress and comes back to the node again). 876 If DAGDepth(M) < DAGDepth(N), then M is located in a more optimum 877 position than N in the DAG with respect to the metrics and 878 optimizations defined by the objective code point. Node M may 879 safely be a DAG Parent for Node N without risk of creating a loop. 881 If DAGDepth(M) == DAGDepth(N), then M and N are located positions 882 of relatively the same optimality within the DAG. In some cases, 883 Node M may be used as a successor by Node N, but with related 884 chance of creating a loop that must be detected and broken by some 885 other means. 887 If DAGDepth(M) > DAGDepth(N), then node M is located in a less 888 optimum position than N in the DAG with respect to the metrics and 889 optimizations defined by the objective code point. Further, Node 890 (M) may in fact be in Node (N)'s sub-DAG. There is no advantage 891 to Node (N) selecting Node (M) as a DAG Parent, and such a 892 selection may create a loop. 894 For example, the DAG Depth could be computed in such a way so as to 895 closely track ETX when the objective function is to minimize ETX, or 896 latency when the objective function is to minimize latency, or in a 897 more complicated way as appropriate to the objective code point being 898 used within the DAG. 900 The DAG depth is subsequently used to restrict the options a node has 901 for movement within the DAG and to coordinate movements in order to 902 avoid the creation of loops. 904 A node may safely move `up' in the DAG, causing its DAG depth to 905 decrease and moving closer to the DAG root without risking the 906 formation of a loop. 908 A node may not consider to move `down' the DAG, causing its DAG depth 909 to increase and moving further from the DAG root. Such a move will 910 entail moving to a less optimum position in the DAG in all cases, as 911 defined by the objective code point. In the case where a node looses 912 connectivity to the DAG, it must first leave the DAG before it may 913 then rejoin at a deeper point. 915 Any neighboring nodes of lesser or equal depth are eligible to be 916 considered as DAG parents. 918 3.4.1.1. Example 920 : : : 921 : : : 922 (A) (A) (A) 923 |\ | | 924 | `-----. | | 925 | \ | | 926 (B) (C) (B) (C) (B) 927 | | \ 928 | | `-----. 929 | | \ 930 (D) (D) (C) 931 | 932 | 933 | 934 (D) 936 [1] [2] [3] 938 Figure 1: DAG Maintenance 940 Consider the example depicted in Figure 1-1. In this example, Node 941 (A) is attached to a DAG at some depth d. Node (A) is a DAG Parent 942 of Nodes (B) and (C). Node (C) is a DAG Parent of Node (D). There 943 is also an undirected sibling link between Nodes (B) and (C). 945 In this example, Node (C) may safely forward to Node (A) without 946 creating a loop. Node (C) may not safely forward to Node (D), 947 contained within it's own sub-DAG, without creating a loop. Node (C) 948 may forward to Node (B) in some cases, e.g. the link (C)->(A) is 949 temporarily unavailable, but with some chance of creating a loop and 950 requiring the intervention of additional mechanisms to detect and 951 break the loop. 953 Consider the case where Node (C) hears a DIO from a Node (Z) at a 954 lesser depth and superior position in the DAG than node (A). Node 955 (C) may safely undergo the process to evict node (A) from its DAG 956 Parent set and attach directly to Node (Z) without creating a loop, 957 because its depth will decrease. 959 Consider the case where the link (C)->(A) becomes nonviable, and node 960 (C) must move to a deeper depth within the DAG: 962 o Node (C) must first detach from the DAG by removing Node (A) from 963 its DAG Parent set, leaving an empty DAG Parent set. Node (C) 964 becomes the root of its own floating DAG. 966 o Node (D), hearing a modified RA-DIO from Node (C), follows Node 967 (C) into the floating DAG. This is depicted in Figure 1-2. In 968 general, any node with no other options in the sub-DAG of Node (C) 969 will follow Node (C) into the floating DAG, maintaining the 970 structure of the sub-DAG. 972 o Node (C) hears a RA-DIO from Node (B) and determines it is able to 973 rejoin the grounded DAG by reattaching at a deeper depth to Node 974 (B). Node (C) starts a DAG Hop timer to coordinate this move. 976 o The timer expires and Node (C) adds Node (B) to its DAG Parent 977 set. Node (C) has now safely moved deeper within the grounded DAG 978 without creating any loops. Node (D), and any other sub-DAG of 979 Node (C), will hear the modified RA-DIO sourced from Node (C) and 980 follow Node (C) in a coordinated manner to reattach to the 981 grounded DAG. The final DAG is depicted in Figure 1-3 983 3.4.2. DAG Parent Selection, Stability, and Greediness 985 If a node is greedy and attempts to move deeper in the DAG, beyond 986 its most preferred parent, in order to increase the size of the DAG 987 Parent set, then an instability can result. This is illustrated in 988 Figure 2. 990 Suppose a node is willing to receive and process a RA-DIOs from a 991 node in its own sub-DAG, and in general a node deeper than it. In 992 such cases a chance exists to create a feedback loop, wherein two or 993 more nodes continue to try and move in the DAG in order to optimize 994 against each other. In some cases this will result in an 995 instability. It is for this reason that RPL recommends that a node 996 MUST NOT receive and process RA-DIOs from deeper nodes. This rule 997 creates an `event horizon', whereby a node cannot be influenced into 998 an instability by the action of nodes that may be in its own sub-DAG. 1000 3.4.2.1. Example 1002 (A) (A) (A) 1003 |\ |\ |\ 1004 | `-----. | `-----. | `-----. 1005 | \ | \ | \ 1006 (B) (C) (B) \ | (C) 1007 \ | | / 1008 `-----. | | .-----` 1009 \| |/ 1010 (C) (B) 1012 [1] [2] [3] 1014 Figure 2: Greedy DAG Parent Selection 1016 Consider the example depicted in Figure 2. A DAG is depicted in 3 1017 different configurations. A usable link between (B) and (C) exists 1018 in all 3 configurations. In Figure 2-1, Node (A) is a DAG Parent for 1019 Nodes (B) and (C), and (B)--(C) is a sibling link. In Figure 2-2, 1020 Node (A) is a DAG Parent for Nodes (B) and (C), and Node (B) is also 1021 a DAG Parent for Node (C). In Figure 2-3, Node (A) is a DAG Parent 1022 for Nodes (B) and (C), and Node (C) is also a DAG Parent for Node 1023 (B). 1025 If a RPL node is too greedy, in that it attempts to optimize for an 1026 additional number of parents beyond its preferred parent, then an 1027 instability can result. Consider the DAG illustrated in Figure 2-1. 1028 In this example, Nodes (B) and (C) may most prefer Node (A) as a DAG 1029 Parent, but are operating under the greedy condition that will try to 1030 optimize for 2 parents. 1032 o Let Figure 2-1 be the initial condition. 1034 o Suppose Node (C) first is able to leave the DAG and rejoin at a 1035 lower depth, taking both Nodes (A) and (B) as DAG parents as 1036 depicted in Figure 2-2. Now Node (C) is deeper than both Nodes 1037 (A) and (B), and Node (C) is satisfied to have 2 DAG parents. 1039 o Suppose Node (B), in its greediness, is willing to receive and 1040 process a DIO from Node (C) (against the rules of RPL), and then 1041 Node (B) leaves the DAG and rejoins at a lower depth, taking both 1042 Nodes (A) and (C) as DAG Parents. Now Node (B) is deeper than 1043 both Nodes (A) and (C) and is satisfied with 2 DAG parents. 1045 o Then Node (C) will leave and rejoin deeper, to again get 2 parents 1047 o Then Node (B) will leave and rejoin deeper, to again get 2 parents 1049 o ... 1051 o The process will repeat, and the DAG will oscillate between 1052 Figure 2-2 and Figure 2-3 until the nodes count to infinity and 1053 restart the cycle again. 1055 o This cycle can be averted through mechanisms in RPL: 1057 * Nodes (B) and (C) stick at a depth sufficient to attach to 1058 their most preferred parent (A) and don't go for any deeper 1059 (worse) alternate parents (Nodes are not greedy) 1061 * Nodes (B) and (C) don't process DIOs from nodes deeper than 1062 themselves (possibly in their own sub-DAGs) 1064 3.4.3. Merging DAGs 1066 The merging of DAGs is coordinated in a way such as to try and merge 1067 two DAGs cleanly, preserving as much DAG structure as possible, and 1068 in the process effecting a clean merge with minimal likelihood of 1069 forming transient loops 1071 3.4.3.1. Example 1073 : 1074 : 1075 (A) (D) 1076 | | 1077 | | 1078 | | 1079 (B) (E) 1080 | | 1081 | | 1082 | | 1083 (C) (F) 1085 Figure 3: Merging DAGs 1087 Consider the example depicted in Figure 3. Nodes (A), (B), and (C) 1088 are part of some larger grounded DAG, where Node (A) is at a depth of 1089 d, Node (B) at d+1, and Node (C) at d+2. The DAG comprised of Nodes 1090 (D), (E), and (F) is a floating DAG, with Node (D) as the DAG root. 1091 This floating DAG may have been formed, for example, in the absence 1092 of a grounded DAG or when Node (D) had to detach from a grounded DAG 1093 and (E) and (F) followed. All nodes are using compatible objective 1094 code points. 1096 Nodes (D), (E), and (F) would rather join the grounded DAG if they 1097 are able than to remain in the floating DAG. 1099 Next, let links (C)--(D) and (A)--(E) become viable. The following 1100 sequence of events may then occur in a typical case: 1102 o Node (D) will receive and process a RA-DIO from Node (C) on link 1103 (C)--(D). Node (D) will consider Node (C) a candidate neighbor, 1104 will note that Node (C) is in a grounded DAG at depth d+2, and 1105 will begin the process to join the grounded DAG at depth d+3. 1106 Node (D) will start a DAG Hop timer, logically associated with the 1107 grounded DAG at Node (C), to coordinate the jump. The DAG Hop 1108 timer will have a duration proportional to d+2. 1110 o Similarly, Node (E) will receive and process a RA-DIO from Node 1111 (A) on link (A)--(E). Node (E) will consider Node (A) a candidate 1112 neighbor, will note that Node (A) is in a grounded DAG at depth d, 1113 and will begin the process to join the grounded DAG at depth d+1. 1114 Node (E) will start a DAG Hop timer, logically associated with the 1115 grounded DAG at Node (A), to coordinate the jump. The DAG Hop 1116 timer will have a duration proportional to d. 1118 o Node (F) takes no action, for Node (F) has observed nothing new to 1119 act on. 1121 o Node (E)'s DAG Hop timer for the grounded DAG at Node (A) expires 1122 first. Node (E), upon the DAG Hop timer expiry, is removes Node 1123 (D), thus emptying the DAG parent set for the floating DAG and 1124 leaving the floating DAG. Node (E) then jumps to the grounded DAG 1125 by entering Node (A) into the set of DAG Parents for the grounded 1126 DAG. Node (E) is now in the grounded DAG at depth d+1. Node (E), 1127 by jumping into the grounded DAG, has created an inconsistency and 1128 will begin to emit RA-DIOs more frequently. 1130 o Node (F) will receive and process a RA-DIO from Node (E). Node 1131 (F) will observe that Node (E) has changed its DAGID and will 1132 directly follow Node (E) into the grounded DAG. Node (F) is now a 1133 member of the grounded DAG at depth d+2. Note that any additional 1134 sub-DAG of Node (E) would continue to join into the grounded DAG 1135 in this coordinated manner. 1137 o Node (D) will receive a RA-DIO from Node (E). Since Node (E) is 1138 now in a different DAG, Node (D) may process the RA-DIO from Node 1139 (E). Node (D) will observe that, via node (E), it could attach to 1140 the grounded DAG at depth d+2. Node (D) will start another DAG 1141 Hop timer, logically associated with the grounded DAG at Node (E), 1142 with a duration proportional to d+1. Node (D) now is running two 1143 DAG hop timers, one which was started with duration proportional 1144 to d+1 and one proportional to d+2. 1146 o Generally, Node (D) will expire the timer associated with the jump 1147 to the grounded DAG at node (E) first. Node (D) may then jump to 1148 the grounded DAG by entering Node (E) into its DAG Parent set for 1149 the grounded DAG. Node (D) is now in the grounded DAG at depth 1150 d+2. 1152 o In this way RPL has coordinated a merge between the grounded DAG 1153 and the floating DAG, such that the nodes within the two DAGs come 1154 together in a generally ordered manner, avoiding the formation of 1155 loops in the process. 1157 3.4.4. Local and Temporary Routing Decision 1159 Although implementation specific, it is worth noting that a node may 1160 decide to implement some local routing decision based on some 1161 metrics, as observed locally or reported in the DIO. For example, 1162 the routing may reflect a set of successors (next-hop), along with 1163 various aggregated metrics used to load balance the traffic according 1164 to some local policy. Such decisions are local and implementation 1165 specific. 1167 Routing stability is crucial in a LLN: in the presence of unstable 1168 links, the first option consists of removing the link from the DAG 1169 and triggering a DAG recomputation across all of the nodes affected 1170 by the removed link. Such a naive approach could unavoidably lead to 1171 frequent and undesirable changes of the DAG, routing instability, and 1172 high-energy consumption. The alternative approach adopted by RPL 1173 relies on the ability to temporarily not use a link toward a 1174 successor marked as valid, with no change on the DAG structure. If 1175 the link is perceived as non-usable for some period of time (locally 1176 configurable), this triggers a DAG recomputation, through the DAG 1177 Discovery mechanism further detailed in Section 5.3, after reporting 1178 the link failure. Note that this concept may be extended to take 1179 into account other link characteristics: for the sake of 1180 illustration, a node may decide to send a fixed number of packets to 1181 a particular successor (because of limited buffering capability of 1182 the successor) before starting to send traffic to another successor. 1184 According to the local policy function, it is possible for the node 1185 to order the DAG parent set from `most preferred' to `least 1186 preferred'. By constructing such an ordered set, and by appending 1187 the set with siblings, the node is able to construct an ordered list 1188 of preferred next hops to assist in local and temporary routing 1189 decisions. The use of the ordered list by a forwarding engine is 1190 loosely constrained, and may take into account the dynamics of the 1191 LLN. Further, a forwarding engine implementation may decide to 1192 perform load balancing functions using hash-based mechanisms to avoid 1193 packet re-ordering. Note however, that specific details of a 1194 forwarding engine implementation are beyond the scope of this 1195 document. 1197 These decisions may be local and/or temporary with the objective to 1198 maintain the DAG shape while preserving routing stability. 1200 3.4.5. Scalability 1202 As each node selects DAG Parents according to implementation specific 1203 objectives, RPL is able to dynamically partition an LLN network into 1204 different regions, each anchored by a DAG root. Multiple DAG roots 1205 may be deployed in accordance with an implementation specific policy 1206 designed to limit the size of a partition, e.g. for performance or 1207 other reasons. 1209 A further example is illustrated in Appendix C. 1211 3.4.6. Maintenance of Routing Adjacency 1213 In order to relieve the LLN of the overhead of periodic keepalives, 1214 RPL MAY employ an as-needed mechanism of NS/NA in order to verify 1215 routing adjacencies just prior to forwarding data. Pending the 1216 outcome of verifying the routing adjacency, the packet may either be 1217 forwarded or an alternate next-hop may be selected. 1219 4. Constraint Based Routing in LLNs 1221 This aim of this section is to make a clear distinction between 1222 routing metrics and constraints and define the term constraint based 1223 routing as used in this document. 1225 4.1. Routing Metrics 1227 Routing metrics are used by the routing protocol to compute the 1228 shortest path according to one of more defined metrics. IGPs such as 1229 IS-IS ([RFC5120]) and OSPF ([RFC4915]) compute the shortest path 1230 according to a Link State Data Base (LSDB) using link metrics 1231 configured by the network administrator. Such metrics can represent 1232 the link bandwidth (in which case the metric is usually inversely 1233 proportional to the bandwidth), delay, etc. Note that in some cases 1234 the metric is a polynomial function of several metrics defining 1235 different link characteristics. The resulting shortest path cost is 1236 equal to the sum (or multiplication) of the link metrics along the 1237 path: such metrics are said to be additive or multiplicative metrics. 1239 Some routing protocols support more than one metric: in the vast 1240 majority of the cases, one metric is used per (sub)topology. Less 1241 often, a second metric may be used as a tie breaker in the presence 1242 of ECMP (Equal Cost Multiple Paths). The optimization of multiple 1243 metrics is known as an NP complete problem and is sometimes supported 1244 by some centralized path computation engine. 1246 In the case of RPL, it is virtually impossible to define *the* 1247 metric, or even a composite, that will fit it all: 1249 o Some information apply to path setup time, other apply to packet 1250 forwarding time. 1252 o Some values are aggregated hop-by-hop, others are triggers from 1253 L2. 1255 o Some properties are very stable, others vary rapidly. 1257 o Some data are useful in a given scenario and useless in another. 1259 o Some arguments are scalar, others statistical. 1261 For that reason, the RPL protocol core is agnostic to the logic that 1262 handles metrics. A node will be configured with some external logic 1263 to use and prioritize certain metrics for a specific scenario. As 1264 new heterogeneous devices are installed to support the evolution of a 1265 network, or as networks form in a totally ad-hoc fashion, it will 1266 happen that nodes that are programmed with antagonistic logics and 1267 conflicting or orthogonal priorities end up participating in the same 1268 network. It is thus RECOMMENDED to use consistent parent selection 1269 policy, as per Objective Code Points (OCP), to ensure consistent 1270 optimized paths. 1272 RPL is designed to survive and still operate, though in a somewhat 1273 degraded fashion, when confronted to such heterogeneity. The key 1274 design point is that each node is solely responsible for setting the 1275 vector of metrics that it sources in the DAG, derived in part from 1276 the metrics sourced from its preferred parent. As a result, the DAG 1277 is not broken if another node makes its decisions in as antagonistic 1278 fashion, though an end-to-end path might not fully achieve any of the 1279 optimizations that nodes along the way expect. The to-be-defined 1280 NULL OCP and related behaviors will further clarify this point. 1282 4.2. Routing Constraints 1284 A constraint is a link or a node characteristic that must be 1285 satisfied by the computed path (using boolean values or lower/upper 1286 bounds) and is by definition neither additive nor multiplicative. 1287 Examples of links constraints are "available bandwidth", 1288 "administrative values (e.g. link coloring)", "protected versus non- 1289 protected links", "link quality" whereas a node constraint can be the 1290 level of battery power, CPU processing power, etc. 1292 4.3. Constraint Based Routing 1294 The notion of constraint based routing consists of finding the 1295 shortest path according to some metrics satisfying a set of 1296 constraints. A technique consists of first filtering out all links 1297 and nodes that cannot satisfy the constraints (resulting in a sub- 1298 topology) and then computing the shortest path. 1300 Example 1: 1301 Link Metric: Bandwidth 1302 Link Constraint: Blue 1303 Node Constraint: Mains-powered node 1305 Objective function 1: 1306 "Find the shortest path (path with lowest cost where the path 1307 cost is the sum of all link costs (Bandwidth)) along the path 1308 such that all links are colored `Blue' and that only traverses 1309 Mains-powered nodes." 1311 Example 2: 1312 Link Metric: Delay 1313 Link Constraint: Bandwidth 1315 Objective function 2: 1316 "Find the shortest path (path with lowest cost where the path 1317 cost is the sum of all link costs (Delay)) along the path such 1318 that all links provide at least X Bit/s of reservable 1319 bandwidth." 1321 5. Specification of Core Protocol 1323 5.1. DAG Information Option 1325 The DAG Information Option carries a number of metrics and other 1326 information that allows a node to discover a DAG, select its DAG 1327 parents, and identify its siblings while employing loop avoidance 1328 strategies. 1330 5.1.1. DIO base option 1332 The DAG Information Option is a container option, which might contain 1333 a number of suboptions. The base option regroups the minimum 1334 information set that is mandatory in all cases. 1336 0 1 2 3 1337 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1338 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1339 | Type | Length |G|D| Reserved | Sequence | 1340 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1341 | DAGPreference | BootTimeRandom | 1342 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1343 | NodePref. | DAGDepth | DAGDelay | 1344 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1345 | DIOIntDoubl. | DIOIntMin. | DAGObjectiveCodePoint | 1346 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1347 | PathDigest | 1348 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1349 | | 1350 + + 1351 | DAGID | 1352 + + 1353 | | 1354 + + 1355 | | 1356 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1357 | sub-option(s)... 1358 +-+-+-+-+-+-+-+-+-+-+-+-+-+ 1360 Figure 4: DIO Base Option 1362 Type: 8-bit unsigned identifying the DIO base option. The value is 1363 to be assigned by the IANA. 1365 Length: 8-bit unsigned integer set to 4 when there is no suboption. 1366 The length of the option (including the type and length fields 1367 and the suboptions) in units of 8 octets. 1369 Grounded (G): The Grounded (G) flag is set when the DAG root is 1370 offering a default route. 1372 Destination Advertisement (D): The Destination Advertisement (D) 1373 flag is set when the DAG root or another node in the successor 1374 chain decides to trigger the sending of Destination 1375 Advertisements in order to update routing state for the outward 1376 direction along the DAG, as further detailed in Section 5.4. 1377 Note that the use and semantics of this flag are still under 1378 investigation. 1380 Reserved: 6-bit unsigned integer set to 0 by the DAG root and left 1381 unchanged by nodes propagating the DIO. 1383 Sequence Number: 8-bit unsigned integer set by the DAG root, 1384 incremented with each new DIO it sends on a link, and 1385 propagated with no change outwards along the DAG. 1387 DAGPreference: 8-bit unsigned integer set by the DAG root to its 1388 preference and unchanged at propagation. Default is 0 (lowest 1389 preference). The DAG preference provides an administrative 1390 mechanism to engineer the self-organization of the LLN, for 1391 example indicating the most preferred LBR. 1393 BootTimeRandom: A random value computed at boot time and recomputed 1394 in case of a duplication with another node. The concatenation 1395 of the NodePreference and the BootTimeRandom is a 32-bit 1396 extended preference that is used to resolve collisions. It is 1397 set by each node at propagation time. 1399 NodePreference: The administrative preference of that LLN Node. 1400 Default is 0. 255 is the highest possible preference. Set by 1401 each LLN Node at propagation time. Forms a collision 1402 tiebreaker in combination with BootTimeRandom. 1404 DAGDepth: 8-bit unsigned integer. The DAG depth of the DAG root is 1405 0. The DAG Depth of a node attached to the DAG should be 1406 greater than depth of its deepest DAG parent, as computed by an 1407 implementation specific routine. All nodes in the DAG 1408 advertise their DAG depth in the DAG Information Options that 1409 they append to the RA messages over their LLN interfaces as 1410 part of the propagation process. 1412 DAGDelay: 16-bit unsigned integer set by the DAG root indicating the 1413 delay before changing the DAG configuration, in TBD-units. A 1414 default value is TBD. It is expected to be an order of 1415 magnitude smaller than the RA-interval. It is also expected to 1416 be an order of magnitude longer than the typical propagation 1417 delay inside the LLN. 1419 DIOIntervalDoublings: 8-bit unsigned integer. Used to configure the 1420 trickle timer governing when RA-DIO should be sent within the 1421 DAG. DIOIntervalDoublings is the number of times that the 1422 DIOIntervalMin is allowed to be doubled during the trickle 1423 timer operation, i.e. DIOIntervalMax = DIOIntervalMin * 1424 2^(DIOIntervalDoublings). 1426 DIOIntervalMin: 8-bit unsigned integer. Used to configure the 1427 trickle timer governing when RA-DIO should be sent within the 1428 DAG. The minimum configured interval for the RA-DIO trickle 1429 timer in units of ms is 2^DIOIntervalMin. For example, a 1430 DIOIntervalMin value of 16ms is expressed as 4. 1432 DAGObjectiveCodePoint: The DAG Objective Code Point is used to 1433 indicate the cost metrics, objective functions, and methods of 1434 computation and comparison for DAGDepth in use in the DAG. The 1435 DAG OCP is set by the DAG Root. (Note: this specification 1436 recommends that another document, e.g. 1437 [I-D.ietf-roll-routing-metrics], define Objective Code Points 1438 and recommend a registry to manage them) 1440 PathDigest: 32-bit unsigned integer CRC, updated by each LLN Node. 1441 This is the result of a CRC-32c computation on a bit string 1442 obtained by appending the received value and the ordered set of 1443 DAG parents at the LLN Node. DAG roots use a 'previous value' 1444 of zeroes to initially set the PathDigest. Used to determine 1445 when something in the set of successor paths has changed. 1447 DAGID: 128-bit unsigned integer which uniquely identify a DAG. This 1448 value is set by the DAG root. The global IPv6 address of the 1449 DAG root can be used. 1451 The following values MUST NOT change during the propagation of the 1452 DIO outwards along the DAG: Type, Length, G, DAGPreference, DAGDelay 1453 and DAGID. All other fields of the DIO are updated at each hop of 1454 the propagation. 1456 5.1.1.1. DIO suboptions 1458 In addition to the minimum options presented in the base option, a 1459 number of suboptions are defined for the DIO: 1461 5.1.1.1.1. Format 1463 0 1 2 3 1464 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1465 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1466 | Subopt. Type | Subopt Length | Suboption Data... 1467 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1469 Figure 5: DIO Suboption Generic Format 1471 Suboption Type: 8-bit identifier of the type of suboption. When 1472 processing a DIO containing a suboption for which the Suboption 1473 Type value is not recognized by the receiver, the receiver MUST 1474 silently ignore and skip over the suboption, correctly handling 1475 any remaining options in the message. 1477 Suboption Length: 8-bit unsigned integer, representing the length in 1478 octets of the suboption, not including the suboption Type and 1479 Length fields. 1481 Suboption Data: A variable length field that contains data specific 1482 to the option. 1484 The following subsections specify the DIO suboptions which are 1485 currently defined for use in the DAG Information Option. 1487 Implementations MUST silently ignore any DIO suboptions options that 1488 they do not understand. 1490 DIO suboptions may have alignment requirements. Following the 1491 convention in IPv6, these options are aligned in a packet such that 1492 multi-octet values within the Option Data field of each option fall 1493 on natural boundaries (i.e., fields of width n octets are placed at 1494 an integer multiple of n octets from the start of the header, for n = 1495 1, 2, 4, or 8). 1497 5.1.1.1.2. Pad1 1499 The Pad1 suboption does not have any alignment requirements. Its 1500 format is as follows: 1502 0 1503 0 1 2 3 4 5 6 7 1504 +-+-+-+-+-+-+-+-+ 1505 | Type = 0 | 1506 +-+-+-+-+-+-+-+-+ 1508 Figure 6: Pad 1 1510 NOTE! the format of the Pad1 option is a special case - it has 1511 neither Option Length nor Option Data fields. 1513 The Pad1 option is used to insert one octet of padding in the DIO to 1514 enable suboptions alignment. If more than one octet of padding is 1515 required, the PadN option, described next, should be used rather than 1516 multiple Pad1 options. 1518 5.1.1.1.3. PadN 1520 The PadN option does not have any alignment requirements. Its format 1521 is as follows: 1523 0 1 1524 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 1525 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - - 1526 | Type = 1 | Subopt Length | Subopt Data 1527 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - - 1529 Figure 7: Pad N 1531 The PadN option is used to insert two or more octets of padding in 1532 the DIO to enable suboptions alignment. For N (N > 1) octets of 1533 padding, the Option Length field contains the value N-2, and the 1534 Option Data consists of N-2 zero-valued octets. PadN Option data 1535 MUST be ignored by the receiver. 1537 5.1.1.1.4. DAG Metric Container 1539 The DAG Metric Container suboption may be aligned as necessary to 1540 support its contents. Its format is as follows: 1542 0 1 1543 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 1544 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - - 1545 | Type = 2 | Container Len | DAG Metric Data 1546 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- - - - - - - - - 1548 Figure 8: DAG Metric Container 1550 The DAG Metric Container is used to report aggregated path metrics 1551 along the DAG. The DAG Metric Container may contain a number of 1552 discrete node, link, and aggregate path metrics as chosen by the 1553 implementer. The Container Length field contains the length in 1554 octets of the DAG Metric Data. The order, content, and coding of the 1555 DAG Metric Container data is as specified in 1556 [I-D.ietf-roll-routing-metrics]. 1558 The processing and propagation of the DAG Metric Container is 1559 governed by implementation specific policy functions. 1561 5.1.1.1.5. Destination Prefix 1563 The Destination Prefix suboption has an alignment requirement of 1564 4n+1. Its format is as follows: 1566 0 1 2 3 1567 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 1568 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1569 | Type = 3 | Length | Prefix Length |Resvd|Prf|Resvd| 1570 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1571 | Destination Prefix (Variable Length) | 1572 . . 1573 . . 1574 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 1576 Figure 9: DAG Destination Prefix 1578 The Destination Prefix suboption is used when the DAG root needs to 1579 indicate that it offers connectivity to destination prefixes other 1580 than the default. This may be useful in cases where more than one 1581 LBR is operating within the LLN and offering connectivity to 1582 different administrative domains, e.g. a home network and a utility 1583 network. (Note that a grounded DIO offers the default route without 1584 any other qualification needed). In such cases, upon observing the 1585 Destination Prefixes offered by a particular DAG root, a node MAY 1586 decide to join multiple DAGs in support of a particular application. 1587 Note that Destination Prefixes specified in this manner inherit the 1588 Router Lifetime of their parent RA. 1590 The Length is coded as the length of the suboption in octets, 1591 excluding the Type and Length fields. The Prefix Length is an 8-bit 1592 unsigned integer that indicates the number of leading bits in the 1593 destination prefix. Prf is the Route Preference as in [RFC4191]. 1594 The Destination Prefix contains Prefix Length significant bits of the 1595 destination prefix. The remaining bits of the Destination Prefix, as 1596 required to complete the trailing octet, are set to 0. 1598 In the event that a DAG root may need to specify that it offers 1599 connectivity to more than one destination, the Destination Prefix 1600 suboption may be repeated. 1602 5.2. Neighbor Discovery 1604 5.2.1. RA-DIO Reception 1606 An node will come to discover its link layer neighbors by a 1607 combination of link layer mechanisms and by hearing the multicast RA 1608 messages from the neighbors. Through these mechanisms a node is able 1609 to construct a set of known neighbors. 1611 When receiving and processing the RA-DIO messages from known 1612 neighbors, in addition to link layer states and characteristics, the 1613 node will come to determine that a neighbor is of particular 1614 interest. As the LLN node periodically observes the neighbor and 1615 determines its behavior to be reliable beyond a certain threshold, 1616 the node may select the neighbor to be part of the candidate neighbor 1617 set and begin to maintain a local confidence value with respect to 1618 the neighbor. 1620 As RA-DIOs are received from candidate neighbors, the DIO information 1621 will be consulted to determine, for example: 1623 1. Does the candidate neighbor offer a position in a different DAG, 1624 or a better position in the current DAG? Is the OCP of the 1625 candidate neighbor compatible with the goals of this node? Do 1626 the related path metrics pass the criteria of a implementation 1627 specific policy function such that the candidate neighbor is 1628 considered feasible? If so then consider the candidate neighbor 1629 as a candidate parent. The decision to move up the DAG is a 1630 policy decision and a node may choose not to move up the DAG if 1631 the path metric is not significantly better than the current one. 1633 2. Does the candidate neighbor exist at the same depth in the 1634 current DAG as this node? Do the related path metrics pass the 1635 criteria of a implementation specific policy function such that 1636 the candidate neighbor is feasible? If so then consider the 1637 candidate neighbor as a DAG sibling. 1639 3. Otherwise, ignore the candidate neighbor. Ignored neighbors may 1640 periodically be re-evaluated to see if their situation has 1641 improved. 1643 The implementation SHOULD provide the ability to bound the size of 1644 the candidate neighbor set, and a scheme SHOULD be applied to add 1645 and/or evict neighbors from the candidate neighbor set as necessary 1646 so as not to exceed the bounds. 1648 As candidate parents are identified, they may subsequently be 1649 promoted to DAG parents by following the rules of DAG Discovery as 1650 described below. When a node adds another node to its set of 1651 candidate parents, the node becomes attached to the DAG through the 1652 parent node. 1654 In the DAG Discovery implementation, the most preferred parent should 1655 be used to restrict which other nodes may become DAG parents. All 1656 nodes in the DAG Parent set should be of a depth less than or equal 1657 to the most preferred DAG parent. 1659 5.2.2. RA-DIO Transmission 1661 Each node maintains a timer that governs when to multicast RAs. This 1662 timer is implemented as a trickle timer operating over a variable 1663 interval. Trickle timers are further detailed in Section 5.2.3. The 1664 governing parameters for the timer should be configured consistently 1665 across the DAG, and are provided by the DAG root in the DIO. In 1666 addition to periodic RAs, each LLN node will respond to Router 1667 Solicitation messages according to [RFC4861]. 1669 o When a node detects an inconsistency, it may reset the interval of 1670 the trickle timer to a minimum value, causing RAs to be emitted 1671 more frequently as part of a strategy to quickly correct the 1672 inconsistency. Such inconsistencies may be, for example, an 1673 update to a key parameter (e.g. sequence number) in the DIO or a 1674 point-to-point loop detected when a node located inwards along the 1675 DAG forwards traffic intended for the default destination. 1676 Inconsistencies are further detailed in Section 5.2.3.2. 1678 o When a node enters a mode of consistent operation within a DAG, it 1679 may begin to open up the interval of the trickle timer towards a 1680 maximum value, causing RAs to be emitted less frequently, thus 1681 reducing network maintenance overhead and saving energy 1682 consumption (which is of utmost importance for battery-operated 1683 nodes). 1685 o When a node is initialized, it may choose to remain silent and not 1686 multicast any RAs until it has encountered and joined a DAG 1687 (perhaps initially probing for a nearby DAG with an RS). 1688 Alternately, it may choose to root its own floating DAG and begin 1689 multicasting RAs using a default trickle configuration. The 1690 second case may be advantageous if it is desired for independent 1691 nodes to begin aggregating into scattered floating DAGs in the 1692 absence of a grounded node, for example in support of LLN 1693 installation and commissioning. 1695 Note that if multiple DAG roots are participating in the same DAG, 1696 i.e. offering DIOs with the same DAGID, then they must coordinate 1697 with each other to ensure that their DIOs are consistent when they 1698 emit RA-DIOs. In particular the Sequence number must be identical 1699 from each DAG root, regardless of which of the multiple DAG roots 1700 issues the DIO, and changes to the Sequence number should be issued 1701 at the same time. The specific mechanism of this coordination is 1702 beyond the scope of this specification. 1704 5.2.3. Trickle Timer for RA Transmission 1706 RPL treats the construction of a DAG as a consistency problem, and 1707 uses a trickle timer [Levis08] to control the rate of control 1708 broadcasts. The operation of this timer is in support of the 1709 procedures further discussed in Section 5.3 1711 For each DAG that a node is part of, the node must maintain a single 1712 trickle timer. The required state contains the following conceptual 1713 items: 1715 I: The current length of the communication interval 1717 T: A timer with a duration set to a random value in the range 1718 [I/2, I] 1720 C: Redundancy Counter 1722 I_min: The smallest communication interval in milliseconds. This 1723 value is learned from the DIO as (2^DIOIntervalMin)ms. The 1724 default value is DEFAULT_DIO_INTERVAL_MIN. 1726 I_doublings: The number of times I_min should be doubled before 1727 maintaining a constant rate, i.e. I_max = I_min * 1728 2^I_doublings. This value is learned from the DIO as 1729 DIOIntervalDoublings. The default value is 1730 DEFAULT_DIO_INTERVAL_DOUBLINGS. 1732 5.2.3.1. Resetting the Trickle Timer 1734 The trickle timer for a DAGID is reset by: 1736 1. Setting I_min and I_doublings to the values learned from the RA- 1737 DIO. 1739 2. Setting C to zero. 1741 3. Setting I to I_min. 1743 4. Setting T to a random value as described above. 1745 5. Restarting the trickle timer to expire after a duration T 1747 When an LLN learns about a DAG through a RA and makes the decision to 1748 join it, it initializes the state of the trickle timer by resetting 1749 the trickle timer and listening. Each time it hears an RA for this 1750 DAG, it increments C. 1752 When the timer fires at time T, the node compares C to the redundancy 1753 constant, DEFAULT_DIO_REDUNDANCY_CONSTANT. If C is less than that 1754 value, the node generates a new RA and broadcasts it. When the 1755 communication interval I expires, the node doubles the interval I so 1756 long as it has previously doubled it fewer then I_doubling times, 1757 resets C, and chooses a new T value. 1759 5.2.3.2. Determination of Inconsistency 1761 The trickle timer is reset whenever an inconsistency is detected 1762 within the DAG, for example: 1764 o The node joins a new DAGID 1766 o The node moves within a DAGID 1768 o The node receives a modified DIO from a DAG parent 1770 o A DAG parent forwards a packet intended for the default route, 1771 indicating an inconsistency and possible loop. 1773 o A metric communicated in the DIO is determined to be inconsistent, 1774 as according to a implementation specific path metric selection 1775 engine. 1777 o The depth of a DAG parent has changed. 1779 5.3. DAG Discovery 1781 DAG Discovery is a form of distance vector protocol for use in LLNs. 1782 DAG Discovery locates the nearest sink and forms a Directed Acyclic 1783 Graph towards that sink, by identifying a set of DAG parents. During 1784 this process DAG Discovery also identifies siblings, which may be 1785 used later to provide additional path diversity towards the DAG root. 1786 DAG Discovery enables nodes to implement different policies for 1787 selecting their DAG parents in the DAG by using implementation 1788 specific policy functions. DAG Discovery specifies a set of rules to 1789 be followed by all implementations in order to ensure interoperation. 1790 DAG Discovery also standardizes the format that is used to advertise 1791 the most common information that is used in order to select DAG 1792 parents. 1794 One of these information, the DAG depth, is used by DAG Discovery to 1795 provide loop avoidance even if nodes implement different policies. 1796 The DAG Depth is computed as specified by the Objective Code Point in 1797 use by the DAG, demonstrating the properties described in 1798 Section 3.4.1. The depth should be computed in such a way so as to 1799 provide a comparable basis with other nodes which may not use the 1800 same metric at all. (The to-be-defined NULL OCP and related 1801 behaviors will clarify this point). 1803 In order to organize and maintain loopless structure, the DAG 1804 Discovery implementation in the nodes MUST obey to the following 1805 rules and definitions: 1807 1. A node that does not have any DAG parents in a DAG is the root 1808 of its own floating DAG. It's depth is 1. A node will end up 1809 in that situation when it looses all of its current feasible 1810 parents, i.e. the set of DAG parents becomes depleted. In that 1811 case, the node SHOULD remember the DAGID and the sequence 1812 counter in the DIO of the lost parents for a period of time 1813 which covers multiple DIO. 1815 2. A LLN Node that is attached to an infrastructure that does not 1816 support DIO, is the DAG root of its own grounded DAG. It's 1817 depth is 1. 1819 3. A router sending a RA without DIO is considered a grounded 1820 infrastructure at depth 0. (For example, a router that is in 1821 communication with an LLN node but not running RPL such as a 1822 backbone router in communication with an LBR) 1824 4. The DAG root exposes the DAG in the Router Advertisement DAG 1825 Information Option and nodes propagate the DIO outwards along 1826 the DAG with the RAs that they forward over their LLN links. 1828 5. A node MAY move at any time, with no delay, within its DAG as 1829 long as such a move does not increase its own DAG depth, as per 1830 the depth calculation indicated by the OCP. If a node is 1831 required to move such that it cannot stay within the DAG without 1832 a depth increase, then it needs to first leave the DAG. In 1833 other words a A node that is already part of a DAG MAY move or 1834 follow a DAG parent at any time and with no delay in order to be 1835 closer, or stay as close, to the DAG root of its current DAG as 1836 it already is. But a node MUST NOT move outwards along the DAG 1837 that it is attached, except in the special case when choosing to 1838 follow the last DAG parent in the set of DAG parents. RAs 1839 received from other routers located higher in the same DAG may 1840 be considered as coming from candidate parents. RAs received 1841 from other routers located at the same depth in the same DAG may 1842 be considered as coming from siblings. Nodes MUST ignore RAs 1843 that are received from other routers located deeper within the 1844 same DAG. 1846 6. A node may jump from its current DAG into any different DAG if 1847 it is preferred for reasons of connectivity, configured 1848 preference, free medium time, size, security, bandwidth, DAG 1849 depth, or whatever metrics the LLN cares to use. A node may 1850 jump at any time and to whatever depth it reaches in the new 1851 DAG, but it may have to wait for a DAG Hop timer to elapse in 1852 order to do so. This allows the new higher parts (closer to the 1853 sink) of the DAG to move first, thus allowing stepped DAG 1854 reconfigurations and limiting relative movements. A node SHOULD 1855 NOT join a previous DAG (identified by its DAGID) unless the 1856 sequence number in the DIO has incremented since the node left 1857 that DAG. A newer sequence number indicates that the candidate 1858 parents were not attached behind this node, as they kept getting 1859 subsequent DIOs with new sequence numbers from the same DAG. In 1860 the event that old sequence numbers (two or more behind the 1861 present value) are encountered they are considered stale and the 1862 corresponding parent SHOULD be removed from the set. 1864 7. If a node has selected a new set of DAG parents but has not 1865 moved yet (because it is waiting for DAG Hop timer to elapse), 1866 the node is unstable and refrains from sending Router 1867 Advertisement - DAG Information Options. 1869 8. If a node receives a Router Advertisement - DAG Information 1870 Option from one of its DAG parents, and if the parent contains a 1871 different DAGID, indicating that the parent has left the DAG, 1872 and if the node can remain in the current DAG through an 1873 alternate DAG parent, then the node should remove the DAG parent 1874 which has joined the new DAG from its DAG parent set and remain 1875 in the original DAG. If the node was the last DAG parent then 1876 the node SHOULD follow that parent. 1878 9. When a node detects or causes a DAG inconsistency, as described 1879 in Section 5.2.3.2, then the node sends an unsolicited Router 1880 Advertisement message to its one-hop neighbors. The RA contains 1881 a DIO that propagates the new DAG information. Such an event 1882 will also cause the trickle timer governing the periodic RAs to 1883 be reset. 1885 10. If a DAG parent increases its depth such that the node depth 1886 would have to change, and if the node does not wish to follow 1887 (e.g. it has alternate options), then the DAG parent should be 1888 evicted from the DAG parent set. If the DAG parent is the last 1889 in the DAG parent set, then the node may chose to follow it. 1891 5.3.1. DAG Selection 1893 The DAG selection is implementation and algorithm dependent. Nodes 1894 SHOULD prefer to join DAGs advertising OCPs compatible with their 1895 implementation specific objectives. In order to limit erratic 1896 movements, and all metrics being equal, nodes SHOULD keep their 1897 previous selection. Also, nodes SHOULD provide a means to filter out 1898 a candidate parent whose availability is detected as fluctuating, at 1899 least when more stable choices are available. Nodes MAY place the 1900 failed candidate parent in a Hold Down mode that ensures that the 1901 candidate parent will not be reused for a given period of time. 1903 The known DAGs are associated with the candidate parents that 1904 advertise them and kept in a list by extending the Default Router 1905 List (DRL). DRL entries are extended to store the information 1906 received from the last DIO. The DRL MAY need to be modified in order 1907 to keep track of membership to multiple DAGs simultaneously. The DRL 1908 entries are managed by states and timers described in the next 1909 section. 1911 When connection to a fixed network is not possible or preferable for 1912 security or other reasons, scattered DAGs MAY aggregate as much as 1913 possible into larger DAGs in order to allow connectivity within the 1914 LLN. How to balance these DAGs is implementation dependent, and MAY 1915 use a specific visitor-counter suboption in the DIO. 1917 A node SHOULD verify that bidirectional connectivity and adequate 1918 link quality is available with a candidate neighbor before it 1919 considers that candidate as a DAG parent. 1921 5.3.2. Administrative depth 1923 When the DAG is formed under a common administration, or when a node 1924 performs a certain role within a community, it might be beneficial to 1925 associate a range of acceptable depth with that node. For instance, 1926 a node that has limited battery should be a leaf unless there is no 1927 other choice, and may then augment the depth computation specified by 1928 the OCP in order to expose an exaggerated depth. 1930 5.3.3. DRL entries states and stability 1932 Candidate parents in the DRL may or may not be usable for forwarding 1933 traffic inward along the DAG toward the root depending on runtime 1934 conditions. The following states are defined: 1936 Current This candidate parent is in the set of DAG parents and 1937 may be used for forwarding traffic inward along the DAG. 1939 Held-Up This parent can not be used until the DAG hop timer 1940 elapses. 1942 Held-Down This candidate parent can not be used till hold down 1943 timer elapses. At the end of the hold-down period, the 1944 candidate is removed from the DRL, and may be reinserted 1945 if it appears again with a RA. 1947 Collision This candidate parent can not be used till its next RA. 1949 5.3.3.1. Held-Up 1951 This state is managed by the DAG Hop timer, it serves 2 purposes: 1953 Delay the reattachment of a sub-DAG that has been forced to 1954 detach. This is not as safe as the use of the sequence, but still 1955 covers that when a sub-DAG has detached, the Router Advertisement 1956 - DAG Information Option that is initiated by the new DAG root has 1957 a chance to spread outward along the sub-DAG so that two different 1958 DAGs have formed. 1960 Limit Router Advertisement - DAG Information Option storms when 1961 two DAGs collide/merge. The idea is that between the nodes from 1962 DAG A that decide to move to DAG B, those that see the highest 1963 place (closer to the DAG root) in DAG B will move first and 1964 advertise their new locations before other nodes from DAG A 1965 actually move. 1967 A new DAG is discovered upon a router advertisement message with or 1968 without a Router Advertisement - DAG Information Option. The node 1969 joins the DAG by selecting the source of the RA message as a DAG 1970 parent (and possible default gateway) and propagating the DIO 1971 accordingly. 1973 When a new DAG is discovered, the candidate parent that advertises 1974 the new DAG is placed in a held up state for the duration of a DAG 1975 Hop timer. If the resulting new set of DAG parents is more 1976 preferable than the current one, or if the node is intending to 1977 maintain a membership in the new DAG in addition to its current DAG, 1978 the node expects to jump and becomes unstable. 1980 A node that is unstable may discover other candidate parents from the 1981 same new DAG during the instability phase. It needs to start a new 1982 DAG Hop timer for all these. The first timer that elapses for a 1983 given new DAG clears them all for that DAG, allowing the node to jump 1984 to the highest position available in the new DAG. 1986 The duration of the DAG Hop timer depends on the DAG Delay of the new 1987 DAG and on the depth of candidate parent that triggers it: 1988 (candidates depth + random) * candidate's DAG_delay (where 0 <= 1989 random < 1). It is randomized in order to limit collisions and 1990 synchronizations. 1992 5.3.3.2. Held-Down 1994 When a neighboring node is 'removed' from the Default Router List, it 1995 is actually held down for a hold down timer period, in order to 1996 prevent flapping. This happens when a node disappears (upon 1997 expiration timer). 1999 An node that is held down is not considered for the purpose of 2000 forwarding traffic inward along the DAG toward the root. When the 2001 hold down timer elapses, the node is removed from the DRL. 2003 5.3.3.3. Collision 2005 A race condition occurs if 2 nodes send RA-DIO at the same time and 2006 then attempt to join each other. This might happen, for example, 2007 between nodes which act as DAG root of their own DAGs. In order to 2008 detect the situation, LLN Nodes time stamp the sending of RA-DIO. 2009 Any RA-DIO received within a short link-layer-dependent period 2010 introduces a risk. To resolve the collision, a 32bits extended 2011 preference is constructed from the DIO by concatenating the 2012 NodePreference with the BootTimeRandom. 2014 A node that decides to add a candidate to its DAG parents will do so 2015 between (candidate depth) and (candidate depth + 1) times the 2016 candidate DAG Delay. But since a node is unstable as soon as it 2017 receives the RA-DIO from the desired candidate, it will restrain from 2018 sending a RA-DIO between the time it receives the RA and the time it 2019 actually jumps. So the crossing of RA may only happen during the 2020 propagation time between the candidate and the node, plus some 2021 internal queuing and processing time within each machine. It is 2022 expected that one DAG delay normally covers that interval, but 2023 ultimately it is up to the implementation and the configuration of 2024 the candidate parent to define the duration of risk window. 2026 There is risk of a collision when a node receives an RA, for another 2027 candidate that is more preferable than the current candidate, within 2028 the risk window. In the face of a potential collision, the node with 2029 lowest extended preference processes the RA-DIO normally, while the 2030 router with the highest extended preference places the other in 2031 collision state, does not start the DAG hop timer, and does not 2032 become instable. It is expected that next RAs between the two will 2033 not cross anyway. 2035 5.3.3.4. Instability 2037 A node is instable when it is prepared to shortly replace a set of 2038 DAG parents in order to jump to a different DAGID. This happens 2039 typically when the node has selected a more preferred candidate 2040 parent in a different DAG and has to wait for the DAG hop timer to 2041 elapse before adjusting the DAG parent set. Instability may also 2042 occur when the entire current DAG parent set is lost and the next 2043 best candidates are still held up. Instability is resolved when the 2044 DAG hop timer of all the candidate(s) causing instability elapse. 2045 Such candidates then change state to Current or Held- Down. 2047 Instability is transient (in the order of DAG hop timers). When a 2048 node is unstable, it MUST NOT send RAs with DIO. This avoids loops 2049 when node A decides to attach to node B and node B decides to attach 2050 to node A. Unless RAs cross (see Collision section), a node receives 2051 DIO from stable candidate parents, which do not plan to attach to the 2052 node, so the node can safely attach to them. 2054 5.4. Establishing Routing State Outward Along the DAG 2056 The Destination Advertisement mechanism supports the dissemination of 2057 routing state required to support traffic flows outward along the 2058 DAG, from the DAG root toward nodes. 2060 Note that some aspects of the Destination Advertisement mechanism are 2061 still under investigation. 2063 As a result of Destination Advertisement operation: 2065 o DAG Discovery establishes a DAG oriented toward a DAG root using 2066 extended Neighbor Discovery RS/RA flows, along which inward routes 2067 toward the DAG root are set up. 2069 o Destination Advertisement extends Neighbor Discovery in order to 2070 establish outward routes along the DAG, along paths containing DA 2071 parents. Such paths consist of: 2072 * Hop-By-Hop routing state within islands of `stateful' nodes. 2073 * Source Routing `bridges' across nodes who do not retain state. 2075 Destinations disseminated with the Destination Advertisement 2076 mechanism may be prefixes, individual hosts, or multicast listeners. 2077 The mechanism supports nodes of varying capabilities as follows: 2079 o When nodes are capable of storing routing state, they may inspect 2080 Destination Advertisements and learn hop-by-hop routing state 2081 toward destinations. In this process they may also learn 2082 necessary piecewise source routes to traverse regions of the LLN 2083 that do not maintain routing state. They may perform route 2084 aggregation on known destinations before emitting Destination 2085 Advertisements. 2087 o When nodes are incapable of storing routing state, they may 2088 forward Destination Advertisements, recording the reverse route as 2089 the go in order to support the construction of piecewise source 2090 routes. 2092 Nodes that are capable of storing routing state, and finally the DAG 2093 roots, are able to learn which destinations are contained in the sub- 2094 DAG below the node, and via which next-hop neighbors. The 2095 dissemination and installation of this routing state into nodes 2096 allows for Hop-By-Hop routing from the DAG root outwards along the 2097 DAG. The mechanism is further enhance by supporting the construction 2098 of source routes across stateless `gaps' in the DAG, where nodes are 2099 incapable of storing additional routing state. An adaptation of this 2100 mechanism allows for the implementation of loose-source or landmark 2101 (waypoint) routing. 2103 The design choice behind this is not to synchronize the parent and 2104 children databases along the DAG, but instead to update them 2105 regularly to cover from the loss of packets. The rationale for that 2106 choice is time variations in connectivity across unreliable links. 2107 If the topology can be expected to change frequently, synchronization 2108 might be an excessive goal in terms of exchanges and protocol 2109 complexity. The approach used here results in a simple protocol with 2110 no real peering. The Destination Advertisement mechanism hence 2111 provides for periodic updates of the derivative routing state, as 2112 cued by occasional RAs and other mechanisms. 2114 5.4.1. Destination Advertisement Message Formats 2116 5.4.1.1. DAO Option 2118 RPL extends Neighbor Discovery [RFC4861] and RFC4191 [RFC4191] to 2119 allow a node to include a Destination Advertisement option, which 2120 includes prefix information, in the Neighbor Advertisements (NAs). A 2121 prefix option is normally present in Router Advertisements (RAs) 2122 only, but the NA is augmented with this option in order to propagate 2123 destination information inwards along the DAG. The option is named 2124 the Destination Advertisement Option (DAO), and an NA containing this 2125 option may be referred to as a Destination Advertisement. The RPL 2126 use of Destination Advertisements allows the nodes in the DAG to 2127 build up routing state for nodes contained in the sub-DAG in support 2128 of traffic flowing outward along the DAG. 2130 0 1 2 3 2131 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2132 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2133 | Type | Length | Prefix Length | RRCount | 2134 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2135 | DAO Lifetime | 2136 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2137 | Route Tag | 2138 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2139 | DAO Depth | Reserved | DAO Sequence | 2140 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2141 | Prefix (Variable Length) | 2142 . . 2143 . . 2144 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2145 | Reverse Route Stack (Variable Length) | 2146 . . 2147 . . 2148 +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+ 2150 Figure 10: Destination Advertisement Option (DAO) 2152 Type: 8-bit unsigned identifying the Destination Advertisement 2153 option. The value is to be assigned by the IANA. 2155 Length: 8-bit unsigned integer. The length of the option (including 2156 the Type and Length fields) in units of 8 octets. 2158 Prefix Length: Number of valid leading bits in the IPv6 Prefix. 2160 RRCount: 8-bit unsigned integer. This counter is used to count the 2161 number of entries in the Reverse Route Stack. A value of `0' 2162 indicates that no Reverse Route Stack is present. 2164 DAO Lifetime: 32-bit unsigned integer. The length of time in 2165 seconds (relative to the time the packet is sent) that the 2166 prefix is valid for route determination. A value of all one 2167 bits (0xFFFFFFFF) represents infinity. A value of all zero 2168 bits (0x00000000) indicates a loss of reachability. 2170 Route Tag: 32-bit unsigned integer. The Route Tag may be used to 2171 give a priority to prefixes that should be stored. This may be 2172 useful in cases where intermediate nodes are capable of storing 2173 a limited amount of routing state. The further specification 2174 of this field and its use is under investigation. 2176 DAO Depth: Set to 0 by the node that owns the prefix and first 2177 issues the DAO. Incremented by all LLN nodes that propagate 2178 the DAO. 2180 Reserved: 8-bit unused field. It MUST be initialized to zero by the 2181 sender and MUST be ignored by the receiver. 2183 DAO Sequence: Incremented by the node that owns the prefix for each 2184 new DAO for that prefix. 2186 Prefix: Variable-length field containing an IPv6 address or a prefix 2187 of an IPv6 address. The Prefix Length field contains the 2188 number of valid leading bits in the prefix. The bits in the 2189 prefix after the prefix length (if any) are reserved and MUST 2190 be initialized to zero by the sender and ignored by the 2191 receiver. 2193 Reverse Route Stack: Variable-length field containing a sequence of 2194 RRCount (possibly compressed) IPv6 addresses. A node who adds 2195 on to the Reverse Route Stack will append to the list and 2196 increment the RRCount. 2198 5.4.2. Destination Advertisement Operation 2200 5.4.2.1. Overview 2202 Note that some aspects of the Destination Advertisement mechanism are 2203 still under investigation 2205 According to implementation specific policy, a subset or all of the 2206 feasible parents in the DAG may be selected to receive prefix 2207 information from the Destination Advertisement mechanism. This 2208 subset of DAG parents shall be designated the set of DA parents. 2210 RPL takes advantage of the DAG structure and allows a node capable of 2211 storing sufficient routing state to autonomously discover the 2212 destinations below itself through the operation of the Destination 2213 Advertisement mechanism. This allows participating nodes to build up 2214 routing state to support traffic flowing outwards along the DAG. 2215 Destination Advertisement messages convey the necessary information 2216 to learn the destinations. 2218 As Destination Advertisements for particular destinations move 2219 inwards along the DAG, a sequence counter is used to guarantee their 2220 freshness. The sequence counter is incremented by the source of the 2221 DAO (the node that owns the prefix), each time it issues a DAO for 2222 its prefix. Nodes who receive the DAO and, if scope allows, will be 2223 forwarding a DAO for the unmodified destination inwards along the 2224 DAG, will leave the sequence number unchanged. Intermediate nodes 2225 will check the sequence counter before processing a DAO, and if the 2226 DAO is unchanged (the sequence counter has not changed), then the DAO 2227 will be discarded without additional processing. Further, if the DAO 2228 appears to be out of synch (the sequence counter is 2 or more behind 2229 the present value) then the DAO state is considered to be stale and 2230 may be purged, and the DAO is discarded. A depth is also added for 2231 tracking purposes; the depth is incremented at each hop as the DAO is 2232 propagated up the DAG. Nodes who are storing routing state may use 2233 the depth to determine which possible next-hops for the destination 2234 are more optimal. 2236 If Destination Advertisements are activated in the DIO as indicated 2237 by the `D' bit, the node sends unicast Destination Advertisements to 2238 its DA parents, and only accepts unicast Destination Advertisements 2239 from any nodes BUT those contained in the DA parent subset. 2241 Every NA to a DA parent MAY contain one or more DAOs. Receiving a 2242 DAG Discovery RA-DIO with the `D' Destination Advertisement bit set 2243 from a DAG parent stimulates the sending of a delayed Destination 2244 Advertisement back, with the collection of all known prefixes (that 2245 is the prefixes learned via Destination Advertisements for nodes 2246 lower in the DAG, and any connected prefixes). A Destination 2247 Advertisement is also sent to a DAG parent once it has been added to 2248 the DA parent set after a movement, or when the list of advertised 2249 prefixes has changed. Destination Advertisements may also be 2250 scheduled for sending when the PathDigest of the DIO has changed, 2251 indicating that some aspect of the inwards paths along the DAG has 2252 been modified. 2254 Destination Advertisements may advertise positive (prefix is present) 2255 or negative (removed) DAOs. A no-DAO is stimulated by the 2256 disappearance of a prefix below. This is discovered by timing out 2257 after a request (a RA-DIO) or by receiving a no-DAO. A no-DAO is a 2258 conveyed as a DAO with a DAO Lifetime of 0. 2260 A node who is capable of recording the state information conveyed in 2261 a DAO will do so upon receiving and processing the DAO, thus building 2262 up routing state concerning destinations below it in the DAG. If a 2263 node capable of recording state information receives a DAO containing 2264 a Reverse Route Stack, then the node knows that the DAO has traversed 2265 one or more nodes that did not retain any routing state as it 2266 traversed the path from the DAO source to the node. The node may 2267 then extract the Reverse Route Stack and retain the included state in 2268 order to specify Source Routing instructions along the return path 2269 towards the destination. The node MUST set the RRCount back to zero 2270 and clear the Reverse Route Stack prior to passing the DAO 2271 information on. 2273 A node who is unable to record the state information conveyed in the 2274 DAO will append the next-hop address to the Reverse Route Stack, 2275 increment the RRCount, and then pass the Destination Advertisement on 2276 without recording any additional state. In this way the Reverse 2277 Route Stack will come to contain a vector of next hops that must be 2278 traversed along the reverse path that the DAO has traveled. The 2279 vector will be ordered such that the node closest to the destination 2280 will appear first in the list. In such cases the node may choose to 2281 convey the Destination Advertisement to one or more DAG Parents in 2282 order of preference as guided by an implementation specific policy. 2284 In hybrid cases, some nodes along the path a Destination 2285 Advertisement follows inward along the DAG may store state and some 2286 may not. The Destination Advertisement mechanism allows for the 2287 provisioning of routing state such that when a packet is traversing 2288 outwards along the DAG, some nodes may be able to directly forward to 2289 the next hop, and other nodes may be able to specify a piecewise 2290 source route in order to bridge spans of stateless nodes within the 2291 path on the way to the desired destination. 2293 In the degenerate case, no node is able to store any routing state as 2294 Destination Advertisements pass by, and the DAG sink ends up with 2295 DAOs that contain a completely specified route back to the 2296 originating node in the form of the inverted Reverse Route Stack. 2298 Information learned through Destination Advertisements can be 2299 redistributed in a routing protocol, MANET or IGP. But the MANET or 2300 the IGP SHOULD NOT be redistributed into Destination Advertisements. 2301 This creates a hierarchy of routing protocols where DA routes stand 2302 somewhere between connected and IGP routes. 2304 The Destination Advertisement mechanism requires stateful nodes to 2305 maintain lists of known prefixes. A prefix entry contains the 2306 following abstract information: 2308 o A reference to the ND entry that was created for the advertising 2309 neighbor. 2311 o The IPv6 address and interface for the advertising neighbor. 2313 o The logical equivalent of the full Destination Advertisement 2314 information (including the prefixes, depth, and Reverse Route 2315 Stack, if any). 2317 o A 'reported' Boolean to keep track whether this prefix was 2318 reported already, and to which of the DA parents. 2320 o A counter of retries to count how many RA-DIOs were sent on the 2321 interface to the advertising neighbor without reachability 2322 confirmation for the prefix. 2324 Note that nodes may receive multiple information from different 2325 neighbors for a specific destination, as different paths through the 2326 DAG may be propagating information inwards along the DAG for the same 2327 destination. A node who is recording routing state will keep track 2328 of the information from each neighbor independently, and when it 2329 comes time to propagate the DAO for a particular prefix to the DA 2330 parents, then the DAO information will be selected from among the 2331 advertising neighbors who offer the least depth to the destination. 2333 The Destination Advertisement mechanism stores the prefix entries in 2334 one of 3 abstract lists; the Connected, the Reachable and the 2335 Unreachable lists. 2337 The Connected list corresponds to the prefixes owned and managed by 2338 the local node. 2340 The Reachable list contains prefixes for which the node keeps 2341 receiving DAOs, and for those prefixes which have not yet timed out. 2343 The Unreachable list keeps track of prefixes which are no longer 2344 valid and in the process of being destroyed, in order to send no-DAOs 2345 to the DA parents. 2347 The Destination Advertisement mechanism requires 2 timers; the 2348 DelayNA timer and the DestroyTimer. 2350 o The DelayNA timer is armed upon a stimulation to send a 2351 Destination Advertisement (such as a DIO from a DA parent). When 2352 the timer is armed, all entries in the Reachable list as well as 2353 all entries for Connected list are set to not reported yet for 2354 that particular DA parent. 2356 o The DelayNA timer has a duration that is DEF_NA_LATENCY divided by 2357 a multiple of the DAG depth. The intention is that nodes located 2358 deeper in the DAG should have a shorter DelayNA timer, allowing 2359 DAOs a chance to be reported from deeper in the DAG and 2360 potentially aggregated by sub-DAGs before propagating further 2361 inwards. 2363 o The DestroyTimer is armed when at least one entry has exhausted 2364 its retries, which means that a number of RA-DIO were sent toward 2365 the reporting neighbor but that the entry was not confirmed with a 2366 DAO. When the destroy timer elapses, for all exhausted entries, 2367 the associated route is removed, and the entry is scheduled to be 2368 destroyed. 2370 o The Destroy timer has a duration of min (MAX_DESTROY_INTERVAL, 2371 RA_INTERVAL). 2373 5.4.2.2. Unicast Destination Advertisement messages from child to 2374 parent 2376 When sending a Destination Advertisement to a DA parent, a LLN Node 2377 includes the DAOs about not already reported prefix entries in the 2378 Reachable and Connected lists, as well as no-DAOs for all the entries 2379 in the Unreachable list. Depending on its policy and ability to 2380 retain routing state, the receiving node SHOULD keep a record of the 2381 reported DAO. If the DAO offers the best route to the prefix as 2382 determined by policy and other prefix records, the node SHOULD 2383 install a route to the prefix in the DAO via the link local address 2384 of the reporting neighbor and it SHOULD further propagate the 2385 information, either as a DAO or by means of redistribution into a 2386 routing protocol. 2388 The RA-DIO from the DAG root is used to synchronize the whole DAG, 2389 including the periodic reporting of Destination Advertisements back 2390 up the DAG. Its period is expected to vary, depending on the 2391 configuration of the trickle timer that governs the RAs. 2393 When a node receives a RA-DIO over an LLN interface from a DA parent, 2394 the DelayNA is armed to force a full update. 2396 When the node broadcasts a RA-DIO on an LLN interface, for all 2397 entries on that interface: 2399 o If the entry is CONFIRMED, it goes PENDING with the retry count 2400 set to 0. 2402 o If the entry is PENDING, the retry count is incremented. If it 2403 reaches a maximum threshold, the entry goes ELAPSED If at least 2404 one entry is ELAPSED at the end of the process: if the Destroy 2405 timer is not running then it is armed with a jitter. 2407 Since the DelayNA has a duration that decreases with the depth, it is 2408 expected to receive all DAOs from all children before the timer 2409 elapses and the full update is sent to the DA parents. 2411 Once the Destroy timer is elapsed, the prefix entry is scheduled to 2412 be destroyed and moved to the Unreachable list if there are any DA 2413 parents that need to be informed of the change in status for the 2414 prefix, otherwise the prefix entry is cleaned up right away. The 2415 prefix entry is removed from the Unreachable list when no more DA 2416 parents need to be informed. This condition may be satisfied when a 2417 no-DAO is sent to all current DA parents indicating the loss of the 2418 prefix, and noting that in some cases parents may have been removed 2419 from the set of DA parents. 2421 5.4.2.3. Other events 2423 Finally, the Destination Advertisement mechanism responds to a series 2424 of events, such as: 2426 o Destination Advertisement operation stopped: All entries in the 2427 abstract lists are freed. All the routes learned from DAOs are 2428 destroyed. 2430 o Interface going down: for all entries in the Reachable list on 2431 that interface, the associated route is removed, and the entry is 2432 scheduled to be destroyed. 2434 o Loss of routing adjacency: When the routing adjacency for a 2435 neighbor is lost, as per the procedures described in Section 5.5, 2436 and if the associated entries are in the Reachable list, the 2437 associated routes are removed, and the entries are scheduled to be 2438 destroyed. 2440 o Changes to DA parent set: All entries in the Reachable list are 2441 set to not 'reported' and DelayNA is armed. 2443 5.4.2.4. Aggregation of prefixes by a node 2445 There may be number of cases where a aggregation may be shared within 2446 a platoon of nodes. In such a case, it is possible to use 2447 aggregation techniques with Destination Advertisements and improve 2448 scalability. For example, consider a platoon formed by firefighters 2449 and their commander. Specifically, the commander may be configured 2450 as the Destination Advertisement aggregator for a group prefix. At 2451 run time, the commander absorbs the individual DAO information 2452 received from the platoon members down its sub-DAG and only reports 2453 the aggregation up the DAG. This works fine when the whole platoon 2454 is attached within the commander's sub-DAG. 2456 Other cases might occur for which additional support is required: 2458 1. The commander is attached within the sub-DAG of one of its 2459 platoon members. 2461 2. A platoon member is somewhere else within the DAG. 2463 3. A platoon member is somewhere else in the LLN. 2465 In all those cases, a node situated above the commander in the DAG 2466 but not above the platoon member will see the advertisements for the 2467 aggregation owned by the commander but not that of the individual 2468 platoon member prefix. So it will route all the packets for the 2469 platoon member towards the commander, but the commander will have no 2470 route to the individual platoon member and will fail to forward. 2472 Additional protocols may be applied beyond the scope of this 2473 specification to dynamically elect/provision a commander and platoon 2474 in order to provide route summarization for a sub-DAG. 2476 5.4.2.5. Default Values 2478 DEF_NA_LATENCY = To Be Determined 2480 MAX_DESTROY_INTERVAL = To Be Determined 2482 5.5. Maintenance of Routing Adjacency 2484 The selection of successors, along the default paths inward along the 2485 DAG, or along the paths learned from Destination Advertisements 2486 outward along the DAG, leads to the formation of routing adjacencies 2487 that require maintenance. 2489 In IGPs such as OSPF [RFC4915] or IS-IS [RFC5120], the maintenance of 2490 a routing adjacency involves the use of Keepalive mechanisms (Hellos) 2491 or other protocols such as BFD ([I-D.ietf-bfd-base]) and MANET 2492 Neighborhood Discovery Protocol (NHDP [I-D.ietf-manet-nhdp]). 2493 Unfortunately, such an approach is not desirable in constrained 2494 environments such as LLN and would lead to excessive control traffic 2495 in light of the data traffic with a negative impact on both link 2496 loads and nodes resources. Overhead to maintain the routing 2497 adjacency should be minimized. Furthermore, it is not always 2498 possible to rely on the link or transport layer to provide 2499 information of the associated link state. The network layer needs to 2500 fall back on its own mechanism. 2502 Thus RPL makes use of a different approach consisting of probing the 2503 neighbor using a Neighbor Solicitation message (see [RFC4861]). The 2504 reception of a Neighbor Advertisement (NA) message with the 2505 "Solicited Flag" set is used to verify the validity of the routing 2506 adjacency. Such mechanism MAY be used prior to sending a data 2507 packet. This allows for detecting whether or not the routing 2508 adjacency is still valid, and should it not be the case, select 2509 another feasible successor to forward the packet. 2511 5.6. Expectations of Link Layer Behavior 2513 This specification does not rely on any particular features of a 2514 specific link layer technologies. It is anticipated that an 2515 implementer should be able to operate RPL over a variety of different 2516 low power wireless or PLC (Power Line Communication) link layer 2517 technologies. 2519 Implementers may find RFC 3819 [RFC3819] a useful reference when 2520 designing a link layer interface between RPL and a particular link 2521 layer technology. 2523 6. Protocol Extensions 2525 7. Manageability Considerations 2527 8. Security Considerations 2529 9. IANA Considerations 2531 9.1. DAG Information Option 2533 IANA is requested to allocate a new Neighbor Discovery Option Type 2534 from the IPv6 Neighbor Discovery Option Formats Registry in order to 2535 represent the DAG Information Option as described in Section 5.1 2537 9.2. Destination Advertisement Option 2539 IANA is requested to allocate a new Neighbor Discovery Option Type 2540 from the IPv6 Neighbor Discovery Option Formats Registry in order to 2541 represent the Destination Advertisement Option as described in 2542 Section 5.4.1.1 2544 10. Acknowledgements 2546 The ROLL Design Team would like to acknowledge the review, feedback, 2547 and comments from Dominique Barthel, Yusuf Bashir, Mathilde Durvy, 2548 Manhar Goindi, Mukul Goyal, Richard Kelsey, Quentin Lampin, Philip 2549 Levis, Jerry Martocci, Alexandru Petrescu, and Don Sturek. 2551 The ROLL Design Team would like to acknowledge the guidance and input 2552 provided by the ROLL Chairs, David Culler and JP Vasseur. 2554 The ROLL Design Team would like to acknowledge prior contributions of 2555 Richard Kelsey, Robert Assimiti, Mischa Dohler, Julien Abeille, Ryuji 2556 Wakikawa, Teco Boot, Patrick Wetterwald, Bryan Mclaughlin, Carlos J. 2557 Bernardos, Thomas Watteyne, Zach Shelby, Dominique Barthel, Caroline 2558 Bontoux, Marco Molteni, Billy Moon, and Arsalan Tavakoli, which have 2559 provided useful design considerations to RPL. 2561 11. Contributors 2563 ROLL Design Team in alphabetical order: 2565 Anders Brandt 2566 Zensys, Inc. 2567 Emdrupvej 26 2568 Copenhagen, DK-2100 2569 Denmark 2571 Email: abr@zen-sys.com 2573 Thomas Heide Clausen 2574 LIX, Ecole Polytechnique, France 2576 Phone: +33 6 6058 9349 2577 EMail: T.Clausen@computer.org 2578 URI: http://www.ThomasClausen.org/ 2580 Stephen Dawson-Haggerty 2581 UC Berkeley 2582 Soda Hall, UC Berkeley 2583 Berkeley, CA 94720 2584 USA 2586 Email: stevedh@cs.berkeley.edu 2588 Jonathan W. Hui 2589 Arch Rock Corporation 2590 501 2nd St. Ste. 410 2591 San Francisco, CA 94107 2592 USA 2594 Email: jhui@archrock.com 2596 Kris Pister 2597 Dust Networks 2598 30695 Huntwood Ave. 2599 Hayward, 94544 2600 USA 2602 Email: kpister@dustnetworks.com 2604 Pascal Thubert 2605 Cisco Systems 2606 Village d'Entreprises Green Side 2607 400, Avenue de Roumanille 2608 Batiment T3 2609 Biot - Sophia Antipolis 06410 2610 FRANCE 2612 Phone: +33 497 23 26 34 2613 Email: pthubert@cisco.com 2615 Tim Winter (editor) 2617 wintert@acm.org 2619 12. References 2621 12.1. Normative References 2623 [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate 2624 Requirement Levels", BCP 14, RFC 2119, March 1997. 2626 12.2. Informative References 2628 [I-D.ietf-bfd-base] 2629 Katz, D. and D. Ward, "Bidirectional Forwarding 2630 Detection", draft-ietf-bfd-base-09 (work in progress), 2631 February 2009. 2633 [I-D.ietf-manet-nhdp] 2634 Clausen, T., Dearlove, C., and J. Dean, "MANET 2635 Neighborhood Discovery Protocol (NHDP)", 2636 draft-ietf-manet-nhdp-10 (work in progress), July 2009. 2638 [I-D.ietf-roll-building-routing-reqs] 2639 Martocci, J., Riou, N., Mil, P., and W. Vermeylen, 2640 "Building Automation Routing Requirements in Low Power and 2641 Lossy Networks", draft-ietf-roll-building-routing-reqs-05 2642 (work in progress), February 2009. 2644 [I-D.ietf-roll-home-routing-reqs] 2645 Porcu, G., "Home Automation Routing Requirements in Low 2646 Power and Lossy Networks", 2647 draft-ietf-roll-home-routing-reqs-06 (work in progress), 2648 November 2008. 2650 [I-D.ietf-roll-indus-routing-reqs] 2651 Networks, D., Thubert, P., Dwars, S., and T. Phinney, 2652 "Industrial Routing Requirements in Low Power and Lossy 2653 Networks", draft-ietf-roll-indus-routing-reqs-06 (work in 2654 progress), June 2009. 2656 [I-D.ietf-roll-routing-metrics] 2657 Vasseur, J. and D. Networks, "Routing Metrics used for 2658 Path Calculation in Low Power and Lossy Networks", 2659 draft-ietf-roll-routing-metrics-00 (work in progress), 2660 April 2009. 2662 [I-D.ietf-roll-terminology] 2663 Vasseur, J., "Terminology in Low power And Lossy 2664 Networks", draft-ietf-roll-terminology-01 (work in 2665 progress), May 2009. 2667 [I-D.tavakoli-hydro] 2668 Tavakoli, A., Dawson-Haggerty, S., Hui, J., and D. Culler, 2669 "HYDRO: A Hybrid Routing Protocol for Lossy and Low Power 2670 Networks", draft-tavakoli-hydro-01 (work in progress), 2671 March 2009. 2673 [I-D.thubert-roll-fundamentals] 2674 Thubert, P., Watteyne, T., Shelby, Z., and D. Barthel, 2675 "LLN Routing Fundamentals", 2676 draft-thubert-roll-fundamentals-01 (work in progress), 2677 April 2009. 2679 [I-D.tsao-roll-security-framework] 2680 Tsao, T., Alexander, R., Dohler, M., Daza, V., and A. 2681 Lozano, "A Security Framework for Routing over Low Power 2682 and Lossy Networks", draft-tsao-roll-security-framework-00 2683 (work in progress), February 2009. 2685 [Levis08] Levis, P., Brewer, E., Culler, D., Gay, D., Madden, S., 2686 Patel, N., Polastre, J., Shenker, S., Szewczyk, R., and A. 2687 Woo, "The Emergence of a Networking Primitive in Wireless 2688 Sensor Networks", Communications of the ACM, v.51 n.7, 2689 July 2008, 2690 . 2692 [RFC3819] Karn, P., Bormann, C., Fairhurst, G., Grossman, D., 2693 Ludwig, R., Mahdavi, J., Montenegro, G., Touch, J., and L. 2694 Wood, "Advice for Internet Subnetwork Designers", BCP 89, 2695 RFC 3819, July 2004. 2697 [RFC4101] Rescorla, E. and IAB, "Writing Protocol Models", RFC 4101, 2698 June 2005. 2700 [RFC4191] Draves, R. and D. Thaler, "Default Router Preferences and 2701 More-Specific Routes", RFC 4191, November 2005. 2703 [RFC4461] Yasukawa, S., "Signaling Requirements for Point-to- 2704 Multipoint Traffic-Engineered MPLS Label Switched Paths 2705 (LSPs)", RFC 4461, April 2006. 2707 [RFC4861] Narten, T., Nordmark, E., Simpson, W., and H. Soliman, 2708 "Neighbor Discovery for IP version 6 (IPv6)", RFC 4861, 2709 September 2007. 2711 [RFC4875] Aggarwal, R., Papadimitriou, D., and S. Yasukawa, 2712 "Extensions to Resource Reservation Protocol - Traffic 2713 Engineering (RSVP-TE) for Point-to-Multipoint TE Label 2714 Switched Paths (LSPs)", RFC 4875, May 2007. 2716 [RFC4915] Psenak, P., Mirtorabi, S., Roy, A., Nguyen, L., and P. 2717 Pillay-Esnault, "Multi-Topology (MT) Routing in OSPF", 2718 RFC 4915, June 2007. 2720 [RFC5120] Przygienda, T., Shen, N., and N. Sheth, "M-ISIS: Multi 2721 Topology (MT) Routing in Intermediate System to 2722 Intermediate Systems (IS-ISs)", RFC 5120, February 2008. 2724 [RFC5548] Dohler, M., Watteyne, T., Winter, T., and D. Barthel, 2725 "Routing Requirements for Urban Low-Power and Lossy 2726 Networks", RFC 5548, May 2009. 2728 Appendix A. Deferred Requirements 2730 NOTE: RPL is still a work in progress. At this time there remain 2731 many unsatisfied application requirements, but these are to be 2732 addressed as RPL is further specified. 2734 Appendix B. Examples 2736 Consider the example LLN physical topology in Figure 11. In this 2737 example the links depicted are all usable L2 links. Suppose that all 2738 links are equally usable, and that the implementation specific policy 2739 function is simply to minimize hops. This LLN physical topology then 2740 yields the DAG depicted in Figure 12, where the links depicted are 2741 the edges toward DAG parents. This topology includes one DAG, rooted 2742 by an LBR node (LBR) at depth 1. The LBR node will issue RAs 2743 containing DIO, as governed by a trickle timer. Nodes (11), (12), 2744 (13), have selected (LBR) as their only parent, attached to the DAG 2745 at depth 2, and periodically advertise RA-DIO multicasts. Node (22) 2746 has selected (11) and (12) in its DAG parent set, and advertises 2747 itself at depth 3. Node (22) thus has a set of DAG parents {(11), 2748 (12)} and siblings {((21), (23)}. 2750 (LBR) 2751 / | \ 2752 .---` | `----. 2753 / | \ 2754 (11)------(12)------(13) 2755 | \ | \ | \ 2756 | `----. | `----. | `----. 2757 | \| \| \ 2758 (21)------(22)------(23) (24) 2759 | /| /| | 2760 | .----` | .----` | | 2761 | / | / | | 2762 (31)------(32)------(33)------(34) 2763 | /| \ | \ | \ 2764 | .----` | `----. | `----. | `----. 2765 | / | \| \| \ 2766 .--------(41) (42) (43)------(44)------(45) 2767 / / /| \ | \ 2768 .----` .----` .----` | `----. | `----. 2769 / / / | \| \ 2770 (51)------(52)------(53)------(54)------(55)------(56) 2772 Note that the links depicted represent the usable L2 connectivity 2773 available in the LLN. For example, Node (31) can communicate 2774 directly with its neighbors, Nodes (21), (22), (32), and (41). Node 2775 (31) cannot communicate directly with any other nodes, e.g. (33), 2776 (23), (42). In this example these links offer bidirectional 2777 communication, and `bad' links are not depicted. 2779 Figure 11: Example LLN Topology 2780 (LBR) 2781 / | \ 2782 .---` | `----. 2783 / | \ 2784 (11) (12) (13) 2785 | \ | \ | \ 2786 | `----. | `----. | `----. 2787 | \| \| \ 2788 (21) (22) (23) (24) 2789 | /| /| | 2790 | .----` | .----` | | 2791 | / | / | | 2792 (31) (32) (33) (34) 2793 | /| \ | \ | \ 2794 | .----` | `----. | `----. | `----. 2795 | / | \| \| \ 2796 .--------(41) (42) (43) (44) (45) 2797 / / /| \ | \ 2798 .----` .----` .----` | `----. | `----. 2799 / / / | \| \ 2800 (51) (52) (53) (54) (55) (56) 2802 Note that the links depicted represent directed links in the DAG 2803 overlaid on top of the physical topology depicted in Figure 11. As 2804 such, the depicted edges represent the relationship between nodes and 2805 their DAG parents, wherein all depicted edges are directed and 2806 oriented `up' on the page toward the DAG root (LBR). The DAG 2807 provides the default routes within the LLN, and serves as the 2808 foundation on which RPL builds further routing structure, e.g. 2809 through the Destination Advertisement mechanism. 2811 Figure 12: Example DAG 2813 B.1. Moving Down a DAG 2815 Consider node (56) in the example of Figure 11. In the unmodified 2816 example, node (56) is at depth 6 with one DAG parent, {(43)}, and one 2817 sibling (55). Suppose, for example, that node (56) wished to expand 2818 its DAG parent set to contain node (55), as {(43), (55)}. Such a 2819 change would require node (56) to detach from the DAG, to defer 2820 reattachment until a loop avoidance algorithm has completed, and to 2821 then reattach to the DAG with {(43), (55)} as it's DAG parents. When 2822 node (56) detaches from the DAG, it is able to act as the root of its 2823 own floating DAG and establish its frozen sub-DAG (which is empty). 2824 Node (56) can then observe that Node (55) is still attached to the 2825 original DAG, that its sequence number is able to increment, and 2826 deduce that Node (55) is safely not behind Node (56). There is then 2827 little change for a loop, and Node (56) may safely reattach to the 2828 DAG, with parents {(43), (55)}. At reattachment time, node (56) 2829 would present itself with a depth deeper than that of its deepest DAG 2830 parent (node (55) at depth 6), depth 7. 2832 B.2. Link Removed 2834 Consider the example of Figure 11 when link (13)-(24) goes down. 2836 o Node (24) will detach and become the root of its own floating DAG 2838 o Node (34) will learn that its DAG parent is now part of its own 2839 floating DAG, will consider that it can remain a part of the DAG 2840 rooted at node (LBR) via node (33), and will initiate procedures 2841 to detach from DAG (LBR) in order to re-attach at a lower depth. 2843 o Node (45) will similarly make preparations to remain attached to 2844 the DAG rooted at (LBR) by detaching from Node (34) and re- 2845 attaching at a lower depth to node (44). 2847 o Node (34) will complete re-attachment to Node (33) first, since it 2848 is able to attach closer to the root of the DAG. 2850 o Node (45) will cancel plans to detach/reattach, keep node (34) as 2851 a DAG parent, and update its dependent depth accordingly. 2853 o Node (45) may now anyway add node (44) to its set of DAG parents, 2854 as such an addition does not require any modification to its own 2855 depth. 2857 o Node (24) will observe that it may reattach to the DAG rooted at 2858 node (LBR) by selecting node (34) as its DAG parent, thus 2859 reversing the relationship that existed in the initial state. 2861 B.3. Link Added 2863 Consider the example of Figure 11 when link (12)-(42) appears. 2865 o Node (42) will see a chance to get closer to the LBR by adding 2866 (12) to its set of DAG parents, {(32), (12)} 2868 o Node (42) may be content to leave its advertised depth at 5, 2869 reflecting a depth deeper than its deepest parent (32). 2871 o Node (42) may now choose to remain where it is, with two parents 2872 {(12), (32)}. Should there be a reason for Node (42) to evict 2873 Node (32) from its set of DAG parents, Node (42) would then 2874 advertise itself at depth 2, thus moving up the DAG. In this 2875 case, Node (53), (54), and (55) may similarly follow and advertise 2876 themselves at depth 3. 2878 B.4. Node Removed 2880 Consider the example of Figure 11 when node (41) disappears. 2882 o Node (51) and (52) will now have empty DAG parent sets and be 2883 detached from the DAG rooted by (LBR), advertising themselves as 2884 the root of their own floating DAGs. 2886 o Node (52) would observe a chance to reattach to the DAG rooted at 2887 (LBR) by adding Node (53) to its set of DAG parents, after an 2888 appropriate delay to avoid creating loops. Node (52) will then 2889 advertise itself in the DAG rooted at (LBR) at depth 7. 2891 o Node (51) will then be able to reattach to the DAG rooted at (LBR) 2892 by adding Node (52) to its set of DAG parents and advertising 2893 itself at depth 8. 2895 B.5. New LBR Added 2897 Consider the example of Figure 11 when a new LBR, (LBR2) appears, 2898 with connectivity (LBR2)-(52), (LBR2)-(53). 2900 o Nodes (52) and Node (53) will see a chance to join a new DAG 2901 rooted at (LBR2) with a depth of 2. Node (52) and (53) may take 2902 this chance immediately, as there is no risk of forming loops when 2903 joining a DAG that has never before been encountered. Note that 2904 the nodes may choose to join the new DAG rooted at (LBR2) if and 2905 only if (LBR2) offers more optimum properties in line with the 2906 implementation specific local policy. 2908 o Nodes (52) and (53) begin to send RA-DIO advertising themselves at 2909 depth 2 in the DAGID (LBR2). 2911 o Nodes (51), (41), (42), and (54) may then choose to join the new 2912 DAG at depth 3, possibly to get closer to the DAG root. Note that 2913 in a more advanced case, these nodes also remain members of the 2914 DAG rooted at (LBR), for example in support of different 2915 constraints for different types of traffic. 2917 o Node (55) may then join the new DAG at depth 4, possibly to get 2918 closer to the DAG root. 2920 o The remaining nodes may choose to remain in their current 2921 positions within the DAG rooted at node (LBR), since there is no 2922 clear advantage to be gained by moving to DAG (LBR2). 2924 B.6. Destination Advertisement 2926 Consider the example DAG depicted in Figure 12. Suppose that Nodes 2927 (22) and (32) are unable to record routing state. Suppose that Node 2928 (42) is able to perform prefix aggregation on behalf of Nodes (53), 2929 (54), and (55). 2931 o Node (53) would send a DAO to Node (42), indicating the 2932 availability of destination (53). 2934 o Node (54) and Node (55) would similarly send DAOs to Node (42) 2935 indicating their own destinations. 2937 o Node (42) would collect and store the routing state for 2938 destinations (53), (54), and (55). 2940 o In this example, Node (42) may then be capable of representing 2941 destinations (42), (53), (54), and (55) in the aggregation (42'). 2943 o Node (42) sends a DAO advertising destination (42') to Node 32. 2945 o Node (32) does not want to maintain any routing state, so it adds 2946 onto to the Reverse Route Stack in the DAO and passes it on to 2947 Node (22) as (42'):[(42)]. It may send a separate DAO to indicate 2948 destination (32). 2950 o Node (22) does not want to maintain any routing state, so it adds 2951 on to the Reverse Route Stack in the DAO and passes it on to Node 2952 (12) as (42'):[(42), (32)]. It also relays the DAO containing 2953 destination (32) to Node 12 as (32):[(32)], and finally may send a 2954 DAO for itself indicating destination (22). 2956 o Node (12) is capable to maintain routing state again, and receives 2957 the DAOs from Node (22). Node (12) then learns: 2958 * Destination (22) is available via Node (22) 2959 * Destination (32) is available via Node (22) and the piecewise 2960 source route to (32) 2961 * Destination (42') is available via Node (22) and the piecewise 2962 source route to (32), (42'). 2964 o Node (12) sends DAOs to (LBR), allowing (LBR) to learn routes to 2965 the destinations (12), (22), (32), and (42'). (42), (53), (54), 2966 and (55) are available via the aggregation (42'). It is not 2967 necessary for Node (12) to propagate the piecewise source routes 2968 to (LBR). 2970 Appendix C. Additional Examples 2972 Consider the expanded example LLN physical topology in Figure 13. In 2973 this example an additional LBR is added. Suppose that all nodes are 2974 configured with an implementation specific policy function that aims 2975 to minimize the number of hops, and that both LBRs are configured to 2976 root different DAGIDs. We may now walk through the formation of the 2977 two DAGs. 2979 (LBR) (LBR2) 2980 / | \ / \ 2981 .---` | `----. / \ 2982 / | \ | | 2983 (11)------(12)------(13) (14) (15) 2984 | \ | \ | \ | /| 2985 | `----. | `----. | `----. | .----` | 2986 | \| \| \| / | 2987 (21)------(22)------(23) (24) (25) 2988 | /| /| | / / 2989 | .----` | .----` | .-----]|[------` / 2990 | / | / | / | / 2991 (31)------(32)------(33)------(34)-----` 2992 | /| \ | \ | \ 2993 | .----` | `----. | `----. | `----. 2994 | / | \| \| \ 2995 .--------(41) (42) (43)------(44)------(45) 2996 / / /| \ | \ 2997 .----` .----` .----` | `----. | `----. 2998 / / / | \| \ 2999 (51)------(52)------(53)------(54)------(55)------(56) 3001 Figure 13: Expanded LLN Topology 3002 (LBR) (LBR2) 3003 / | \ / \ 3004 .---` | `----. / \ 3005 / | \ | | 3006 (11) (12) (13) (14) (15) 3008 (21) (22) (23) (24) (25) 3010 (31) (32) (33) (34) 3012 (41) (42) (43) (44) (45) 3014 (51) (52) (53) (54) (55) (56) 3016 Figure 14: DAG Construction Step 1 3018 (LBR) (LBR2) 3019 / | \ / \ 3020 .---` | `----. / \ 3021 / | \ | | 3022 (11) (12) (13) (14) (15) 3023 | \ | \ | | /| 3024 | `----. | `----. | | .----` | 3025 | \| \| | / | 3026 (21) (22) (23) (24) (25) 3028 (31) (32) (33) (34) 3030 (41) (42) (43) (44) (45) 3032 (51) (52) (53) (54) (55) (56) 3033 Figure 15: DAG Construction Step 2 3035 (LBR) (LBR2) 3036 / | \ / \ 3037 .---` | `----. / \ 3038 / | \ | | 3039 (11) (12) (13) (14) (15) 3040 | \ | \ | | /| 3041 | `----. | `----. | | .----` | 3042 | \| \| | / | 3043 (21) (22) (23) (24) (25) 3044 | /| / | / / 3045 | .----` | .----` .-----]|[------` / 3046 | / | / / | / 3047 (31) (32) (33) (34)-----` 3049 (41) (42) (43) (44) (45) 3051 (51) (52) (53) (54) (55) (56) 3053 Figure 16: DAG Construction Step 3 3054 (LBR) (LBR2) 3055 / | \ / \ 3056 .---` | `----. / \ 3057 / | \ | | 3058 (11) (12) (13) (14) (15) 3059 | \ | \ | | /| 3060 | `----. | `----. | | .----` | 3061 | \| \| | / | 3062 (21) (22) (23) (24) (25) 3063 | /| / | / / 3064 | .----` | .----` .-----]|[------` / 3065 | / | / / | / 3066 (31) (32) (33) (34)-----` 3067 | /| | \ | \ 3068 | .----` | | `----. | `----. 3069 | / | | \| \ 3070 (41) (42) (43) (44) (45) 3072 (51) (52) (53) (54) (55) (56) 3074 Figure 17: DAG Construction Step 4 3076 (LBR) (LBR2) 3077 / | \ / \ 3078 .---` | `----. / \ 3079 / | \ | | 3080 (11) (12) (13) (14) (15) 3081 | \ | \ | | /| 3082 | `----. | `----. | | .----` | 3083 | \| \| | / | 3084 (21) (22) (23) (24) (25) 3085 | /| / | / / 3086 | .----` | .----` .-----]|[------` / 3087 | / | / / | / 3088 (31) (32) (33) (34)-----` 3089 | /| | \ | \ 3090 | .----` | | `----. | `----. 3091 | / | | \| \ 3092 .--------(41) (42) (43) (44) (45) 3093 / / /| | \ 3094 .----` .----` .----` | | `----. 3095 / / / | | \ 3096 (51) (52) (53) (54) (55) (56) 3097 Figure 18: DAG Construction Step 5 3099 Authors' Addresses 3101 Tim Winter (editor) 3103 Email: wintert@acm.org 3105 ROLL Design Team 3106 IETF ROLL WG 3108 Email: dtroll@external.cisco.com