<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE rfc SYSTEM "rfc2629-xhtml.ent">
<?rfc toc="yes"?>
<?rfc tocompact="yes"?>
<?rfc tocdepth="3"?>
<?rfc tocindent="yes"?>
<?rfc symrefs="yes"?>
<?rfc sortrefs="yes"?>
<?rfc comments="yes"?>
<?rfc inline="yes"?>
<?rfc compact="yes"?>
<?rfc subcompact="no"?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" category="std" docName="draft-ietf-ippm-stamp-on-lag-05" ipr="trust200902" submissionType="IETF" tocInclude="true" sortRefs="true" consensus="true">
  <front>
    <title abbrev="STAMP PM on LAG">Simple Two-Way Active Measurement Protocol
    Extensions for Performance Measurement on LAG</title>

    <author fullname="Zhenqiang Li" initials="Z." surname="Li">
      <organization>China Mobile</organization>

      <address>
        <postal>
          <street>No. 29 Finance Avenue, Xicheng District</street>

          <city>Beijing</city>

          <code/>

          <country>China</country>
        </postal>

        <email>li_zhenqiang@hotmail.com</email>
      </address>
    </author>

    <author fullname="Tianran Zhou" initials="T." surname="Zhou">
      <organization>Huawei</organization>

      <address>
        <postal>
          <street/>

          <country>China</country>
        </postal>

        <email>zhoutianran@huawei.com</email>
      </address>
    </author>

    <author fullname="Jun Guo" initials="J." surname="Guo">
      <organization>ZTE Corp.</organization>

      <address>
        <postal>
          <street/>

          <city/>

          <region/>

          <code/>

          <country>China</country>
        </postal>

        <phone/>

        <facsimile/>

        <email>guo.jun2@zte.com.cn</email>

        <uri/>
      </address>
    </author>

    <author fullname="Greg Mirsky" initials="G." surname="Mirsky">
      <organization>Ericsson</organization>

      <address>
        <postal>
          <street/>

          <country>United States of America</country>
        </postal>

        <email>gregimirsky@gmail.com</email>
      </address>
    </author>

    <author fullname="Rakesh Gandhi" initials="R." surname="Gandhi">
      <organization>Cisco</organization>

      <address>
        <postal>
          <street/>

          <city/>

          <region/>

          <code/>

          <country>Canada</country>
        </postal>

        <phone/>

        <facsimile/>

        <email>rgandhi@cisco.com</email>

        <uri/>
      </address>
    </author>

    <date year="2023"/>
    <area>Transport</area>
    <workgroup>IPPM</workgroup>

    <abstract>
      <t>This document extends Simple Two-Way Active Measurement Protocol
      (STAMP) to implement performance measurement on every member link of a
      Link Aggregation Group (LAG). Knowing the measured metrics of each
      member link of a LAG enables operators to enforce a performance based
      traffic steering policy across the member links.</t>
    </abstract>

    <note title="Requirements Language">
      <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 <xref
      target="RFC2119"/> <xref target="RFC8174"/> when, and only when, they
      appear in all capitals, as shown here.</t>
    </note>
  </front>

  <middle>
    <section title="Introduction">
      <t>Link Aggregation Group (LAG), as defined in <xref
      target="IEEE802.1AX"/>, provides mechanisms to combine multiple physical
      links into a single logical link. This logical link offers higher
      bandwidth and better resiliency, because if one of the physical member
      links fails, the aggregate logical link can continue to forward traffic
      over the remaining operational physical member links.</t>

      <t>Usually, when forwarding traffic over LAG, the hash-based mechanism
      is used to load balance the traffic across the LAG member links. Link
      delay of each member link varies because of different transport paths.
      To provide low latency service for time sensitive traffic, we need to
      explicitly steer the traffic across the LAG member links based on the
      link delay, loss and so on. That requires a solution to measure the
      performance metrics of each member link of a LAG. Hence the measured
      performance metrics can work together with <xref target="RFC8668">layer
      2 bundle member link attributes advertisement</xref> for traffic
      steering.</t>

      <t><xref target="RFC8762">Simple Two-Way Active Measurement Protocol
      (STAMP)</xref> is an active measurement method according to the
      classification given in <xref target="RFC7799"/>, which can complement
      passive and hybrid methods. It provides a mechanism to measure both
      one-way and round-trip performance metrics, like delay, delay variation,
      and packet loss. Running a single STAMP test session over the
      aggregation without the knowledge of each member link would make it
      impossible to measure the performance of a given physical member link.
      The measured metrics can only reflect the performance of one member link
      or an average of some/all member links of the LAG.</t>

      <t>This document extends STAMP to implement performance measurement on
      every member link of a LAG. It can provide the same metrics as OWAMP and
      TWAMP can measure, such as delay, jitter, and packet loss. </t>

<t>The proposed
      method could also potentially apply to layer 3 ECMP (Equal Cost
      Multi-Path), e.g., with <xref target="RFC9256">Segment Routing
      Policy</xref>. The details are for future work, and not in the scope of this document</t>
    </section>

    <section title="Micro Session on LAG">
      <t>This document intends to address the scenario (e.g., <xref
      target="PMonLAG"/>) where a LAG (e.g., the LAG includes four member
      links) directly connects two nodes (A and B) . The goal is to measure
      the performance of each link of the LAG.</t>

      <figure align="center" anchor="PMonLAG" title="PM on LAG">
        <artwork><![CDATA[+---+                       +---+
|   |-----------------------|   | 
| A |-----------------------| B | 
|   |-----------------------|   |
|   |-----------------------|   |
+---+                       +---+
]]></artwork>
      </figure>

      <t>To measure the performance metrics of every member link of a LAG,
      multiple sessions (one session for each member link) need to be
      established between the two end points that are connected by the LAG.
      These sessions are called micro sessions in the remainder of this
      document. Although micro sessions, indicated by <xref target="RFC8972">SSID</xref>, are in fact STAMP sessions estabilished on member links of a LAG, test packets of micro sessions are RECOMMENDED to carry member link information for validation, as stated below.</t>

      <t>All micro sessions of a LAG share the same Sender IP Address and
      Receiver IP Address of the LAG. As for the UDP Port, the micro sessions
      may share the same Sender Port and Receiver Port pair, or each micro
      session is configured with a different Sender Port and Receiver Port
      pair. But from the operational point of view, the former is simpler and
      is RECOMMENDED.</t>

      <t>At the Sender side, each micro STAMP session MUST be assigned with a
      unique <xref target="RFC8972">SSID</xref>. Both the micro STAMP Session
      Sender and Reflector MUST use SSID to correlate the test packet to a
      micro session. If there is no such a session, or the SSID is not
      correct, the test packet MUST be discarded.</t>

      <t>Test packets MAY carry the member link information for validation
      check, which is RECOMMENDED. For example, when a micro STAMP Session-Sender receives a
      reflected test packet, it may need to check whether the test packet is
      from the expected member link. The member link information is encoded in the Micro-session ID TLV introduced in section 3 of this document and the detailed description about the member
      link validation is also in this section.</t>

      <t>A micro STAMP Session-Sender MAY include the <xref
      target="RFC8972">Follow-Up Telemetry TLV</xref> to request information
      from the micro Session-Reflector. This timestamp might be important for
      the micro Session-Sender, as it improves the accuracy of network delay
      measurement by minimizing the impact of egress queuing delays on the
      measurement.</t>
    </section>

    <section title="Member Link Validation">
      <t>Test packets are RECOMMENDED to carry member link information in Micro-session ID TLV introdued in this section for validation check.
      The micro Session Sender can verify whether the test packet is reveived
      from the expected member link. It can also verify whether the packet is
      sent from the expected member link at the Reflector side. The micro
      Session Reflector can verify whether the test packet is received from
      the expected member link.</t>

      <section title="Micro-session ID TLV">
        <t><xref target="RFC8972">STAMP TLV</xref> mechanism extends STAMP
        test packets with one or more optional TLVs. This document defines the
        TLV Type (value TBA1) for the Micro-session ID TLV that carries the
        micro STAMP Session-Sender member link identifier and Session-Reflector member link identifier in Sender Micro-session ID field and
        Reflector Micro-session ID field respectively. The format of the
        Micro-session ID TLV is shown as follows:</t>

        <t><figure align="center" anchor="STAMPSender" title="Micro-session ID TLV">
            <artwork><![CDATA[    0                   1                   2                   3
    0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |STAMP TLV Flags|  Type = TBA1  |           Length              |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
   |     Sender Micro-session ID   |   Reflector Micro-session ID  |
   +-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
]]></artwork>
          </figure><list style="symbols">
            <t>Type (one-octet in length): It is defined to indicate this TLV is a Micro-session ID TLV. Value TBA1 is allocated by IANA
            (Section 5).</t>

            <t>Length (2-octets in length): It is defined to carry the length of the Value field in octets. The Length field value MUST be 4.</t>

            <t>Sender Micro-session ID (2-octets in length): It is now defined to
            carry the LAG member link identifier of the Sender side. In the future, it may be used generically to cover use-cases beyond LAG. The value
            of this field MUST be unique within a STAMP session indicated by <xref target="RFC8972">SSID</xref> at the Session-Sender.</t>

            <t>Reflector Micro-session ID (2-octets in length): It is now defined
            to carry the LAG member link identifier of the Reflector side. In the future, it may be used generically to cover use-cases beyond LAG. The
            value of this field MUST be unique within a STAMP session indicated by <xref target="RFC8972">SSID</xref> at the
            Session-Reflector.</t>
          </list></t>
      </section>

      <section title="Micro STAMP-Test Procedures">
        <t>The micro STAMP-Test reuses the procedures as defined in Section 4
        of <xref target="RFC8762">STAMP</xref> with the following
        additions.</t>

        <t>The micro STAMP Session-Sender MUST send the micro STAMP-Test
        packets over the member link with which the session is associated. The
        configuration and management of the mapping between a micro STAMP
        session and the Sender/Reflector member link identifiers are outside
        the scope of this document.</t>

        <t>When sending a test packet, the micro STAMP Session-Sender MUST set the Sender Micro-session ID field with the member link identifier
associated with the micro STAMP session. If the Session-Sender knows
the Reflector member link identifier, the Reflector Micro-session ID
field MUST be set. Otherwise, the Reflector Micro-session ID field
MUST be zero. The Reflector member link identifier can be obtained
from pre-configuration or learned from data plane (e.g., the
reflected test packet). How to obtain/learn the Reflector member
link identifier is outside of this document's scope.</t>

        <t>When the micro STAMP Session-Reflector receives a test packet, if the Reflector Micro-session ID is not zero, the micro STAMP Session-Reflector MUST use the Reflector member link identifier to check
whether it is associated with the micro STAMP session. If the
validation fails, the test packet MUST be discarded. If the
Reflector Micro-session ID is zero, it will not be verified. If all
validations passed, the Session-Reflector sends a reflected test
packet to the Session-Sender. The micro STAMP Session-Reflector MUST
put the Sender and Reflector member link identifiers that are
associated with the micro STAMP session in the Sender Micro-session
ID and Reflector Micro-session ID fields respectively. The Sender
member link identifier is copied from the received test packet.</t>

        <t>When receiving a reflected test packet, the micro Session-Sender
MUST use the Sender Micro-session ID to validate whether the
reflected test packet is correctly transmitted over the expected
member link. If the validation fails, the test packet MUST be
discarded. The micro Session-Sender MUST use the Reflector Micro-session ID to validate the Reflector's behavior. If the validation
fails, the test packet MUST be discarded.</t>

        <t>Two modes of the STAMP Session-Reflector, stateless and stateful,
        characterize the expected behavior. The micro STAMP-Test supports both
        stateless and stateful modes. However, the micro STAMP-Test does not
        introduce any additional state to STAMP, i.e, any procedure with
        regard to the Micro-session ID is stateless.</t>
      </section>
    </section>

    <section title="Applicability">
      <t>The micro STAMP Session-Sender sends micro Session-Sender packets
with the Micro-session ID TLV. The micro Session-Reflector checks
whether a test packet is received from the member link associated
with the correct micro STAMP session, if the Reflector Micro-session
ID field is set. When reflecting, the micro STAMP Session-Reflector
copies the Sender Micro-session ID from the received micro Session-Sender packet to the micro Session-Reflector packet, and sets the
Reflector Micro-session ID field with the member link identifier
that is associated with the micro STAMP session. When receiving the
micro Session-Reflector packet, the micro Session-Sender uses the
the Sender Micro-session ID to check whether the packet is received
from the member link associated with the correct micro STAMP
session. The micro Session-Sender also use the Reflector Micro-session ID to validate the Reflector's behavior.</t>
    </section>

    <section anchor="IANA" title="IANA Considerations">
      <t>In the "STAMP TLV Types" registry created for [RFC8972], a new STAMP
      TLV Type for Micro-session ID TLV is requested from IANA as
      follows:<figure align="center" title="New STAMP TLV Type">
          <artwork><![CDATA[+----------------+-------------------+-----------------+------------+
| STAMP TLV Type | Description       | Semantics       | Reference  |
| Value          |                   | Definition      |            |
+----------------+-------------------+-----------------+------------+
| TBA1           | Micro-session     | Section 3       | This       |
|                | ID TLV            |                 | Document   |
+----------------+-------------------+-----------------+------------+]]></artwork>
        </figure></t>
    </section>

    <section anchor="Security" title="Security Considerations">
      <t>The STAMP extension defined in this document is intended for
      deployment in LAG scenario where Session-Sender and Session-Reflector
      are directly connnected. As such, it's assumed that a node involved in
      STAMP protocol operation has previously verified the integrity of the
      LAG connection and the identity of its one-hop-away peer node.</t>

      <t>This document does not introduce any additional security issues and
      the security mechanisms defined in <xref target="RFC8762"/> and <xref
      target="RFC8972"/> apply in this document.</t>
    </section>

    <section anchor="Acknowledgements" title="Acknowledgements">
      <t>The authors would like to thank Mach Chen, Min Xiao, Fang Xin, Marcus
      Ihlar, Richard Foote for the valuable comments to this work.</t>
    </section>
  </middle>

  <back>
    <references title="Normative References">
      <?rfc include="reference.RFC.2119"?>

      <?rfc include='reference.RFC.8174'?>

      <?rfc include='reference.RFC.8762'?>

      <?rfc include='reference.RFC.8972'?>
    </references>

    <references title="Informative References">
      <reference anchor="IEEE802.1AX">
        <front>
          <title>IEEE Standard for Local and metropolitan area networks - Link
          Aggregation</title>

          <author>
            <organization>IEEE Std. 802.1AX</organization>
          </author>

          <date month="November" year="2008"/>
        </front>
      </reference>

      <?rfc include='reference.RFC.7799'?>

      <?rfc include='reference.RFC.8668'?>

      <?rfc include='reference.RFC.9256'?>
    </references>
  </back>
</rfc>
