RFC 7419

Common Interval Support in Bidirectional Forwarding Detection

πŸ“… published December 2014, from ietf

RFC 7419: Common Interval Support in Bidirectional Forwarding Detection ✨

Who wrote it: N. Akiya, M. Binderberger (Cisco Systems), and G. Mirsky (Ericsson) 🫢 Published by: Internet Engineering Task Force (IETF) 🌸 Category: Informational πŸ’œ Date: December 2014 πŸ“… ISSN: 2070-1721 Updates: RFC 5880 πŸ”₯ Obsoletes: nothing listed

The title block is giving very clean organization, bestie. This doc is not a Standards Track spec, so it's published for info only, and it's a sequel-style fix to RFC 5880 ✨


Abstract

okay so Bidirectional Forwarding Detection (BFD) needs messages to be sent at regular intervals, and it gives you a way to negotiate which interval BFD peers use πŸ¦‹ The catch is that some BFD implementations can only handle a few specific interval values. When two of those meet, they might not find a single interval they both support, and then the session just can't run πŸ’€

This doc updates RFC 5880 by defining a small set of interval values for BFD that we call "Common Intervals," and it recommends that implementations support them. It solves the "find a value we both can do" problem and still keeps things simple for hardware-based BFD 🧚 It doesn't stop an implementation from supporting more intervals on top of the Common Intervals, though. Go wild πŸ’…

Status of This Memo

Real talk: this document is not an Internet Standards Track specification. It's published for informational purposes 🌈

This document is a product of the Internet Engineering Task Force (IETF), and it represents the consensus of the IETF community. It went through public review and got approved for publication by the Internet Engineering Steering Group (IESG). Not every document the IESG approves is a candidate for any level of Internet Standard, so see Section 2 of RFC 5741 for the details πŸ™ˆ

For info about the current status of this document, any errata, and how to send feedback, check http://www.rfc-editor.org/info/rfc7419 ✨

Copyright (c) 2014 IETF Trust and the persons identified as the document authors. All rights reserved. πŸŽ€

This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info) as they stand on the date this document was published. Please actually read these, because they spell out your rights and restrictions for this document. Code Components pulled out of this document must include the Simplified BSD License text described in Section 4.e of the Trust Legal Provisions, and they come without warranty, as described in the Simplified BSD License πŸ’–

Table of Contents

1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
2.  The Problem with Few Supported Intervals  . . . . . . . . . .   3
3.  Well-Defined, Common Intervals  . . . . . . . . . . . . . . .   4
4.  Security Considerations . . . . . . . . . . . . . . . . . . .   4
5.  References  . . . . . . . . . . . . . . . . . . . . . . . . .   5
  5.1.  Normative References  . . . . . . . . . . . . . . . . . .   5
  5.2.  Informative References  . . . . . . . . . . . . . . . . .   5
Appendix A.  Why Some Values Are in the Common Interval Set . . .   6
Appendix B.  Timer Adjustment with Non-identical Interval Sets  .   6
Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . . .   8
Authors' Addresses  . . . . . . . . . . . . . . . . . . . . . . .   8

1. Introduction 🌸

The Bidirectional Forwarding Detection (BFD) standard [RFC5880] explains how to work out the transmission interval and the detection time. BUT it says nothing about what to do when one BFD speaker can't support the value that was calculated 😭 In practice this wasn't really a problem as long as software-implemented timers were used, and as long as the timer granularity was small compared to the interval values being supported. In other words, as long as the error in the timer interval stayed small compared to 25 percent jitter ✨

Now things are getting spicy. People are asking for super fast interval values, down to 3.3 msec for the MPLS Transport Profile (MPLS-TP) πŸ”₯ At the same time, the requested scale for the number of BFD sessions keeps climbing. Both of these have pushed vendors toward Network Processors (NP), Field Programmable Gate Arrays (FPGAs), or other hardware-based solutions to offload the periodic packet transmission and the timeout detection in the receive direction 🧚 The problem with hardware-based BFD is the granularity of its interval timers. Depending on the implementation, only a few intervals might be supported, and that can cause interoperability problems πŸ™ˆ This document proposes a set of interval values that should be supported by all implementations. The details are in the sections that follow πŸ¦‹

2. The Problem with Few Supported Intervals πŸ’…

Let's say vendor "A" supports 10 msec, 100 msec, and 1 sec interval timers in hardware, and vendor "B" supports every value from 20 msec onward, with a granularity of 1 msec. For a BFD session, "A" tries to set up the session with 10 msec, while "B" uses 20 msec as the value for RequiredMinRxInterval and DesiredMinTxInterval. Rx and Tx are negotiated as described in [RFC5880], which lands on 20 msec in this case. BUT system "A" can't support a 20 msec interval timer πŸ’€ There are multiple ways to resolve this dilemma, and none of them is without problems.

a. Realizing it can't support 20 msec, system "A" sends out a new BFD packet advertising the next larger interval of 100 msec in RequiredMinRxInterval and DesiredMinTxInterval. The new negotiated interval between "A" and "B" is then 100 msec, which both systems support. The problem? We jumped from the 10/20 msec range all the way to 100 msec, which is way off from what operators expected 😬

b. System "A" could violate [RFC5880] and use the 10 msec interval for the Tx direction. In the receive direction, it could use an adjusted multiplier value M' = 2 * M to match the correct detection time. Now, besides the fact that we're explicitly violating [RFC5880], there may be a problem where system "B" drops up to 50% of the packets. That could happen if "B" uses an ingress rate policer to protect itself, and the policer was programmed to expect 20 msec receive intervals πŸ™ƒ

The example above could get even worse if system "B" can only support a few timer values itself. Let's say "B" supports 20 msec, 300 msec, and 1 sec. If both systems adjust their advertised intervals, the adjustment ends at 1 sec. It could be even worse still if "B" can only support 50 msec, 500 msec, and 2 sec. In that case, even if both systems walk through all of their supported intervals, the two systems will never be able to agree on an interval to run any BFD sessions πŸ˜­πŸ’”

3. Well-Defined, Common Intervals πŸŽ€

The fix is to define interval values that all implementations support. That way the adjustment mechanism can find a commonly supported interval without straying too far from the original request ✨

In technical terms, the requirement is this: a BFD implementation should support all values in the set of Common Interval values that are equal to or larger than the fastest (i.e., lowest) interval that the particular BFD implementation supports 🧚

This document defines the set of Common Interval values as: 3.3 msec, 10 msec, 20 msec, 50 msec, 100 msec, and 1 sec.

On top of that, both a 10 sec interval and multiplier values up to 255 are recommended to support graceful restart 🌈

The adjustment always goes toward larger (i.e., slower) interval values when the initial interval proposed by the peer isn't supported 🐒

This document doesn't add any new requirements about how precisely a timer value must be implemented πŸ’œ Supporting an interval value means advertising that value in the DesiredMinTxInterval and/or RequiredMinRxInterval field of BFD packets, and providing timers that are reasonably close. [RFC5880] defines the safety margins for timers by defining a jitter range 🫢

So how is the Common Interval set used, exactly? In the example above, vendor "A" has a fastest interval of 10 msec, so it would be required to support all Common Intervals equal to or larger than 10 msec. That means 10 msec, 20 msec, 50 msec, 100 msec, and 1 sec. Vendor "B" has a fastest interval of 20 msec, so it would need to support 20 msec, 50 msec, 100 msec, and 1 sec. As long as this requirement is met for the common set of values, both vendor "A" and vendor "B" are free to support additional values outside of the Common Interval set πŸ‘‘


to be continued in part 2 πŸ¦‹πŸ’–

Appendix A. Why Some Values Are in the Common Interval Set πŸ’–

The Common Interval list is basically a balancing act πŸŽ€. We don't want too many values, because every extra timer makes implementations more expensive πŸ’…. But fewer values means bigger gaps and bigger adjustment jumps 😭. So we add more values in the low-interval range, since that's where customers in multi-vendor setups need fast detection πŸ¦‹.

  • 3.3 msec: MPLS-TP needs this one to hit the 10 msec defect detection time from [GR-253-CORE] 🧚
  • 10 msec: general consensus is to support it. Multiple vendors already do it or plan to πŸ”₯
  • 20 msec: this one avoids a big gap in that critical region ✨. It still allows 50-60 msec detect and restore (with multiplier of 2), and it covers existing software-based implementations πŸ’œ
  • 50 msec: this is a widely deployed interval 🌸. Supporting it matches what lots of BFD implementations do today πŸ’…
  • 100 msec: kind of like 10 msec, this value lets you reuse [G.8013_Y.1731] implementations, especially hardware πŸ“. It supports a big pile of 100 msec sessions with multiplier 9 (9 x 100 msec), which could replace the 3 x 300 msec configs customers use to get a detection time just under 1 sec for VoIP setups πŸ“ž
  • 1 sec: this comes from [RFC5880] πŸ‘‘. The interval for Down packets can be 1 sec or larger, but this document recommends using exactly 1 sec to avoid interoperability issues 🫢
The recommended value for large intervals is 10 sec 🌈. That gives you a timeout of 42.5 minutes with a multiplier of 255. It's kept outside the Common Interval set because normal BFD operations happen in the sub-second range and don't need it. The expected use is graceful restart, if needed πŸ™ˆ

Appendix B. Timer Adjustment with Non-identical Interval Sets πŸ¦‹

Okay so [RFC5880] kind of quietly assumes that a BFD implementation can support any timer value equal to or above the advertised one 🧚. When a BFD speaker starts a Poll Sequence, the peer has to reply with the Final (F) bit set and adjust its transmit and detection timers ✨. With contiguous software-based timers, that's totally fine πŸ’…. Even with a small number of supported intervals, it still works as long as both speakers support exactly the same interval values 🫢.

But what happens when both speakers support intervals that the peer doesn't? 😭 Picture router "A" supporting the Common Interval set plus 200 msec, while router "B" supports the Common Intervals plus 300 msec. Both routers are configured and running at 50 msec πŸ’–. Now router A gets configured for 200 msec. The result has to be that both BFD speakers end up on 1 sec timers, but how do they actually get there? πŸ€”

First, router A sends a packet with 200 msec. The P bit is set according to [RFC5880] πŸ”₯. The Tx timer stays at 50 msec, and the detection timer is 3 * 200 msec:

   (A) DesiredTx: 200 msec, MinimumRx: 200 msec, P-bit
      Tx: 50 msec, Detect: 3 * 200 msec

Router B now has to reply with an F bit πŸ’€. The issue is that B is confirming timer values it can't actually support. The only way to avoid a session flap is:

   (B) DesiredTx: 300 msec, MinimumRx: 300 msec, F-bit
      Tx: 50 msec, Detect: 3 * 300 msec

...and then immediately follow up with a P-bit packet, since the advertised timer values have changed:

   (B) DesiredTx: 300 msec, MinimumRx: 300 msec, P-bit
      Tx: 50 msec, Detect: 3 * 300 msec

Not exactly what Section 6.8.7 of [RFC5880] says about the transmission rate πŸ™ˆ. Here's the good news though: this state doesn't last long 🌸. Router A adjusts its timers based on the received Final bit:

   (A) Tx: 200 msec, Detect: 3 * 1 sec

Router A doesn't support the proposed 300 msec, so it uses 1 sec for the detection time instead πŸ’…. It then responds to router B's Poll Sequence using 1 sec, since router A doesn't support Max(200 msec, 300 msec):

   (A) DesiredTx: 1 sec, MinimumRx: 1 sec, F-bit
      Tx: 200 msec, Detect: 3 * 1 sec

and then sends its own Poll Sequence, because the advertised timer values have changed:

   (A) DesiredTx: 1 sec, MinimumRx: 1 sec, P-bit
      Tx: 200 msec, Detect: 3 * 1 sec

Router B adjusts its timers based on the received Final bit:

   (B) Tx: 300 msec , Detect: 3 * 1 sec

then replies to router A's Poll Sequence:

   (B) DesiredTx: 300 msec, MinimumRx: 300 msec, F-bit
      Tx: 1 sec, Detect: 3 * 1 sec

which finally makes router A adjust its timers:

   (A) Tx: 1 sec, Detect: 3 * 1 sec

So yeah, router A and B go through multiple Poll Sequences until they land on a value they both support πŸ‘‘. And this document guarantees that they will reach one ✨🫢.

Acknowledgments πŸŽ€

Huge thank yous to Sylvain Masse and Anca Zamfir for starting the conversation about the Poll Sequence πŸ’œ. Also a big shoutout to Jeffrey Haas for helping us find the fine line between "exact" and "pedantic" πŸ™ˆπŸ”₯.

Authors' Addresses 🌈

Nobo Akiya Cisco Systems

EMail: nobo@cisco.com

Marc Binderberger Cisco Systems

EMail: mbinderb@cisco.com

Greg Mirsky Ericsson

EMail: gregory.mirsky@ericsson.com

πŸ“¦ where this page comes from