<?xml version="1.0" encoding="UTF-8"?>
  <?xml-stylesheet type="text/xsl" href="rfc2629.xslt" ?>
  <!-- generated by https://github.com/cabo/kramdown-rfc version 1.6.17 (Ruby 2.6.10) -->


<!DOCTYPE rfc  [
  <!ENTITY nbsp    "&#160;">
  <!ENTITY zwsp   "&#8203;">
  <!ENTITY nbhy   "&#8209;">
  <!ENTITY wj     "&#8288;">

]>


<rfc ipr="trust200902" docName="draft-spd-grow-bmp-purge-00" category="std" consensus="true" submissionType="IETF" tocInclude="true" sortRefs="true" symRefs="true">
  <front>
    <title abbrev="BMP RIB Purge Notification">Support for BMP RIB Purge Notification</title>

    <author initials="T." surname="Saad" fullname="Tarek Saad">
      <organization>Cisco Systems, Inc.</organization>
      <address>
        <email>tsaad@cisco.com</email>
      </address>
    </author>
    <author initials="P." surname="Narasimha" fullname="Prasad S. Narasimha">
      <organization>Cisco Systems, Inc.</organization>
      <address>
        <email>snprasad@cisco.com</email>
      </address>
    </author>

    <date year="2025" month="February" day="26"/>

    
    <workgroup>Network Working Group</workgroup>
    <keyword>Internet-Draft</keyword>

    <abstract>


<t>This document describes a mechanism to notify a BMP collector of the need to
purge the state associated with a RIB view of a specific peer. This is useful,
for example, when the BMP sender decides to stop exporting a specific RIB view
after providing an initial export. The BMP collector can use the per-peer Purge
message to take appropriate action to remove the stale state and avoid holding
on to irrelevant network data.</t>



    </abstract>



  </front>

  <middle>


<section anchor="introduction"><name>Introduction</name>

<t>The BGP Monitoring Protocol (BMP) defines means to access and monitor
multiple Routing Information Base (RIB) views on per peer of a router.
<xref target="RFC7854"/> and <xref target="RFC8671"/> define mechanisms to export the pre and post policy views
of the (Adj-RIB-In and Adj-RIB-Out), while <xref target="RFC9069"/> defines the mechanisms
to access the Loc-RIB view.</t>

<t>The BMP sender (e.g. router) uses the flags present in the Per-Peer Header of the BMP message
to distinguish whether the BMP updates are for the pre-policy or post-policy of the
Adj-RIB-In, or Adj-RIB-Out views. For the Loc-RIB updates, the BMP sender uses the Peer Type
field in the BMP Peer Header to indicate updates are for the Loc-RIB view.</t>

<t>A BMP sender can stop exporting a RIB view to a BMP collector at any time after
the initial export. For example, the BMP sender might decide to halt the export
of the Adj-RIB-Out view of a specific peer to the BMP collector due to a policy
or configuration change. Currently, the BMP collector is not informed about
these changes in the RIB view export policy and continues to maintain the stale
state, which may no longer be relevant to the current network situation. To
address this, the BMP sender can terminate and restart the BMP session,
prompting the BMP collector to rebuild the BMP RIB views based on the new
policies. However, doing so each time such changes occur may be undesirable or
impractical, especially in high-scale environments, where rebuilding the BMP
views after a session restart could take several minutes.</t>

<t>This document defines a new flag from the per peer header flags that is used in a BMP
message to notify the BMP collector to purge any previously exported state
for a specific RIB view of a peer. The BMP sender can use the per peer Purge notification at
anytime after the BMP session is established to purge any previously stored state for the
specific peer and RIB view.</t>

<t>This document introduces a new flag within the per-peer header flags to be used in a
BMP message to notify the BMP collector to purge any previously exported state
for a RIB view of a peer. The BMP sender can utilize the per-peer
Purge notification message at any time after the BMP session is established to remove
the previously stored state for the specific peer and RIB view on the BMP collector.</t>

<section anchor="terminology"><name>Terminology</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>

<t>The terminology for describing YANG data models is found in <xref target="RFC7950"/>.</t>

</section>
</section>
<section anchor="per-peer-header"><name>Per-Peer Header</name>

<t>The per-peer header was initially defined <xref target="RFC7854"/>. It includes a set of flags that
are defined in <xref target="RFC7854"/> and <xref target="RFC8671"/>.</t>

<t>This document extends the per-peer header to include a new flag, the P flag, to indicate
that the BMP sender is requesting the BMP collector to purge the state associated with the
specific RIB view of the peer. The P flag is defined as follows:</t>

<figure title="The BMP per-peer header flags." anchor="Fig1"><artwork><![CDATA[
 0 1 2 3 4 5 6 7
 +-+-+-+-+-+-+-+-+
 |V|L|A|O|P|Resv |
 +-+-+-+-+-+-+-+-+
]]></artwork></figure>

<t><list style="symbols">
  <t>The P flag, when set, indicates that a purge is requested for the specific RIB view of the peer. In combination with
the O and L flags, the BMP collector can determine which RIB view is being purged.</t>
</list></t>

<t>The remaining bits are reserved for future use and MUST be set to 0 by the BMP sender and ignored by the BMP collector.</t>

</section>
<section anchor="bmp-messages"><name>BMP Messages</name>

<t>The per-peer header follows the common header for most BMP messages.
A Purge BMP message is a BMP Route Monitoring or Route Mirroring message
that has the P flag set in the per-peer header. The Purge message MUST only
contain the MP_UNREACH_NLRI attribute <xref target="RFC2858"/> with no withdrawn routes similar to the End-of-RIB marker
in Section 2 of <xref target="RFC4724"/>.</t>

<t>For other BMP messages that contain the per-peer header, the P flag MUST be set to 0.</t>

</section>
<section anchor="security-considerations"><name>Security Considerations</name>

<t>The considerations in Section 11 of <xref target="RFC7854"></xref> apply to this document.
Implementations of this protocol SHOULD require establishing sessions
with authorized and trusted monitoring devices.  It is also believed
that this document does not add any additional security
considerations.</t>

</section>
<section anchor="iana-considerations"><name>IANA Considerations</name>

<t>IANA has assigned the following new parameters to the "BGP Monitoring Protocol (BMP) Parameters" registry
(https://www.iana.org/assignments/bmp-parameters/).</t>

<section anchor="addition-to-bmp-peer-flags-registry"><name>Addition to BMP Peer Flags Registry</name>

<t>IANA is requested to assign a new flag to the "Per-Peer Header Flags" registry as follow:</t>

<figure><artwork><![CDATA[
   +------+-------------+---------------+
   | Flag | Description | Reference     |
   +======+=============+===============+
   | 4    | P flag      | this document |
   +------+-------------+---------------+

    Table 1: Addition to the "BMP Peer Flags" Registry
]]></artwork></figure>

</section>
</section>


  </middle>

  <back>


    <references title='Normative References'>



<reference anchor='RFC7854' target='https://www.rfc-editor.org/info/rfc7854'>
  <front>
    <title>BGP Monitoring Protocol (BMP)</title>
    <author fullname='J. Scudder' initials='J.' role='editor' surname='Scudder'/>
    <author fullname='R. Fernando' initials='R.' surname='Fernando'/>
    <author fullname='S. Stuart' initials='S.' surname='Stuart'/>
    <date month='June' year='2016'/>
    <abstract>
      <t>This document defines the BGP Monitoring Protocol (BMP), which can be used to monitor BGP sessions. BMP is intended to provide a convenient interface for obtaining route views. Prior to the introduction of BMP, screen scraping was the most commonly used approach to obtaining such views. The design goals are to keep BMP simple, useful, easily implemented, and minimally service affecting. BMP is not suitable for use as a routing protocol.</t>
    </abstract>
  </front>
  <seriesInfo name='RFC' value='7854'/>
  <seriesInfo name='DOI' value='10.17487/RFC7854'/>
</reference>

<reference anchor='RFC8671' target='https://www.rfc-editor.org/info/rfc8671'>
  <front>
    <title>Support for Adj-RIB-Out in the BGP Monitoring Protocol (BMP)</title>
    <author fullname='T. Evens' initials='T.' surname='Evens'/>
    <author fullname='S. Bayraktar' initials='S.' surname='Bayraktar'/>
    <author fullname='P. Lucente' initials='P.' surname='Lucente'/>
    <author fullname='P. Mi' initials='P.' surname='Mi'/>
    <author fullname='S. Zhuang' initials='S.' surname='Zhuang'/>
    <date month='November' year='2019'/>
    <abstract>
      <t>The BGP Monitoring Protocol (BMP) only defines access to the Adj-RIB-In Routing Information Bases (RIBs). This document updates BMP (RFC 7854) by adding access to the Adj-RIB-Out RIBs. It also adds a new flag to the peer header to distinguish between Adj-RIB-In and Adj-RIB-Out.</t>
    </abstract>
  </front>
  <seriesInfo name='RFC' value='8671'/>
  <seriesInfo name='DOI' value='10.17487/RFC8671'/>
</reference>

<reference anchor='RFC9069' target='https://www.rfc-editor.org/info/rfc9069'>
  <front>
    <title>Support for Local RIB in the BGP Monitoring Protocol (BMP)</title>
    <author fullname='T. Evens' initials='T.' surname='Evens'/>
    <author fullname='S. Bayraktar' initials='S.' surname='Bayraktar'/>
    <author fullname='M. Bhardwaj' initials='M.' surname='Bhardwaj'/>
    <author fullname='P. Lucente' initials='P.' surname='Lucente'/>
    <date month='February' year='2022'/>
    <abstract>
      <t>The BGP Monitoring Protocol (BMP) defines access to local Routing
Information Bases (RIBs). This document updates BMP (RFC 7854) by
adding access to the Local Routing Information Base (Loc-RIB), as
defined in RFC 4271. The Loc-RIB contains the routes that have been
selected by the local BGP speaker's Decision Process.</t>
    </abstract>
  </front>
  <seriesInfo name='RFC' value='9069'/>
  <seriesInfo name='DOI' value='10.17487/RFC9069'/>
</reference>

<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 fullname='S. Bradner' initials='S.' surname='Bradner'/>
    <date month='March' year='1997'/>
    <abstract>
      <t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
    </abstract>
  </front>
  <seriesInfo name='BCP' value='14'/>
  <seriesInfo name='RFC' value='2119'/>
  <seriesInfo name='DOI' value='10.17487/RFC2119'/>
</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 fullname='B. Leiba' initials='B.' surname='Leiba'/>
    <date month='May' year='2017'/>
    <abstract>
      <t>RFC 2119 specifies common key words that may be used in protocol specifications. This document aims to reduce the ambiguity by clarifying that only UPPERCASE usage of the key words have the defined special meanings.</t>
    </abstract>
  </front>
  <seriesInfo name='BCP' value='14'/>
  <seriesInfo name='RFC' value='8174'/>
  <seriesInfo name='DOI' value='10.17487/RFC8174'/>
</reference>

<reference anchor='RFC7950' target='https://www.rfc-editor.org/info/rfc7950'>
  <front>
    <title>The YANG 1.1 Data Modeling Language</title>
    <author fullname='M. Bjorklund' initials='M.' role='editor' surname='Bjorklund'/>
    <date month='August' year='2016'/>
    <abstract>
      <t>YANG is a data modeling language used to model configuration data, state data, Remote Procedure Calls, and notifications for network management protocols. This document describes the syntax and semantics of version 1.1 of the YANG language. YANG version 1.1 is a maintenance release of the YANG language, addressing ambiguities and defects in the original specification. There are a small number of backward incompatibilities from YANG version 1. This document also specifies the YANG mappings to the Network Configuration Protocol (NETCONF).</t>
    </abstract>
  </front>
  <seriesInfo name='RFC' value='7950'/>
  <seriesInfo name='DOI' value='10.17487/RFC7950'/>
</reference>

<reference anchor='RFC2858' target='https://www.rfc-editor.org/info/rfc2858'>
  <front>
    <title>Multiprotocol Extensions for BGP-4</title>
    <author fullname='T. Bates' initials='T.' surname='Bates'/>
    <author fullname='Y. Rekhter' initials='Y.' surname='Rekhter'/>
    <author fullname='R. Chandra' initials='R.' surname='Chandra'/>
    <author fullname='D. Katz' initials='D.' surname='Katz'/>
    <date month='June' year='2000'/>
    <abstract>
      <t>This document defines extensions to BGP-4 to enable it to carry routing information for multiple Network Layer protocols (e.g., IPv6, IPX, etc...). [STANDARDS-TRACK]</t>
    </abstract>
  </front>
  <seriesInfo name='RFC' value='2858'/>
  <seriesInfo name='DOI' value='10.17487/RFC2858'/>
</reference>

<reference anchor='RFC4724' target='https://www.rfc-editor.org/info/rfc4724'>
  <front>
    <title>Graceful Restart Mechanism for BGP</title>
    <author fullname='S. Sangli' initials='S.' surname='Sangli'/>
    <author fullname='E. Chen' initials='E.' surname='Chen'/>
    <author fullname='R. Fernando' initials='R.' surname='Fernando'/>
    <author fullname='J. Scudder' initials='J.' surname='Scudder'/>
    <author fullname='Y. Rekhter' initials='Y.' surname='Rekhter'/>
    <date month='January' year='2007'/>
    <abstract>
      <t>This document describes a mechanism for BGP that would help minimize the negative effects on routing caused by BGP restart. An End-of-RIB marker is specified and can be used to convey routing convergence information. A new BGP capability, termed "Graceful Restart Capability", is defined that would allow a BGP speaker to express its ability to preserve forwarding state during BGP restart. Finally, procedures are outlined for temporarily retaining routing information across a TCP session termination/re-establishment.</t>
      <t>The mechanisms described in this document are applicable to all routers, both those with the ability to preserve forwarding state during BGP restart and those without (although the latter need to implement only a subset of the mechanisms described in this document). [STANDARDS-TRACK]</t>
    </abstract>
  </front>
  <seriesInfo name='RFC' value='4724'/>
  <seriesInfo name='DOI' value='10.17487/RFC4724'/>
</reference>




    </references>




  </back>

<!-- ##markdown-source:
H4sIAChNv2cAA61YbW8bNxL+zl8x53xJ7rSK7XPiRECAUxw7FuAX1XZ6KIoi
oHYpiZfd5ZbkSlVj57ffzJC7Wr001wLnFtGKIjkzD595ZrhJkgivfa4GcF9X
lbEepsbC++sx3I3ew7i2MwU3xuupTqXXphRyMrFqMfjelMykpSxwy8zKqU9c
lSUza5bJpKiSiqYnh4cC56qZsasBOJ8JXdkBeFs7f3x4+PbwWCyN/YKL6moA
N8rTN/g3/qPLGXykYfFFrXA0G8Co9MqWyicfyJpw9aTQzqEfD6sKfRidP1wI
4bwss88yNyUOrZQTlR7Az96kPXAYtFVTh0+rgh5+EULWfm7sQEAiAP906Qbw
0Id7KTMeCOE9SKu+rAeNnclS/84YDOBMu9TA/cp5VeDeozLt8yxVSJ1jrA6X
/SulSf3UFBuWxn24kVY6Xcxlx9wYh2QG99u//iW7rqx4m45pIUpjC1y+UAMh
dDntfEuSBOTEeStTL8TDXDvA060LVXrIlEutnigHEgqVztEJV4A3UBIZVjhK
HElNnqvUI6nMFPxcQalUhrMEM4FH8HC8AumcSTU+ZbDUfo7LiV4LrZa0UoKr
VEocg0op2wf2Bf+vnZrWeU8QbdVvsqhy1YPlXJW8NXngVJkpi+6mGl0mB503
FU4muhOhOns3JgVSCddU1ix0xnNKPBvttczjQvJAbUWY4iz0hy1XyibkaUgQ
USjnJMVrwMsvGG2Fe1dWc+QpHR39ZFVhFi0oeQtNmYFcGJ3B3OTkjgjTtbUq
VwuJh1HGJMmkl/1wboXOslwJ8YxSxJqsZjN0iuj3xzFcGwzIWIpubA3mgsnh
OQb0AqGa6hKhKpQsGTCZpug/+1GEVaKoc68RbLgzNaM4aoiDvr2XiMJzBPMF
o+kAxyrCkwDh08QcRoD74uvXv91dnJ2+eXXy9MT7h4E3r0+PcCA4smYXOxPw
DyDbAE5lnMd/cp2ugkERyfZ8mP0nQT+SUckTm6+3tX9BNNEYQLD49vD129ai
48Vrs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