<!DOCTYPE html>
<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
  </head>
  <body>
    <p>Hi Matthieu,<br>
      <br>
      thanks a lot for the patch of BMP in v3!<br>
      I put it in our internal backlog and as soon as this busy period*
      is over, we will review it and hopefully merge it.<br>
      Then we can also proceed further in the Adj-RIB-Out post-policy
      support.<br>
      <br>
      You mentioned that you rely on BMP quite a lot, can I ask you
      which BMP listener do you use?<br>
      I will soon get back to writing a test for BMP (initially prompted
      by your previous mail concerning BMP in v3) and I would be curious
      about your actual setup.<br>
      Will most likely use Rotonda and/or pmbmpd utility, but maybe you
      are using something else entirely.<br>
      <br>
      WIP of the test can be seen on a branch here: 
<a class="moz-txt-link-freetext" href="https://gitlab.nic.cz/labs/bird-tools/-/tree/bmp_test/netlab/cf-bgp-bmp?ref_type=heads">https://gitlab.nic.cz/labs/bird-tools/-/tree/bmp_test/netlab/cf-bgp-bmp?ref_type=heads</a> <br>
      (note it is not in a working state yet)<br>
      <br>
      I would also like the test to be ready for the eventual support of
      Adj-RIB-Out post-policy. <br>
      <br>
      Thanks again and happy routing!<br>
      David<br>
      <br>
      *most of our team is either finishing EVPN or writing drafts for
      the upcoming IETF))</p>
    <pre class="moz-signature" cols="72">David Petera (he/him) | BIRD Tech Support | CZ.NIC, z.s.p.o.</pre>
    <div class="moz-cite-prefix">On 1/15/26 11:50, Matthieu Gouel via
      Bird-users wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:8TYWLbGrb0K5l1qAc2mSX0MYK_nJrFOUwvDPdheGPDu3S6seLrkgU0qZiq9U3XTUYfBIMfwk1-RRzum1qCR7BisTKD16ShpxaFhQotPJ0hY=@nxthdr.dev">
      <meta http-equiv="content-type" content="text/html; charset=UTF-8">
      <div style="font-family: Arial, sans-serif; font-size: 14px;">
        <p>Dear Maria,</p>
        <p>Thanks a lot for the review and for the pointers!</p>
        <p>Indeed, my initial patch is wrong. I was sourcing updates
          from the main table, which effectively means I was exporting
          the RIB as updates and calling that ADJ-RIB-Out.</p>
        <p>I tried to fix the implementation to use the actual <code>out_table</code>,
          but I kept running into crashes. From what I can tell, this is
          because the out table is an internal table and I didn’t manage
          to correctly create or attach a channel to it without hitting
          invalid states. </p>
        <p>Given your comment about <code>thread-next</code> handling <code>out_table</code>
          very differently, I wondered whether it might make more sense
          to target that branch instead. Before going further in that
          direction, I wanted to double-check that BMP ADJ-RIB-In Route
          Monitoring was working properly there first.</p>
        <p>I had a suspicion it wasn’t, since I had already tested early
          BIRD v3 releases back when they came out and saw issues at the
          time (mentioned it on the mailing list but that was a busy
          period). After retesting, it turns out ADJ-RIB-In RM was
          indeed broken: my collector was only receiving End-of-RIB
          messages, with no actual route updates.</p>
        <p>Since I had a good test setup handy, I dug into it and found
          a few issues that prevented IPv4 and IPv6 updates from being
          sent as BMP Route Monitoring messages. Here is the result:</p>
        <p><a
href="https://github.com/matthieugouel/bird/commit/835ea3fae7f162105621bd773a078bd7ad36ec4d"
            moz-do-not-send="true" class="moz-txt-link-freetext">https://github.com/matthieugouel/bird/commit/835ea3fae7f162105621bd773a078bd7ad36ec4d</a></p>
        <p>I compared the BMP output against BIRD v2 and got matching
          behavior, using v2 as the reference. That said, given my C
          skills, this would definitely need a careful review before
          merging.</p>
        <p>This is a bit of a detour from the original ADJ-RIB-Out goal,
          but I think getting the current BMP implementation in v3 into
          a solid state is probably a good first step before extending
          it further.</p>
        <p>Thanks again for the feedback, happy to iterate or adjust
          direction based on what you think makes the most sense.</p>
        <p>Best,<br>
          Matthieu</p>
        <br>
      </div>
      <div class="protonmail_quote"> On Wednesday, 14 January 2026 at
        15:39, Maria Matejka via Bird-users
        <a class="moz-txt-link-rfc2396E" href="mailto:bird-users@network.cz"><bird-users@network.cz></a> wrote:<br>
        <blockquote class="protonmail_quote" type="cite">
          <p>Dear Matthieu,</p>
          <p>thank you for your patch!</p>
          <p>On Wed, Jan 14, 2026 at 07:50:29AM +0000, Matthieu Gouel
            via
            Bird-users wrote:</p>
          <blockquote>
            <p>Currently, the (preliminary) BMP protocol implementation
              in BIRD does
              not support ADJ-RIB-Out monitoring. Only ADJ-RIB-In pre-
              and post-policy
              are supported at the moment.</p>
            <p>I have implemented support for ADJ-RIB-Out post-policy
              monitoring,
              which is relatively straightforward to add. The proposed
              implementation
              is available here:</p>
            <p><a class="moz-txt-link-freetext" href="https://github.com/CZ-NIC/bird/compare/master…matthieugouel:bird:bmp-adj-rib-out">https://github.com/CZ-NIC/bird/compare/master…matthieugouel:bird:bmp-adj-rib-out</a></p>
            <p>I have not implemented ADJ-RIB-Out pre-policy yet, as
              this would
              require more intrusive changes related to export tables.</p>
          </blockquote>
          <p>I suspect that you don’t export from the <code>out_table</code>
            actually, you are using the main table instead if I read
            your patch
            correctly.</p>
          <p>Also, your commit is missing documentation in
            <code>doc/bird.sgml</code>, as well as supported RFC in
            <code>proto/bmp/bmp.c</code> header.</p>
          <p>You should also check mergability of your patch with the
            thread-next
            branch, as if I remember correctly, the out_table is
            implemented there
            completely differently.</p>
          <p>Last but not least, I would love to see a commit on top of
            <a class="moz-txt-link-freetext" href="https://gitlab.nic.cz/labs/bird-tools/">https://gitlab.nic.cz/labs/bird-tools/</a> in the <code>netlab</code>
            folder
            as an automatic test suite. David Petera (cc) is currently
            working on
            BMP tests for other scenarios, and it might be worth
            consulting this
            topic with him.</p>
          <blockquote>
            <p>I would be interested to know whether this is something
              you would
              consider merging. More generally, is there interest in
              extending BMP
              support in BIRD with additional features? I know that BMP
              is still
              marked as preliminary and not production-ready, but it is
              a protocol I
              personally rely on quite heavily.</p>
          </blockquote>
          <p>BMP should be production-worthy and we do consider merging
            BMP
            extensions.</p>
          <p>Please note, however, that BGP export is a very hot path
            and one
            should very much think about what is being done there,
            performance-wise.
            That deserves at least a warning in the documentation, so
            that somebody
            doesn’t unknowingly turn their router into a traffic
            generator.</p>
          <p>More specifically, the BMP implementation still severely
            lacks update
            merging, and there have been some very serious thoughts
            about merging
            the BMP TX with BGP TX data structures (which would do the
            update
            merging). With that, I would suggest informing us about your
            plans
            beforehand, so that we can plan around accordingly.</p>
          <p>Have a nice day!<br>
            Maria</p>
          <p>–<br>
            Maria Matejka (she/her) | BIRD Team Leader | CZ.NIC,
            z.s.p.o.</p>
        </blockquote>
        <br>
      </div>
    </blockquote>
  </body>
</html>