RFC 6673

Round-Trip Packet Loss Metrics

๐Ÿ“… published August 2012, from ietf

Round-Trip Packet Loss Metrics โœจ

Okay bestie, this is RFC 6673 ๐Ÿฆ‹, written by A. Morton from AT&T Labs and published by the IETF. It's a Standards Track doc, dated August 2012, with ISSN 2070-1721. The title block doesn't list anything it obsoletes or updates, so no drama there ๐Ÿ’….

Abstract

Okay so a lot of user apps (and the transport protocols that make them work) need two-way communication ๐Ÿ’ฌ. To check that, and keep test setups simple, people run round-trip loss tests all the time ๐Ÿงช. The Two-Way Active Measurement Protocol in RFC 5357 gives the Internet a round-trip loss measurement capability โœจ. But plot twist: there's no round-trip packet loss metric defined under the RFC 2330 framework yet ๐Ÿ˜ญ. This memo fixes that by adding round-trip loss to the IP Performance Metrics (IPPM) set ๐Ÿ”ฅ.

Status of This Memo

This is an Internet Standards Track document ๐ŸŽ€.

It's a product of the Internet Engineering Task Force (IETF), so it represents the consensus of the IETF community ๐Ÿซถ. It got public review and was approved for publication by the Internet Engineering Steering Group (IESG). You can find more about Internet Standards in Section 2 of RFC 5741 ๐Ÿ“š.

For the current status, any errata, and how to send feedback, check http://www.rfc-editor.org/info/rfc6673 ๐Ÿ”—.

Copyright (c) 2012 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) in effect on the date of publication. Please read these carefully, because they spell out your rights and restrictions for this document ๐Ÿ“œ. Code Components pulled out of this document must include Simplified BSD License text as 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 ....................................................3
   1.1. Motivation .................................................4
   1.2. Requirements Language ......................................5
2. Scope ...........................................................5
3. Common Specifications for Round-Trip Metrics ....................5
   3.1. Name: Type-P-* .............................................5
   3.2. Metric Parameters ..........................................5
   3.3. Metric Definition ..........................................6
   3.4. Metric Units ...............................................6
4. A Singleton Round-Trip Loss Metric ..............................7
   4.1. Name: Type-P-Round-trip-Loss ...............................7
   4.2. Metric Parameters ..........................................7
   4.3. Definition and Metric Units ................................7
   4.4. Discussion and Other Details ...............................8
5. A Sample Round-Trip Loss Metric .................................9
   5.1. Name: Type-P-Round-trip-Loss-<Sample>-Stream ...............9
   5.2. Metric Parameters ..........................................9
   5.3. Definition and Metric Units ................................9
   5.4. Discussion and Other Details ..............................10
6. Round-Trip Loss Statistic ......................................10
   6.1. Type-P-Round-trip-Loss-<Sample>-Ratio .....................10
7. Round-Trip Testing and One-Way Reporting .......................11
8. Measurement Considerations and Calibration .....................11
9. Security Considerations ........................................12
   9.1. Denial-of-Service Attacks .................................12
   9.2. User Data Confidentiality .................................12
   9.3. Interference with the Metrics .............................12
10. IANA Considerations ...........................................13
11. Acknowledgements ..............................................13
12. References ....................................................13
   12.1. Normative References .....................................13
   12.2. Informative References ...................................14

1. Introduction ๐ŸŒ

This memo defines a metric for how well an IP network can move packets in both directions between one host and another. Two-way communication is almost always needed, so if a packet fails to make it in either direction, that counts as a round-trip packet loss ๐Ÿ’€.

This memo defines a metric for round-trip packet loss on Internet paths. It builds on the notions and conventions from the IP Performance Metrics (IPPM) framework [RFC2330]. The one-way packet loss metric for IPPM [RFC2680] and the round-trip delay metric for IPPM [RFC2681] get referenced a lot, and they're tweaked here to fit round-trip situations ๐Ÿ”„. This memo assumes you already know those references, though, so it doesn't repeat the material the way [RFC2681] did ๐Ÿ“–.

This memo uses "two-way" and "round-trip" to mean the same thing ๐Ÿ’œ.

1.1. Motivation ๐ŸŽ€

Lots of user apps, and the transport protocols behind them, need two-way communications. The TCP three-way handshake is a great example: SYN->, <-SYN-ACK, ACK->. It happens billions of times every day, and it can't finish without two-way connectivity in a near-simultaneous time interval ๐Ÿค. So measuring round-trip packet loss on the Internet gives us a solid basis for inferring application performance, and it's way easier to do that way ๐Ÿง .

Measurement system designers also noticed that system simplicity is a big perk when one host just echoes or reflects test packets back to the sender ๐Ÿชž. Round-trip packet loss measurements show up all the time in practice. The ubiquitous "ping" tools can measure round-trip packet loss and delay, but they usually need ICMP Echo-Request/Reply support, and ICMP packets may get exceptional treatment on the measurement path (see Section 2.6 of [RFC2681]) ๐Ÿ™ˆ. The Two-Way Active Measurement Protocol (TWAMP) specified in [RFC5357] sets up a round-trip packet loss measurement capability for the Internet. Still, there's currently no round-trip packet loss metric specified according to the [RFC2330] framework ๐Ÿ˜ญ.

[RFC2681] says round-trip measurements may sometimes run into "asymmetric" paths ๐Ÿ”€. When you see loss with a round-trip measurement, you often really want to figure out which of the two directional paths "lost" the packet ๐Ÿ•ต๏ธ. Sometimes you can make that inference, but interpreting the embedded one-way results with a round-trip measurement brings a few complications, so users should be aware of them ๐Ÿ‘€.

[RFC2681] also points out that loss measurements taken sequentially in both directions of a path and reported as a round-trip result may be exactly the metric you want โœ…. On the flip side, it may be hard to work out the state of round-trip packet loss from one-way measurements taken in each direction, unless there's a pre-arranged method to match the right one-way measurements together ๐Ÿงฉ.

Finally, lots of measurement systems report statistics on a conditional delay distribution, where the condition is packet arrival at the destination ๐Ÿ“Š. This condition gets encouraged in [RFC3393], [RFC5481], and [RFC6703]. As a result, lost packets need to be reported separately, according to a standardized metric, and this memo defines exactly that ๐Ÿ†.

See Section 1.1 of [RFC2680] for more motivation behind the packet loss metric ๐Ÿ“š.

1.2. Requirements Language ๐Ÿ“œ

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 [RFC2119] ๐Ÿ’–.

2. Scope ๐Ÿ”

This memo defines a round-trip packet loss metric using the conventions of the IPPM framework [RFC2330] ๐Ÿง.

The memo defines a singleton metric, a sample metric, and a statistic, as per [RFC2330]. The [RFC2330] framework is for active measurement methods. Although this metric MAY be applicable in passive measurement as well, discussing extra considerations for the passive scenario is beyond the normative scope of this memo ๐Ÿ™ƒ.

The memo also looks into one-way loss inference from a two-way measurement, and it lists some key considerations ๐Ÿ•ฐ๏ธ.

3. Common Specifications for Round-Trip Metrics ๐Ÿงฉ

To cut down on repeated info in the detailed metrics sections that follow, this section lays out the specifications that two or more metrics have in common ๐Ÿซง. It's organized with the same subsections as the individual metrics, so comparing them is easy ๐Ÿ‘ฏ.

3.1. Name: Type-P-* ๐Ÿท๏ธ

All metrics use the Type-P convention described in [RFC2330]. The rest of the name is unique to each metric ๐Ÿ’….

3.2. Metric Parameters ๐ŸŽ›๏ธ

  • Src, the IP address of a host
  • Dst, the IP address of a host
  • T, a time (start of test interval)
  • Tf, a time (end of test interval)
  • lambda, a rate in reciprocal seconds (for Poisson Streams)
  • incT, the nominal duration of inter-packet interval, first bit to first bit (for Periodic Streams)
  • T0, a time that MUST be selected at random from the interval [T, T+dT] to start generating packets and taking measurements (for Periodic Streams)
  • TstampSrc, the wire time of the packet as measured at MP(Src) as it leaves for Dst.
  • TstampDst, the wire time of the packet as measured at MP(Dst), assigned to packets that arrive within a "reasonable" time (less than Tmax).
  • Tmax, a maximum waiting time for packets to arrive at Src, set sufficiently long to disambiguate packets with long delays from packets that are discarded (lost).
  • M, the total number of packets sent between T0 and Tf
  • N, the total number of packets received at Dst (sent between T0 and Tf)
  • Type-P, as defined in [RFC2330], which includes any field that may affect a packet's treatment as it traverses the network

3.3. Metric Definition ๐Ÿ“

This section is specific to each metric ๐ŸŽฏ.

3.4. Metric Units ๐Ÿ“

The metric units are logical (1 or 0) when describing a single packet's loss performance. A 0 means successful packet transmission and a 1 means packet loss โœ…โŒ.

Units of time are as specified in [RFC2330] โฑ๏ธ.

Other units get defined in the associated section where needed, for example Section 6.1 in the case of Type-P-Round-trip-Loss-<Sample>-Ratio ๐Ÿงฎ.

4. A Singleton Round-Trip Loss Metric ๐ŸŽฏ

4.1. Name: Type-P-Round-trip-Loss ๐ŸŒธ

4.2. Metric Parameters ๐ŸŽ€

See Section 3.2.

4.3. Definition and Metric Units

okay bestie, this is the part where we decide what a "lost" packet actually means ๐Ÿ’… Type-P-Round-trip-Loss SHALL be represented by the binary logical values (or their equivalents) when the following conditions are met:

Type-P-Round-trip-Loss = 0 means it all went right ๐ŸŒˆ

  • Src sent the first bit of a Type-P packet to Dst at wire-time TstampSrc,
  • Dst received that packet,
  • Dst sent a Type-P packet back to Src as fast as it possibly could (definitely under Tmax, and fast enough for whatever the test is for) โšก, and
  • Src received the last bit of that reflected packet before wire-time TstampSrc + Tmax ๐ŸŽ€.

Type-P-Round-trip-Loss = 1 means the packet ghosted us ๐Ÿ’€

  • Src sent the first bit of a Type-P packet to Dst at wire-time TstampSrc,
  • and Src did NOT receive the last bit of the reflected packet before the waiting time ran out at TstampSrc + Tmax.

Possible reasons for the Loss = 1 outcome:

  • Dst never received that packet,
  • Dst never sent a Type-P packet back to Src, or
  • Src never got a reflected Type-P packet from Dst.

Following the precedent of Section 2.4 of [RFC2681], we make a simplifying assumption: round-trip loss measured between two hosts is the same no matter which host starts the test ๐Ÿซถ

Type-P-Round-trip-Loss(Src->Dst->Src) =
Type-P-Round-trip-Loss(Dst->Src->Dst)

(and we agree with the reasoning over there, that the ambiguity is a small price to pay for measurement efficiency ๐Ÿฆ‹).

So each singleton can be represented by a pair of elements:

  • TstampSrc, the wire time of the packet at Src (where the round-trip journey begins).
  • L, either zero or one (or some logical equivalent), where L=1 means loss and L=0 means successful round-trip arrival before TstampSrc + Tmax ๐ŸŒธ

4.4. Discussion and Other Details

For the full tea on methods of measurement, errors, uncertainties, and all the other foundational stuff, go read [RFC2680] and [RFC2681] โœจ We don't need to repeat it all here.

We're adding some guidance on the responder side of "send a Type-P packet back to the Src as quickly as possible" ๐Ÿƒโ€โ™€๏ธ

A response that wasn't generated within Tmax is useless for any realistic test, and Src will toss it out ๐Ÿ—‘๏ธ A responder that handles typical round-trip packet loss testing (which matters for higher-layer application performance) SHOULD produce a response in 1 second or less ๐Ÿ’– If a responder can't hit that, it SHOULD log the fact so an operator can adjust load and priorities as needed ๐Ÿงš And if analysis of responder timestamps [RFC5357] shows responses aren't coming back in a timely way, that SHOULD result in operator notification, and the operator SHOULD suspend tests to that responder, since it may be overloaded ๐Ÿ˜ญ More measurement considerations are in Section 8 below ๐Ÿ“

5. A Sample Round-Trip Loss Metric

Now that we have a singleton metric, we can define one particular sample of them ๐ŸŽ€ The idea is to pick a specific binding of the parameters Src, Dst, and Type-P, then define a sample of values for the parameter TstampSrc. There are a few ways to do this, including:

  1. Poisson: a pseudo-random Poisson process of rate lambda, with values falling between T and Tf. The time between successive values of TstampSrc will then average 1/lambda, as per Section 11.1.1 of [RFC2330] ๐Ÿฆ‹
  2. Periodic: a periodic stream process with a pseudo-random start time T0 between T and dT, and a nominal inter-packet interval incT, as per [RFC3432] ๐Ÿ’œ

In the metric name, the variable <Sample> SHALL be replaced with the name of the process used to define the sample. Use one of the processes above, or another sample process that meets the criteria in Section 11.1 of [RFC2330]. If you go with another process, its details MUST be reported along with the results ๐Ÿ“‹

5.1. Name: Type-P-Round-trip-Loss-<Sample>-Stream

5.2. Metric Parameters

See Section 3.2.

5.3. Definition and Metric Units

Given one of the methods for defining the test interval (the sample of times, TstampSrc, plus the other metric parameters), we get a sequence of Type-P-Round-trip-Loss singletons as defined in Section 4.3 โœจ

Type-P-Round-trip-Loss-<Sample>-Stream SHALL be a sequence of pairs with these elements:

  • TstampSrc, as above
  • L, either zero or one (or some logical equivalent), where L=1 means loss and L=0 means successful round-trip arrival before TstampSrc + Tmax

And <Sample> SHALL be replaced with "Poisson", "Periodic", or an appropriate term for another sample method, as described in Section 5 above ๐ŸŒˆ

5.4. Discussion and Other Details

Again, [RFC2680] and [RFC2681] have all the deep stuff on methods, errors, and uncertainties, so we won't repeat it here ๐Ÿ“š BUT, when those references were approved, the packet reordering metrics in [RFC4737] didn't exist yet, and reordering wasn't covered in IPPM methodologies. So we need to address it here ๐Ÿ‘€

[RFC4737] defines packets that arrive "late" relative to their sending order as reordered. For example, if packets arrive with sequence numbers 4, 7, 5, 6, then packets 5 and 6 are reordered, and they are NOT lost, because they showed up within some reasonable waiting time threshold ๐Ÿซ  Reordering on a round-trip path has a few likely effects on the measurement:

  1. Measurement methods should keep waiting the specified time for packets, and avoid prematurely declaring round-trip packet loss whenever a sequence gap or error shows up ๐Ÿ•ฐ๏ธ
  2. The time distribution of the singletons in the sample has changed a lot ๐Ÿ“‰
  3. Either the original packet stream or the reflected stream went through path instability, so the original conditions might not be there anymore ๐ŸŒช๏ธ

Measurement implementations MUST address the possibility of packet reordering and avoid related errors in their processes โš ๏ธ

6. Round-Trip Loss Statistic

This section gives the primary and overall statistic for loss performance ๐Ÿ‘‘ Additional statistics and metrics that were originally made for one-way loss MAY also be applicable.

6.1. Type-P-Round-trip-Loss-<Sample>-Ratio

Given a Type-P-Round-trip-Loss-<Sample>-Stream, the average of all the logical values, L, in the stream is the Type-P-Round-trip-Loss-<Sample>-Ratio ๐Ÿงฎ This ratio is in units of lost packets per round-trip transmissions actually attempted.

The Type-P-Round-trip-Loss-<Sample>-Ratio is undefined if the sample is empty ๐Ÿ™ˆ

7. Round-Trip Testing and One-Way Reporting

This section covers things to think about when you collect results with a round-trip measurement setup, like TWAMP [RFC5357] ๐Ÿฆ‹

The sampling process for the reverse path (Dst->Src) is conditional. It depends on packets successfully arriving at Dst, and on Dst operating correctly so it can generate the reflected packet ๐Ÿชž So when a lot of loss shows up on the Src->Dst path, the sampling process for the reverse path gets seriously affected, and trying to assess the reverse path performance becomes invalid (for loss, or possibly for any metric) ๐Ÿ’”

The sampling times for the reverse path (Dst->Src) are also a random process. They depend on the original sample times (TstampSrc), the one-way delay for packets arriving at Dst, and the time Dst takes to generate the reflected packet โณ So when there's a lot of delay variation on the Src->Dst path, the reverse path sampling gets seriously affected too, and again, assessing reverse path performance becomes invalid (for loss, or possibly any metric) ๐Ÿ˜ฉ

As we said in Section 5.4, packet reordering is always a possibility ๐Ÿ”€ On top of the big delay variation that usually comes with it, reordering on the Src->Dst path will mess up the sequence numbers applied at Dst compared to the sender's numbers. Measurement implementations MUST address this possible outcome ๐Ÿซถ

8. Measurement Considerations and Calibration

Before running this measurement, the participating hosts MUST be configured to send and receive test packets of the chosen Type-P ๐Ÿ› ๏ธ Standard measurement protocols can handle this job [RFC5357], but any reliable method is good enough. For example, if the ICMP issues discussed in Section 2.6 of [RFC2681] can be fixed, and the requirements of Sections 4.3 and 4.4 above are met, then ICMP could be used ๐ŸงŠ

Two key features of the host that receives test packets and sends them back to the originating host are described in Section 4.2 of [RFC5357] ๐Ÿ’… Every received test packet MUST result in a responding packet, and the response MUST be generated as quickly as possible โšก That implies interface buffers get serviced promptly, and buffer discards are extremely rare ๐ŸŒŸ These features of the measurement equipment MUST be calibrated according to Section 3.7.3 of [RFC2679] when running under a representative measurement load (as defined by the user). Both unexpected test packet discards and the systematic and random errors and uncertainties MUST be recorded ๐Ÿ“

We also want to flag that Section 4.2.1 of [RFC5357] describes a method to collect all four significant timestamps needed to describe a packet's round-trip delay [RFC2681], and to remove the processing time spent at the responding host ๐Ÿง  That info supports measuring the corresponding one-way delays on the round-trip path, which can reveal path asymmetry or unexpected processing time at the responding host ๐Ÿ”

9. Security Considerations

9.1. Denial-of-Service Attacks

This metric needs a stream of packets sent from one host (source) to another host (destination) through intervening networks, and back again ๐ŸŒ€ This method could be abused for denial-of-service attacks aimed at the destination, the intervening network(s), or both ๐Ÿšจ

Seriously, this is a big deal. Administrators of the source, destination, and intervening network(s) should set up bilateral or multilateral agreements about the timing, size, and frequency of collecting sample metrics ๐Ÿ›‘ Using this method beyond what the participants agreed to may get you immediate rejection or discard of packets, or other escalation procedures set between the affected parties ๐Ÿ’€

9.2. User Data Confidentiality

Active use of this method generates packets for a sample, instead of taking samples from user data, so it doesn't threaten user data confidentiality ๐Ÿ”’ Passive measurement, though, has to restrict attention to the headers of interest ๐Ÿ‘€ Since user payloads may be stored temporarily for length analysis, suitable precautions MUST be taken to keep that information safe and confidential ๐Ÿ” In most cases, a hashing function will produce a value good enough for payload comparisons ๐Ÿ’œ


9.3. Interference with the Metrics ๐Ÿ‘€

okay so this one is lowkey scary ๐Ÿ˜ญ If someone can tell that a certain packet or stream is part of a sample, then whoever is at the destination or on the networks in between can change how those packets get processed (like adding or cutting delay), and that can distort the measured performance. They could also make extra packets that look like they belong to the sample metric. Those sneaky packets are likely to mess up the results ๐Ÿ’€

Here's the fix the spec gives us: authentication or encryption techniques, such as digital signatures, MAY be used where appropriate to guard against injected traffic attacks ๐Ÿ›ก๏ธ [RFC5357] includes both authentication and encryption features โœจ


10. IANA Considerations ๐Ÿ“‹

Metrics that were defined in the IETF used to get registered in the IANA IPPM Metrics Registry, but that process was discontinued once the registry structure was found to be inadequate, and the registry was declared obsolete [RFC6248] ๐Ÿฅ€

Although the metrics in this document may be considered for some form of registration in the future, no IANA action is requested at this time ๐Ÿ’…


11. Acknowledgements ๐Ÿซถ

The author gives a big thank-you to Tiziano Ionta for his careful review of this memo, which mainly led to the development of measurement considerations using TWAMP [RFC5357] as an example method ๐Ÿ’– The reviews of Adrian Farrel and Benoit Claise also made the memo way clearer ๐ŸŒธ


12. References ๐Ÿ“š

12.1. Normative References

[RFC2119]  Bradner, S., "Key words for use in RFCs to Indicate
           Requirement Levels", BCP 14, RFC 2119, March 1997.

[RFC2330]  Paxson, V., Almes, G., Mahdavi, J., and M. Mathis,
           "Framework for IP Performance Metrics", RFC 2330,
           May 1998.

[RFC2679]  Almes, G., Kalidindi, S., and M. Zekauskas, "A One-way
           Delay Metric for IPPM", RFC 2679, September 1999.

[RFC2680]  Almes, G., Kalidindi, S., and M. Zekauskas, "A One-way
           Packet Loss Metric for IPPM", RFC 2680, September 1999.

[RFC2681]  Almes, G., Kalidindi, S., and M. Zekauskas, "A Round-trip
           Delay Metric for IPPM", RFC 2681, September 1999.

[RFC3393]  Demichelis, C. and P. Chimento, "IP Packet Delay Variation
           Metric for IP Performance Metrics (IPPM)", RFC 3393,
           November 2002.

[RFC3432]  Raisanen, V., Grotefeld, G., and A. Morton, "Network
           performance measurement with periodic streams", RFC 3432,
           November 2002.

[RFC4737]  Morton, A., Ciavattone, L., Ramachandran, G., Shalunov,
           S., and J. Perser, "Packet Reordering Metrics", RFC 4737,
           November 2006.

[RFC5357]  Hedayat, K., Krzanowski, R., Morton, A., Yum, K., and J.
           Babiarz, "A Two-Way Active Measurement Protocol (TWAMP)",
           RFC 5357, October 2008.

12.2. Informative References

[RFC5481]  Morton, A. and B. Claise, "Packet Delay Variation
           Applicability Statement", RFC 5481, March 2009.

[RFC6248]  Morton, A., "RFC 4148 and the IP Performance Metrics
           (IPPM) Registry of Metrics Are Obsolete", RFC 6248,
           April 2011.

[RFC6703]  Morton, A., Ramachandran, G., and G. Maguluri, "Reporting
           IP Network Performance Metrics: Different Points of View",
           RFC 6703, August 2012.

Author's Address ๐ŸŽ€

Al Morton
AT&T Labs
200 Laurel Avenue South
Middletown, NJ  07748
USA

Phone: +1 732 420 1571
Fax:   +1 732 368 1192
EMail: acmorton@att.com
URI:   http://home.comcast.net/~acmacm/
๐Ÿ“ฆ where this page comes from