<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rfc [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY bom    "&#65279;">
  <!ENTITY wd     "&#x2011;">
]>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" ipr="trust200902"
     docName="draft-li-bfd-rcp-00"
     category="std" submissionType="IETF" consensus="true" version="3"
     xml:lang="en" tocInclude="true" sortRefs="true" symRefs="true">
  <front>
    <title abbrev="BFD for Redundant CPs">BFD Considerations for Redundant Control Planes</title>
    <seriesInfo name="Internet-Draft" value="draft-li-bfd-rcp-00"/>

    <author fullname="Zhiqiang Li" initials="Z." surname="Li">
      <organization>China Mobile</organization>
      <address>
        <postal><city>Beijing</city><code>100053</code>
        <country>China</country></postal>
        <email>lizhiqiangyjy@chinamobile.com</email>
      </address>
    </author>
    <author fullname="Zongpeng Du" initials="Z." surname="Du">
      <organization>China Mobile</organization>
      <address>
        <postal><city>Beijing</city><code>100053</code>
        <country>China</country></postal>
        <email>duzongpeng@chinamobile.com</email>
      </address>
    </author>
    <author fullname="Junjie Wang" initials="J." surname="Wang">
      <organization>Centec</organization>
      <address>
        <postal><city>Shanghai</city><code>201203</code>
        <country>China</country></postal>
        <email>wangjj@centec.com</email>
      </address>
    </author>
    <author fullname="Wei Cheng" initials="W." surname="Cheng">
      <organization>Centec</organization>
      <address>
        <postal><city>Shanghai</city><code>201203</code>
        <country>China</country></postal>
        <email>chengw@centec.com</email>
      </address>
    </author>
    <author fullname="Guoying Zhang" initials="G." surname="Zhang">
      <organization>Centec</organization>
      <address>
        <postal><city>Shanghai</city><code>201203</code>
        <country>China</country></postal>
        <email>zhanggy@centec.com</email>
      </address>
    </author>
    <author fullname="Xun Sun" initials="X." surname="Sun">
      <organization>Inesa</organization>
      <address>
        <postal><city>Shanghai</city><code>200030</code>
        <country>China</country></postal>
        <email>sunxun@inesa.com</email>
      </address>
    </author>
    <author fullname="Chunhao Zhao" initials="C." surname="Zhao">
      <organization>SAIA</organization>
      <address>
        <postal><city>Shanghai</city><code>200125</code>
        <country>China</country></postal>
        <email>chunhao.zhao@sh-aia.com</email>
      </address>
    </author>

    <date year="2026" month="July" day="4"/>
    <area>RTG</area>
    <workgroup>BFD</workgroup>
    <keyword>BFD</keyword>
    <keyword>Bidirectional Forwarding Detection</keyword>
    <keyword>redundant control plane</keyword>
    <keyword>switchover</keyword>
    <keyword>high availability</keyword>
    <abstract>
      <t>In systems with redundant control plane processors, Bidirectional Forwarding Detection (BFD) sessions are typically managed by a single active processor. When that processor fails and a standby takes over, BFD sessions may be interrupted long enough for remote peers to declare failure, even though the forwarding plane remains operational.</t>
      <t>This document describes requirements and operational considerations for preserving BFD sessions across control plane switchover events. It discusses how BFD session state can be maintained on a standby processor and how BFD processing can be resumed by the standby within the BFD Detection Time, without requiring cooperation from or signaling to remote BFD peers.</t>
    </abstract>
  </front>

  <middle>
<section anchor="introduction" numbered="true" toc="include"><name>Introduction</name>
<t>Bidirectional Forwarding Detection (BFD) <xref target="RFC5880"/> provides a low-overhead mechanism for detecting forwarding path failures between adjacent systems. BFD is widely deployed in conjunction with routing protocols such as OSPF, IS-IS, and BGP to trigger rapid convergence upon link or node failure.</t>
<t>Many network devices employ redundant control plane architectures to improve availability. Common examples include routers with dual Route Processors (RPs), switch stacking topologies, Virtual Chassis systems, and chassis with redundant Supervisor modules. In these systems, one control plane processor is active while one or more standby processors are available to take over upon failure.</t>
<t>In typical deployments, BFD sessions are managed entirely by the active processor: the BFD state machine, timers, and packet processing all reside there. When the active processor fails and control transitions to a standby, BFD sessions must be re-established. This re-establishment time frequently exceeds the BFD Detection Time (the product of the negotiated transmit interval and the detection multiplier, as defined in <xref target="RFC5880"/>), causing the remote BFD peer to declare failure.</t>
<t>The result is unnecessary routing reconvergence and transient traffic disruption, even when the forwarding plane remains fully operational.</t>
<t>The interactions between BFD and Graceful Restart (GR) described in Section 4.3 of <xref target="RFC5882"/> address BFD behavior during control protocol restarts, but rely on explicit signaling by the restarting system and cooperation from remote peers in helper mode. Not all control protocols support planned restart signaling, and GR cannot protect against all unplanned failure scenarios.</t>
<t>This document describes an approach in which BFD session state is maintained on the standby processor and BFD processing is resumed there before the remote peer's Detection Time expires. Because this operates entirely within the local system, the remote BFD peer is unaware of the switchover, and no protocol extensions or new BFD packet formats are introduced.</t>
<t>This document does not address forwarding plane failures, link-level failures, or data plane issues, which are detected by normal BFD operation as defined in <xref target="RFC5880"/>. The considerations in this document are also distinct from Seamless BFD (S-BFD) <xref target="RFC7880"/>, which defines an initiator/responder model for unidirectional path monitoring.</t>
<section anchor="requirements-language" numbered="true" toc="include"><name>Requirements Language</name>
<t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOT RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14 <xref target="RFC2119"/> <xref target="RFC8174"/> when, and only when, they appear in all capitals, as shown here.</t>
</section></section>
<section anchor="terminology" numbered="true" toc="include"><name>Terminology</name>
<t>This document uses the following terms. BFD-specific terms such as Detection Time, Discriminator, and state machine variables are defined in <xref target="RFC5880"/>.</t>
<dl><dt>Active Processor:</dt><dd>The control plane processor in a redundant system that is currently running the BFD state machine, managing BFD session timers, and processing BFD control packets for all locally-owned sessions.</dd>
<dt>Standby Processor:</dt><dd>A control plane processor in a redundant system that is available to take over BFD session processing from the active processor. During normal operation, the standby processor does not run BFD timers or generate BFD control packets.</dd>
<dt>Switchover:</dt><dd>The event in which BFD session processing transitions from the active processor to a standby processor, which then becomes the new active processor. A switchover may be planned (e.g., administrative action) or unplanned (e.g., processor failure).</dd></dl>
</section>
<section anchor="system-model" numbered="true" toc="include"><name>System Model</name>
<t>This document considers systems with the following characteristics:</t>
<ul><li>Two or more control plane processors, each capable of running BFD.</li><li>A shared forwarding plane that continues to operate during control plane switchover.</li><li>An internal communication path between processors with sufficient bandwidth and reliability to carry BFD session state.</li></ul>
<t>Such systems include routers with redundant Route Processors, switch stacking topologies, Virtual Chassis configurations, and chassis with redundant Supervisor modules.</t>
<t>At any point in time, exactly one processor is active for any given BFD session. This invariant MUST be maintained: there MUST NOT be a period during which two processors simultaneously run timers or transmit BFD control packets for the same session.</t>
</section>
<section anchor="maintaining-bfd-state" numbered="true" toc="include"><name>Maintaining BFD State on the Standby Processor</name>
<t>To enable the standby processor to resume BFD processing after switchover, the active processor MUST keep the standby informed of current BFD session state. The following session variables, as defined in Section 6.8.1 of <xref target="RFC5880"/>, MUST be available on the standby processor:</t>
<ul><li>bfd.LocalDiscr and bfd.RemoteDiscr</li><li>bfd.SessionState and bfd.RemoteSessionState</li><li>bfd.LocalDiag</li><li>bfd.DesiredMinTxInterval and bfd.RequiredMinRxInterval</li><li>bfd.RemoteMinRxInterval</li><li>bfd.DemandMode and bfd.RemoteDemandMode</li><li>bfd.DetectMult</li><li>bfd.AuthType, and when authentication is enabled, bfd.RcvAuthSeq and bfd.XmitAuthSeq</li></ul>
<t>The state on the standby processor MUST be sufficiently current that BFD processing can be resumed without the remote peer detecting a discontinuity. In particular, the standby's copy of session state MUST NOT lag behind the active processor by more than one BFD transmission interval.</t>
<t>The specific method used to keep the standby processor informed is an implementation choice. Possible approaches include shared memory between processors on the same board, inter-processor messaging over a backplane, checkpoint-based periodic synchronization, or any other suitable internal transport. This document does not prescribe a particular method.</t>
<t>While the standby processor holds copies of BFD session state, it MUST NOT run BFD state machine timers, transmit BFD control packets, or otherwise actively participate in BFD sessions. The standby MUST be ready to begin active BFD processing at any time upon becoming the active processor.</t>
</section>
<section anchor="switchover-behavior" numbered="true" toc="include"><name>Switchover Behavior</name>
<t>When a switchover occurs (whether planned or due to failure), the system MUST ensure that BFD processing resumes on the newly active processor before the remote peer's Detection Time expires. The following requirements apply.</t>
<section anchor="packet-delivery" numbered="true" toc="include"><name>Packet Delivery</name>
<t>Incoming BFD control packets MUST be delivered to the processor that is currently active for the corresponding BFD session. The system MUST be capable of redirecting BFD packet delivery to the newly active processor as part of the switchover.</t>
<t>If the system's forwarding plane can receive BFD packets on behalf of multiple processors (e.g., in a stacking topology where different member switches have physical ports), then the system MUST ensure that BFD packets received on any port are delivered to the currently active processor, regardless of which physical member receives the packet.</t>
</section>
<section anchor="resuming-bfd-processing" numbered="true" toc="include"><name>Resuming BFD Processing</name>
<t>Upon becoming the active processor, the newly active processor MUST begin running the BFD state machine for each session using the most recently available session state. Specifically:</t>
<ul><li>BFD control packets transmitted by the newly active processor MUST use the same bfd.LocalDiscr, bfd.RemoteDiscr, and bfd.SessionState values that were in use by the former active processor. From the remote peer's perspective, there MUST be no observable change in these values.</li><li>The transmit interval MUST be set to the previously negotiated bfd.DesiredMinTxInterval.</li><li>The Detection Time calculation MUST continue using the previously negotiated parameters.</li><li>If BFD authentication is enabled (as specified in Section 6.7 of <xref target="RFC5880"/>), the newly active processor MUST continue the authentication sequence from the values maintained on the standby. For Meticulous Keyed modes, the sequence number used in the first transmitted packet MUST be the successor of the most recently transmitted sequence number.</li></ul>
</section>
<section anchor="former-active-processor" numbered="true" toc="include"><name>Former Active Processor</name>
<t>If the former active processor is still partially operational during a planned switchover, it MUST cease all BFD timer processing and packet transmission before the newly active processor begins transmitting. This prevents duplicate packets and conflicting state transitions. If the former active processor has failed completely, this condition is inherently satisfied.</t>
</section>
<section anchor="timing-requirements" numbered="true" toc="include"><name>Timing Requirements</name>
<t>For BFD sessions to survive a switchover, the newly active processor MUST transmit a valid BFD control packet before the remote peer's Detection Time expires. The Detection Time is defined in Section 6.8.4 of <xref target="RFC5880"/> as the product of the remote peer's bfd.RequiredMinRxInterval (or the negotiated transmit interval) and bfd.DetectMult.</t>
<t>Because BFD transmissions from the local system cease during the switchover interval, and the remote peer's Detection Timer continues to run, the total time consumed by the switchover -- including redirecting packet delivery, loading session state on the new processor, and transmitting the first BFD packet -- MUST be less than the remaining time on the remote peer's Detection Timer.</t>
<t>In practice, the switchover time SHOULD be significantly shorter than the Detection Time to account for scheduling variance and processing delays. A switchover that completes within a small fraction of the Detection Time provides adequate margin for reliable operation.</t>
</section></section>
<section anchor="applicability" numbered="true" toc="include"><name>Applicability</name>
<section anchor="bfd-session-types" numbered="true" toc="include"><name>BFD Session Types</name>
<t>The approach described in this document applies to BFD sessions operating in Asynchronous mode, which is the most widely deployed operational mode. Sessions using Demand mode MAY also benefit, although the timing considerations differ because the remote peer does not maintain a continuous Detection Timer in Demand mode.</t>
<t>BFD Echo mode operates in the forwarding plane and is typically unaffected by control plane switchover. The considerations in this document generally do not apply to the Echo function.</t>
<t>The approach applies to both single-hop BFD sessions <xref target="RFC5881"/> and multihop sessions. The specific BFD encapsulation does not affect the requirements described here.</t>
<t>For BFD sessions associated with Link Aggregation Groups as described in <xref target="RFC7130"/>, session state for each per-member-link BFD session (micro-BFD session) MUST be individually maintained on the standby. All micro-BFD sessions associated with a LAG MUST be covered by the switchover.</t>
</section>
<section anchor="relationship-to-bfd-graceful-restart" numbered="true" toc="include"><name>Relationship to BFD Graceful Restart</name>
<t>The approach described in this document operates entirely within the local system and does not require remote peer awareness or cooperation. In contrast, the BFD interactions with Graceful Restart described in <xref target="RFC5882"/> rely on the remote peer entering helper mode and on control-protocol-level restart signaling.</t>
<t>The two approaches are complementary. A system MAY implement both: using standby-based BFD state maintenance for local recovery, while also signaling GR capability for interoperability with peers that support it. When both are present, the local switchover can provide sub-Detection-Time recovery independent of whether the remote peer supports GR.</t>
<t>If a system successfully preserves BFD sessions across switchover as described in this document, the Control Plane Independent (C) bit in the BFD control packet (Section 4.3 of <xref target="RFC5882"/>) accurately reflects that BFD is not sharing fate with the control plane, since BFD processing survives the control plane restart.</t>
</section></section>
<section anchor="manageability-considerations" numbered="true" toc="include"><name>Manageability Considerations</name>
<t>Implementations supporting BFD across redundant control planes SHOULD provide the following operational visibility:</t>
<ul><li>An indication of whether BFD session state is currently being maintained on the standby processor for each session, and whether the standby state is current.</li><li>Counters tracking the number of switchover events that occurred and whether BFD sessions were preserved during each event.</li><li>Notifications when the state on the standby processor falls behind the active processor by more than a configurable threshold.</li><li>A mechanism to administratively enable or disable BFD state maintenance on the standby, on a per-session or system-wide basis.</li></ul>
</section>
<section anchor="security-considerations" numbered="true" toc="include"><name>Security Considerations</name>
<t>Maintaining BFD session state on a standby processor introduces an internal communication path that carries sensitive information including discriminator values and, when authentication is enabled, authentication sequence numbers and keying material.</t>
<t>The internal communication path between processors MUST be protected against unauthorized modification. An attacker who can alter session state on the standby could cause BFD sessions to fail upon switchover or could prevent legitimate failure detection by injecting false state. If BFD authentication is in use, compromise of replicated authentication state could enable session spoofing.</t>
<t>When the communication path between processors traverses media that may be subject to interception or modification -- for example, a backplane fabric accessible to line cards running third-party software -- the path SHOULD be protected using integrity and confidentiality mechanisms such as MACsec <xref target="IEEE802.1AE"/> or IPsec <xref target="RFC4301"/>. When the path is entirely within a trusted hardware boundary (e.g., shared memory on the same board), hardware-level access controls MAY be sufficient.</t>
<t>Switchover is time-critical. If the newly active processor is unable to begin BFD processing promptly -- for instance, due to a denial-of-service condition exhausting CPU resources -- BFD sessions will time out despite having state available. Implementations SHOULD ensure that switchover-related BFD processing is appropriately prioritized and isolated from general-purpose control plane tasks.</t>
</section>
<section anchor="iana-considerations" numbered="true" toc="include"><name>IANA Considerations</name>
<t>This document has no IANA actions.</t>
</section>
  </middle>

  <back>
      <references title="Normative References">
    <reference anchor="RFC2119" target="https://www.rfc-editor.org/info/rfc2119">
      <front>
        <title>Key words for use in RFCs to Indicate Requirement Levels</title>
        <author initials="S." surname="Bradner" fullname="Scott Bradner"/>
        <date year="1997" month="March"/>
      </front>
      <seriesInfo name="BCP" value="14"/>
      <seriesInfo name="RFC" value="2119"/>
      <seriesInfo name="DOI" value="10.17487/RFC2119"/>
    </reference>
    <reference anchor="RFC5880" target="https://www.rfc-editor.org/info/rfc5880">
      <front>
        <title>Bidirectional Forwarding Detection (BFD)</title>
        <author initials="D." surname="Katz" fullname="Dave Katz"/>
        <author initials="D." surname="Ward" fullname="David Ward"/>
        <date year="2010" month="June"/>
      </front>
      <seriesInfo name="RFC" value="5880"/>
      <seriesInfo name="DOI" value="10.17487/RFC5880"/>
    </reference>
    <reference anchor="RFC8174" target="https://www.rfc-editor.org/info/rfc8174">
      <front>
        <title>Ambiguity of Uppercase vs Lowercase in RFC 2119 Key Words</title>
        <author initials="B." surname="Leiba" fullname="Barry Leiba"/>
        <date year="2017" month="May"/>
      </front>
      <seriesInfo name="BCP" value="14"/>
      <seriesInfo name="RFC" value="8174"/>
      <seriesInfo name="DOI" value="10.17487/RFC8174"/>
    </reference>
    <reference anchor="IEEE802.1AE">
      <front>
        <title>IEEE Standard for Local and Metropolitan Area Networks: Media Access Control (MAC) Security</title>
        <author fullname="IEEE">
          <organization>IEEE</organization>
        </author>
        <date year="2018"/>
      </front>
      <seriesInfo name="IEEE" value="802.1AE-2018"/>
    </reference>
    <reference anchor="RFC4301" target="https://www.rfc-editor.org/info/rfc4301">
      <front>
        <title>Security Architecture for the Internet Protocol</title>
        <author initials="S." surname="Kent" fullname="Stephen Kent"/>
        <author initials="K." surname="Seo" fullname="Karen Seo"/>
        <date year="2005" month="December"/>
      </front>
      <seriesInfo name="RFC" value="4301"/>
      <seriesInfo name="DOI" value="10.17487/RFC4301"/>
    </reference>
    <reference anchor="RFC5881" target="https://www.rfc-editor.org/info/rfc5881">
      <front>
        <title>Bidirectional Forwarding Detection (BFD) for IPv4 and IPv6 (Single Hop)</title>
        <author initials="D." surname="Katz" fullname="Dave Katz"/>
        <author initials="D." surname="Ward" fullname="David Ward"/>
        <date year="2010" month="June"/>
      </front>
      <seriesInfo name="RFC" value="5881"/>
      <seriesInfo name="DOI" value="10.17487/RFC5881"/>
    </reference>
      </references>
      <references title="Informative References">
    <reference anchor="RFC5882" target="https://www.rfc-editor.org/info/rfc5882">
      <front>
        <title>Generic Application of Bidirectional Forwarding Detection (BFD)</title>
        <author initials="D." surname="Katz" fullname="Dave Katz"/>
        <author initials="D." surname="Ward" fullname="David Ward"/>
        <date year="2010" month="June"/>
      </front>
      <seriesInfo name="RFC" value="5882"/>
      <seriesInfo name="DOI" value="10.17487/RFC5882"/>
    </reference>
    <reference anchor="RFC7130" target="https://www.rfc-editor.org/info/rfc7130">
      <front>
        <title>Bidirectional Forwarding Detection (BFD) on Link Aggregation Group (LAG) Interfaces</title>
        <author initials="M." surname="Bhatia" fullname="Manav Bhatia"/>
        <author initials="M." surname="Chen" fullname="Mach Chen"/>
        <author initials="S." surname="Boutros" fullname="Sami Boutros"/>
        <author initials="M." surname="Binderberger" fullname="Manuel Binderberger"/>
        <author initials="J." surname="Haas" fullname="Jeff Haas"/>
        <date year="2014" month="February"/>
      </front>
      <seriesInfo name="RFC" value="7130"/>
      <seriesInfo name="DOI" value="10.17487/RFC7130"/>
    </reference>
    <reference anchor="RFC7880" target="https://www.rfc-editor.org/info/rfc7880">
      <front>
        <title>Seamless Bidirectional Forwarding Detection (S-BFD)</title>
        <author initials="C." surname="Pignataro" fullname="Carlos Pignataro"/>
        <author initials="D." surname="Ward" fullname="David Ward"/>
        <author initials="N." surname="Akiya" fullname="Nobo Akiya"/>
        <author initials="M." surname="Bhatia" fullname="Manav Bhatia"/>
        <author initials="S." surname="Pallagatti" fullname="Santosh Pallagatti"/>
        <date year="2016" month="July"/>
      </front>
      <seriesInfo name="RFC" value="7880"/>
      <seriesInfo name="DOI" value="10.17487/RFC7880"/>
    </reference>
      </references>
      <section anchor="acknowledgements" numbered="false" toc="include">
        <name>Acknowledgements</name>
        <t>The authors would like to thank the members of the BFD Working Group for their review and feedback.</t>
      </section>
  </back>
</rfc>
