idnits 2.17.1 draft-lapukhov-bgp-ecmp-considerations-01.txt: Checking boilerplate required by RFC 5378 and the IETF Trust (see https://trustee.ietf.org/license-info): ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/1id-guidelines.txt: ---------------------------------------------------------------------------- No issues found here. Checking nits according to https://www.ietf.org/id-info/checklist : ---------------------------------------------------------------------------- ** The document seems to lack a Security Considerations section. ** The document seems to lack an IANA Considerations section. (See Section 2.2 of https://www.ietf.org/id-info/checklist for how to handle the case when there are no actions for IANA.) ** The abstract seems to contain references ([RFC4271]), which it shouldn't. Please replace those with straight textual mentions of the documents in question. ** The document seems to lack a both a reference to RFC 2119 and the recommended RFC 2119 boilerplate, even if it appears to use RFC 2119 keywords. RFC 2119 keyword, line 93: '...at content of AS_SEQUENCE segment MUST...' Miscellaneous warnings: ---------------------------------------------------------------------------- == The copyright year in the IETF Trust and authors Copyright Line does not match the current year -- The document date (October 30, 2017) is 2370 days in the past. Is this intentional? Checking references for intended status: Informational ---------------------------------------------------------------------------- == Outdated reference: A later version (-07) exists of draft-ietf-idr-link-bandwidth-06 Summary: 4 errors (**), 0 flaws (~~), 2 warnings (==), 1 comment (--). Run idnits with the --verbose option for more detailed information about the items above. -------------------------------------------------------------------------------- 2 Network Working Group P. Lapukhov 3 Internet-Draft Facebook 4 Intended status: Informational October 30, 2017 5 Expires: May 3, 2018 7 Equal-Cost Multipath Considerations for BGP 8 draft-lapukhov-bgp-ecmp-considerations-01 10 Abstract 12 BGP routing protocol defined in ([RFC4271]) employs tie-breaking 13 logic to elect single best path among multiple possible. At the same 14 time, it has been common in all practical BGP implementations to 15 allow for "equal-cost multipath" (ECMP) path election and programming 16 of multiple next-hops in routing tables. This documents provides 17 some common considerations for the ECMP logic, with the intent of 18 providing common reference on otherwise unstandardized feature. 20 Status of This Memo 22 This Internet-Draft is submitted in full conformance with the 23 provisions of BCP 78 and BCP 79. 25 Internet-Drafts are working documents of the Internet Engineering 26 Task Force (IETF). Note that other groups may also distribute 27 working documents as Internet-Drafts. The list of current Internet- 28 Drafts is at https://datatracker.ietf.org/drafts/current/. 30 Internet-Drafts are draft documents valid for a maximum of six months 31 and may be updated, replaced, or obsoleted by other documents at any 32 time. It is inappropriate to use Internet-Drafts as reference 33 material or to cite them other than as "work in progress." 35 This Internet-Draft will expire on May 3, 2018. 37 Copyright Notice 39 Copyright (c) 2017 IETF Trust and the persons identified as the 40 document authors. All rights reserved. 42 This document is subject to BCP 78 and the IETF Trust's Legal 43 Provisions Relating to IETF Documents 44 (https://trustee.ietf.org/license-info) in effect on the date of 45 publication of this document. Please review these documents 46 carefully, as they describe your rights and restrictions with respect 47 to this document. Code Components extracted from this document must 48 include Simplified BSD License text as described in Section 4.e of 49 the Trust Legal Provisions and are provided without warranty as 50 described in the Simplified BSD License. 52 Table of Contents 54 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 2 55 2. AS-PATH attribute comparison . . . . . . . . . . . . . . . . 2 56 3. Multipath among eBGP-learned paths . . . . . . . . . . . . . 3 57 4. Multipath among iBGP learned paths . . . . . . . . . . . . . 3 58 5. Multipath among eBGP and iBGP paths . . . . . . . . . . . . . 4 59 6. Multipath with AIGP . . . . . . . . . . . . . . . . . . . . . 5 60 7. Best path advertisement . . . . . . . . . . . . . . . . . . . 5 61 8. Multipath and non-deterministic tie-breaking . . . . . . . . 5 62 9. Weighted equal-cost multipath . . . . . . . . . . . . . . . . 5 63 10. Informative References . . . . . . . . . . . . . . . . . . . 5 64 Author's Address . . . . . . . . . . . . . . . . . . . . . . . . 6 66 1. Introduction 68 Section 9.1.2.2 of [RFC4271] defines step-by step procedure for 69 selecting single "best-path" among multiple alternative available for 70 the same NLRI (Network Layer Reachability Information) element. In 71 order to improve efficiency in symmetric network topologies is has 72 become common practice to allow selecting multiple "equivalent" paths 73 for the same prefix. Most commonly used approach is to stop the tie- 74 breaking process after comparing the IGP cost for the NEXT_HOP 75 attribute and selecting either all eBGP or all iBGP paths that 76 remained equivalent under the tie-breaking rules (see [BGPMP] for a 77 vendor document explaining the logic). Basically, the steps that 78 compare the BGP identifier and BGP peer IP addresses (steps (f) and 79 (g)) are ignored for the purpose of multipath routing. BGP 80 implementations commonly have a configuration knob that specifies the 81 maximum number of equivalent paths that may be programmed to the 82 routing table. There is also common a knob to enable multipath 83 separately for iBGP-learned or eBGP-learned paths. 85 2. AS-PATH attribute comparison 87 A mandatory requirement is for all paths that are candidates for ECMP 88 selection to have the same AS_PATH length, computed using the 89 standard logic defined in [RFC4271] and [RFC5065], i.e. ignoring the 90 AS_SET, AS_CONFED_SEQUENCE, and AS_CONFED_SET segment lengths. The 91 content of the latter attributes is used purely for loop detection. 92 Assuming that AS_PATH lengths computed in this fashion are the same, 93 many implementations require that content of AS_SEQUENCE segment MUST 94 be the same among all equivalent paths. Two common configuration 95 knobs are usually provided: one allowing only the length of AS_PATH 96 to be the same, and another requiring that the first AS numbers in 97 first AS_SEQUENCE segment found in AS_PATH (often referred to as 98 "peer AS" number) be the same as the one found in best path 99 (determined by running the full tie-breaking algorithm). This 100 document refer to those two as "multipath as-path relaxed" and 101 "multipath same peer-as" knobs. 103 3. Multipath among eBGP-learned paths 105 Step (d) in Section 9.1.2.2 of [RFC4271] instructs to remove all iBGP 106 paths from considerations if an eBGP path is present in the candidate 107 set. This leaves the BGP process with just eBGP paths. At this 108 point, the mandatory BGP NEXT_HOP attribute value most commonly 109 belongs to the IP subnet that the BGP speaker shares with advertising 110 neighbor. In this case, it is common for implementation to treat all 111 NEXT_HOP values as having the same "internal cost" to reach them per 112 the guidance of step (e) of Section 9.1.2.2. In some cases, either 113 static routing or an IGP routing protocol could be running between 114 the BGP speakers peering over eBGP session. An implementation may 115 use the metric discovered from the above sources to perform tie- 116 breaking even for eBGP paths. 118 In case when MED attribute is present in some paths, the set of 119 allowed multipath routes will most likely be reduced to the ones 120 coming from the same peer AS, per step (c) of Section 9.1.2.2. This 121 is unless the implementation provided a configuration knob to always 122 compare MED attributes across all paths, as recommended in [RFC4451]. 123 In the latter case, the presence of MED attribute does not narrow the 124 candidate path set only to the same peer AS. 126 4. Multipath among iBGP learned paths 128 When all paths for a prefix are learned via iBGP, the tie-breaking 129 commonly occurs based on IGP metric of the NEXT_HOP attribute, since 130 in most cases iBGP is used along with an underlying IGP. It is 131 possible, in some implementations, to ignore the IGP cost as well, if 132 all of the paths are reachable via some kind of tunneling mechanism, 133 such as MPLS ([RFC3031]). This is enabled via a knob referred to as 134 "skip igp check" in this document. Notice that there is no standard 135 way for a BGP speaker to detect presence of such tunneling techniques 136 other than relying on configuration settings. 138 When iBGP is deployed with BGP route-reflectors per [RFC4456] the 139 path attribute list may include the CLUSTER_LIST attribute. Most 140 implementations commonly ignore it for the purpose of ECMP route 141 selection, assuming that IGP cost along should be sufficient for loop 142 prevention. This assumption may not hold when IGP is not deployed, 143 and instead iBGP session are configured to reset the NEXT_HOP 144 attribute on every node (this also assumes the use of directly 145 connected link IP addresses for session formation). In this case, 146 ignoring CLUSTER_LIST length might lead to routing loops. It is 147 therefore recommended for implementations to have a knob that enables 148 accounting for CLUSTER_LIST length when performing multipath route 149 selection. In this case, CLUSTER_LIST attribute length should be 150 effectively used to replace the IGP metric. 152 Similar to the route-reflector scenario, the use of BGP 153 confederations assumes presence of an IGP for proper loop prevention 154 in multipath scenarios, and use the IGP metric as the final tie- 155 breaker for multipath routing. In addition to this, and similar to 156 eBGP case, implementation often require that equivalent paths belong 157 to the same peer member AS as the best-path. It is useful to have 158 two configuration knobs, one enabling "multipath same confederation 159 member peer-as" and another enabling less restrictive "confed as-path 160 multipath relaxed", which allows selecting multipath routes going via 161 any confederation member peer AS. As mentioned above, the 162 AS_CONFED_SEQUENCE value length is usually ignored for the purpose of 163 AS_PATH length comparison, relying on IGP cost instead for loop 164 prevention. 166 In case if IGP is not present with BGP confederation deployment, and 167 similar to route-reflection case, it may be needed to consider 168 AS_CONFED_SEQUENCE length when selecting the equivalent routes, 169 effectively using it as a substitution for IGP metric. A separate 170 configuration knob is needed to allow this behavior. 172 Per [RFC5065] the path learned over BGP intra-confederation peering 173 sessions are treated as iBGP. There is no specification or 174 operational document that defines how a mixed iBGP route-reflector 175 and confederation based model would work together. Therefore, this 176 document does not make recommendations or considers this case. 178 5. Multipath among eBGP and iBGP paths 180 The best-path selection algorithm explicitly prefers eBGP paths over 181 iBGP (or learned from BGP confederation member AS, which is per 182 [RFC5065] is treated the same as iBGP from perspective of best-path 183 selection). In some case, allowing multipath routing between eBGP 184 and iBGP learned paths might be beneficial. This is only possible if 185 some sort of tunneling technique is used to reach both the eBGP and 186 iBGP path. If this feature is enabled, the equivalent routes are 187 selection by stopping the tie-breaking process prior at the MED 188 comparison step (c) in Section 9.1.2.2 of [RFC4271]. 190 6. Multipath with AIGP 192 AIGP attribute defined in [RFC7311] must be used for best-path 193 selection prior to running any logic of Section 9.1.2.2. Only the 194 paths with minimal value of AIGP metric are eligible for further 195 consideration of tie-breaking rules. The rest of multipath selection 196 logic remains the same. 198 7. Best path advertisement 200 Event though multiple equivalent paths may be selected for 201 programming into the routing table, the BGP speaker always announces 202 single best-path to its peers, unless BGP "Add-Path" feature has been 203 enabled as described in [RFC7911]. The unique best-path is elected 204 among the multi-path set using the standard tie-breaking rules. 206 8. Multipath and non-deterministic tie-breaking 208 Some implementations may implement non-standard tie-breaking using 209 the oldest path rule to improve routing stability. This is generally 210 not recommended, and may interact with multi-path route selection on 211 downstream BGP speakers. That is, after a route flap that affects 212 the best-path upstream, the original best path would not be 213 recovered, and the older path still be advertised, possibly affecting 214 the tie-breaking rules on down-stream device, for example if the 215 AS_PATH contents are different from previous. 217 9. Weighted equal-cost multipath 219 The proposal in [I-D.ietf-idr-link-bandwidth] defines conditions 220 where iBGP multipath feature might inform the routing table of the 221 "weights" associated with the multiple paths. The document defines 222 the applicability only in iBGP case, though there are implementations 223 that apply it to eBGP multipath as well. The proposal does not 224 change the equal-cost multipath selection logic, only associates 225 additional load-sharing attributes with equivalent paths. 227 10. Informative References 229 [BGPMP] "BGP Best Path Selection Algorithm", 230 . 233 [I-D.ietf-idr-link-bandwidth] 234 Mohapatra, P. and R. Fernando, "BGP Link Bandwidth 235 Extended Community", draft-ietf-idr-link-bandwidth-06 236 (work in progress), January 2013. 238 [RFC3031] Rosen, E., Viswanathan, A., and R. Callon, "Multiprotocol 239 Label Switching Architecture", RFC 3031, 240 DOI 10.17487/RFC3031, January 2001, 241 . 243 [RFC4271] Rekhter, Y., Ed., Li, T., Ed., and S. Hares, Ed., "A 244 Border Gateway Protocol 4 (BGP-4)", RFC 4271, 245 DOI 10.17487/RFC4271, January 2006, 246 . 248 [RFC4451] McPherson, D. and V. Gill, "BGP MULTI_EXIT_DISC (MED) 249 Considerations", RFC 4451, DOI 10.17487/RFC4451, March 250 2006, . 252 [RFC4456] Bates, T., Chen, E., and R. Chandra, "BGP Route 253 Reflection: An Alternative to Full Mesh Internal BGP 254 (IBGP)", RFC 4456, DOI 10.17487/RFC4456, April 2006, 255 . 257 [RFC5065] Traina, P., McPherson, D., and J. Scudder, "Autonomous 258 System Confederations for BGP", RFC 5065, 259 DOI 10.17487/RFC5065, August 2007, 260 . 262 [RFC7311] Mohapatra, P., Fernando, R., Rosen, E., and J. Uttaro, 263 "The Accumulated IGP Metric Attribute for BGP", RFC 7311, 264 DOI 10.17487/RFC7311, August 2014, 265 . 267 [RFC7911] Walton, D., Retana, A., Chen, E., and J. Scudder, 268 "Advertisement of Multiple Paths in BGP", RFC 7911, 269 DOI 10.17487/RFC7911, July 2016, 270 . 272 Author's Address 274 Petr Lapukhov 275 Facebook 276 1 Hacker Way 277 Menlo Park, CA 94025 278 US 280 Email: petr@fb.com