draft-ietf-tcpm-rfc3782-bis-01.txt   draft-ietf-tcpm-rfc3782-bis-02.txt 
Network Working Group T. Henderson Network Working Group T. Henderson
Internet-Draft Boeing Internet-Draft Boeing
Obsoletes: 3782 (if approved) S. Floyd Obsoletes: 3782 (if approved) S. Floyd
Intended status: Standards Track ICSI Intended status: Standards Track ICSI
Expires: September 15, 2011 A. Gurtov Expires: October 20, 2011 A. Gurtov
HIIT HIIT
Y. Nishida Y. Nishida
WIDE Project WIDE Project
March 14, 2011 April 20, 2011
The NewReno Modification to TCP's Fast Recovery Algorithm The NewReno Modification to TCP's Fast Recovery Algorithm
draft-ietf-tcpm-rfc3782-bis-01.txt draft-ietf-tcpm-rfc3782-bis-02.txt
Abstract Abstract
RFC 5681 [RFC5681] documents the following four intertwined TCP RFC 5681 documents the following four intertwined TCP
congestion control algorithms: Slow Start, Congestion Avoidance, Fast congestion control algorithms: slow start, congestion avoidance, fast
Retransmit, and Fast Recovery. RFC 5681 explicitly allows retransmit, and fast recovery. RFC 5681 explicitly allows
certain modifications of these algorithms, including modifications certain modifications of these algorithms, including modifications
that use the TCP Selective Acknowledgement (SACK) option [RFC2883], that use the TCP Selective Acknowledgement (SACK) option (RFC 2883),
and modifications that respond to "partial acknowledgments" (ACKs and modifications that respond to "partial acknowledgments" (ACKs
which cover new data, but not all the data outstanding when loss was which cover new data, but not all the data outstanding when loss was
detected) in the absence of SACK. This document describes a specific detected) in the absence of SACK. This document describes a specific
algorithm for responding to partial acknowledgments, referred to as algorithm for responding to partial acknowledgments, referred to as
NewReno. This response to partial acknowledgments was first proposed NewReno. This response to partial acknowledgments was first proposed
by Janey Hoe in [Hoe95]. by Janey Hoe. This document obsoletes RFC 3782.
The purpose of this revision from [RFC3782] is to make errata changes
and to adopt a proposal from Yoshifumi Nishida to slightly increase
the minimum window size after Fast Recovery from one to two segments,
to improve performance when the receiver uses delayed acknowledgments.
Status of this Memo Status of this Memo
This Internet-Draft is submitted to IETF in full conformance with the This Internet-Draft is submitted to IETF in full conformance with the
provisions of BCP 78 and BCP 79. provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering Internet-Drafts are working documents of the Internet Engineering
Task Force (IETF). Note that other groups may also distribute Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet- working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/. Drafts is at http://datatracker.ietf.org/drafts/current/.
skipping to change at page 4, line 24 skipping to change at page 4, line 24
Recovery. The version of NewReno in this document also draws on other Recovery. The version of NewReno in this document also draws on other
discussions of NewReno in the literature [LM97, Hen98]. discussions of NewReno in the literature [LM97, Hen98].
We do not claim that the NewReno version of Fast Recovery described We do not claim that the NewReno version of Fast Recovery described
here is an optimal modification of Fast Recovery for responding to here is an optimal modification of Fast Recovery for responding to
partial acknowledgments, for TCP connections that are unable to use partial acknowledgments, for TCP connections that are unable to use
SACK. Based on our experiences with the NewReno modification in the SACK. Based on our experiences with the NewReno modification in the
NS simulator [NS] and with numerous implementations of NewReno, we NS simulator [NS] and with numerous implementations of NewReno, we
believe that this modification improves the performance of the Fast believe that this modification improves the performance of the Fast
Retransmit and Fast Recovery algorithms in a wide variety of Retransmit and Fast Recovery algorithms in a wide variety of
scenarios. scenarios. Previous versions of this RFC [RFC2582, RFC3782] provide
simulation-based evidence of the possible performance gains.
2. Terminology and Definitions 2. Terminology and Definitions
In this document, the key words "MUST", "MUST NOT", "REQUIRED", In this document, the key words "MUST", "MUST NOT", "REQUIRED",
"SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY",
and "OPTIONAL" are to be interpreted as described in BCP 14, RFC 2119 and "OPTIONAL" are to be interpreted as described in BCP 14, RFC 2119
[RFC2119]. This RFC indicates requirement levels for compliant TCP [RFC2119]. This RFC indicates requirement levels for compliant TCP
implementations implementing the NewReno Fast Retransmit and Fast implementations implementing the NewReno Fast Retransmit and Fast
Recovery algorithms described in this document. Recovery algorithms described in this document.
This document assumes that the reader is familiar with the terms This document assumes that the reader is familiar with the terms
SENDER MAXIMUM SEGMENT SIZE (SMSS), CONGESTION WINDOW (cwnd), and SENDER MAXIMUM SEGMENT SIZE (SMSS), CONGESTION WINDOW (cwnd), and
FLIGHT SIZE (FlightSize) defined in [RFC5681]. FLIGHT SIZE is FLIGHT SIZE (FlightSize) defined in [RFC5681]. FLIGHT SIZE is
defined as in [RFC5681] as follows: defined as in [RFC5681] as follows:
FLIGHT SIZE: FLIGHT SIZE:
The amount of data that has been sent but not yet cumulatively The amount of data that has been sent but not yet cumulatively
acknowledged. acknowledged.
This document defines an additional sender-side state variable
called RECOVER:
RECOVER:
When in Fast Recovery, this variable records the send sequence
number that must be acknowledged before the Fast Recovery
procedure is declared to be over.
3. The Fast Retransmit and Fast Recovery Algorithms in NewReno 3. The Fast Retransmit and Fast Recovery Algorithms in NewReno
The basic idea of these extensions to the Fast Retransmit and 3.1. Protocol Overview
Fast Recovery algorithms described in [RFC5681] is as follows.
The TCP sender can infer, from the arrival of duplicate
acknowledgments, whether multiple losses in the same window of
data have most likely occurred, and avoid taking a retransmit
timeout or making multiple congestion window reductions due to
such an event.
The standard implementation of the Fast Retransmit and Fast Recovery The basic idea of these extensions to the Fast Retransmit and
algorithms is given in [RFC5681]. This section specifies the basic Fast Recovery algorithms described in Section 3.2 of [RFC5681]
NewReno algorithm. Section 4 describes heuristics for processing is as follows. The TCP sender can infer, from the arrival of
duplicate acknowledgments after a retransmission timeout. Sections duplicate acknowledgments, whether multiple losses in the same
5 and 6 provide some guidance to implementors based on experience window of data have most likely occurred, and avoid taking a
with NewReno implementations. Several appendices provide more retransmit timeout or making multiple congestion window reductions
background information and describe variations that an implementor due to such an event.
may want to consider when tuning performance for certain network
scenarios.
The NewReno modification applies to the Fast Recovery procedure that The NewReno modification applies to the Fast Recovery procedure that
begins when three duplicate ACKs are received and ends when either a begins when three duplicate ACKs are received and ends when either a
retransmission timeout occurs or an ACK arrives that acknowledges all retransmission timeout occurs or an ACK arrives that acknowledges all
of the data up to and including the data that was outstanding when of the data up to and including the data that was outstanding when
the Fast Recovery procedure began. the Fast Recovery procedure began.
The NewReno algorithm specified in this document extends the 3.2. Specification
implementation in [RFC5681] by introducing a variable specified as
"recover" whose initial value is the initial send sequence number.
This new variable is used by the sender to record the send sequence
number that must be acknowledged before the Fast Recovery
procedure is declared to be over. This variable is used below
in step 1, in the response to a partial or new
acknowledgment in step 5, and in modifications to step 1 and the
addition of step 6 for avoiding multiple Fast Retransmits caused by
the retransmission of packets already received by the receiver.
1) Three duplicate ACKs:
When the third duplicate ACK is received and the sender is not
already in the Fast Recovery procedure, check to see if the
Cumulative Acknowledgment field covers more than
"recover". If so, go to Step 1A. Otherwise, go to Step 1B.
1A) Invoking Fast Retransmit:
If so, then set ssthresh to no more than the value given in
equation 1 below. (This is equation 4 from [RFC5681]).
ssthresh = max (FlightSize / 2, 2*SMSS) (1)
In addition, record the highest sequence number transmitted in
the variable "recover", and go to Step 2.
1B) Not invoking Fast Retransmit:
Do not enter the Fast Retransmit and Fast Recovery procedure. In
particular, do not change ssthresh, do not go to Step 2 to
retransmit the "lost" segment, and do not execute Step 3 upon
subsequent duplicate ACKs.
2) Entering Fast Retransmit: The procedures specified in Section 3.2 of [RFC5681] are followed
Retransmit the lost segment and set cwnd to ssthresh plus with the following modifications.
3*SMSS. This artificially "inflates" the congestion window by the
number of segments (three) that have left the network and the
receiver has buffered.
3) Fast Recovery: 1) Initialization of TCP protocol control block:
For each additional duplicate ACK received while in Fast When the TCP protocol control block is initialized, Recover is
Recovery, increment cwnd by SMSS. This artificially inflates set to the initial send sequence number.
the congestion window in order to reflect the additional segment
that has left the network.
4) Fast Recovery, continued: 2) Three duplicate ACKs:
Transmit a segment, if allowed by the new value of cwnd and the When the third duplicate ACK is received, the TCP sender first
receiver's advertised window. checks the value of Recover to see if the Cumulative Acknowledgment
field covers more than Recover. If so, the value of Recover is
incremented to the value of the highest sequence number
transmitted by the TCP so far. The TCP then enters Fast Retransmit
(step 2 of Section 3.2 of [RFC5681]). If not, the TCP does not
enter fast retransmit and does not reset ssthresh.
5) When an ACK arrives that acknowledges new data, this ACK could be 3) Response to newly acknowledged data:
the acknowledgment elicited by the retransmission from step 2, or Step 6 of [RFC5681] specifies the response to the next ACK that
elicited by a later retransmission. acknowledges previously unacknowledged data. When an ACK
arrives that acknowledges new data, this ACK could be the
acknowledgment elicited by the retransmission from step 2, or
elicited by a later retransmission. There are two cases.
Full acknowledgments: Full acknowledgments:
If this ACK acknowledges all of the data up to and including If this ACK acknowledges all of the data up to and including
"recover", then the ACK acknowledges all the intermediate Recover, then the ACK acknowledges all the intermediate
segments sent between the original transmission of the lost segments sent between the original transmission of the lost
segment and the receipt of the third duplicate ACK. Set cwnd to segment and the receipt of the third duplicate ACK. Set cwnd to
either (1) min (ssthresh, max(FlightSize, SMSS) + SMSS) or either (1) min (ssthresh, max(FlightSize, SMSS) + SMSS) or
(2) ssthresh, where ssthresh is the value set in step 1; this is (2) ssthresh, where ssthresh is the value set when Fast Retransmit
termed "deflating" the window. (We note that "FlightSize" in step 1 was entered, and where FlightSize in (1) is the amount of data
referred to the amount of data outstanding in step 1, when Fast presently outstanding. This is termed "deflating" the window.
Recovery was entered, while "FlightSize" in step 5 refers to the If the second option is selected, the implementation
amount of data outstanding in step 5, when Fast Recovery is
exited.) If the second option is selected, the implementation
is encouraged to take measures to avoid a possible burst of is encouraged to take measures to avoid a possible burst of
data, in case the amount of data outstanding in the network is data, in case the amount of data outstanding in the network is
much less than the new congestion window allows. A simple mechanism much less than the new congestion window allows. A simple mechanism
is to limit the number of data packets that can be sent in response is to limit the number of data packets that can be sent in response
to a single acknowledgment. Exit the Fast Recovery procedure. to a single acknowledgment. Exit the Fast Recovery procedure.
Partial acknowledgments: Partial acknowledgments:
If this ACK does *not* acknowledge all of the data up to and If this ACK does *not* acknowledge all of the data up to and
including "recover", then this is a partial ACK. In this case, including Recover, then this is a partial ACK. In this case,
retransmit the first unacknowledged segment. Deflate the retransmit the first unacknowledged segment. Deflate the
congestion window by the amount of new data acknowledged by the congestion window by the amount of new data acknowledged by the
cumulative acknowledgment field. If the partial ACK cumulative acknowledgment field. If the partial ACK
acknowledges at least one SMSS of new data, then add back SMSS acknowledges at least one SMSS of new data, then add back SMSS
bytes to the congestion window. As in Step 3, this artificially bytes to the congestion window. This artificially
inflates the congestion window in order to reflect the additional inflates the congestion window in order to reflect the additional
segment that has left the network. Send a new segment if segment that has left the network. Send a new segment if
permitted by the new value of cwnd. This "partial window permitted by the new value of cwnd. This "partial window
deflation" attempts to ensure that, when Fast Recovery eventually deflation" attempts to ensure that, when Fast Recovery eventually
ends, approximately ssthresh amount of data will be outstanding ends, approximately ssthresh amount of data will be outstanding
in the network. Do not exit the Fast Recovery procedure (i.e., in the network. Do not exit the Fast Recovery procedure (i.e.,
if any duplicate ACKs subsequently arrive, execute Steps 3 and if any duplicate ACKs subsequently arrive, execute Step 4 of
4 above). Section 3.2 of [RFC5681].
For the first partial ACK that arrives during Fast Recovery, also For the first partial ACK that arrives during Fast Recovery, also
reset the retransmit timer. Timer management is discussed in reset the retransmit timer. Timer management is discussed in
more detail in Section 4. more detail in Section 4.
6) Retransmit timeouts: 4) Retransmit timeouts:
After a retransmit timeout, record the highest sequence number After a retransmit timeout, record the highest sequence number
transmitted in the variable "recover" and exit the Fast transmitted in the variable Recover and exit the Fast
Recovery procedure if applicable. Recovery procedure if applicable.
Step 1 specifies a check that the Cumulative Acknowledgment field Step 2 above specifies a check that the Cumulative Acknowledgment
covers more than "recover". Because the acknowledgment field field covers more than Recover. Because the acknowledgment field
contains the sequence number that the sender next expects to receive, contains the sequence number that the sender next expects to receive,
the acknowledgment "ack_number" covers more than "recover" when: the acknowledgment "ack_number" covers more than Recover when:
ack_number - 1 > recover; ack_number - 1 > Recover;
i.e., at least one byte more of data is acknowledged beyond the i.e., at least one byte more of data is acknowledged beyond the
highest byte that was outstanding when Fast Retransmit was last highest byte that was outstanding when Fast Retransmit was last
entered. entered.
Note that in Step 5, the congestion window is deflated after a Note that in Step 3 above, the congestion window is deflated after
partial acknowledgment is received. The congestion window was a partial acknowledgment is received. The congestion window was
likely to have been inflated considerably when the partial likely to have been inflated considerably when the partial
acknowledgment was received. In addition, depending on the original acknowledgment was received. In addition, depending on the original
pattern of packet losses, the partial acknowledgment might pattern of packet losses, the partial acknowledgment might
acknowledge nearly a window of data. In this case, if the congestion acknowledge nearly a window of data. In this case, if the congestion
window was not deflated, the data sender might be able to send nearly window was not deflated, the data sender might be able to send nearly
a window of data back-to-back. a window of data back-to-back.
This document does not specify the sender's response to duplicate This document does not specify the sender's response to duplicate
ACKs when the Fast Retransmit/Fast Recovery algorithm is not ACKs when the Fast Retransmit/Fast Recovery algorithm is not
invoked. This is addressed in other documents, such as those invoked. This is addressed in other documents, such as those
describing the Limited Transmit procedure [RFC3042]. This document describing the Limited Transmit procedure [RFC3042]. This document
also does not address issues of adjusting the duplicate acknowledgment also does not address issues of adjusting the duplicate acknowledgment
threshold, but assumes the threshold specified in the IETF standards; threshold, but assumes the threshold specified in the IETF standards;
the current standard is RFC 5681, which specifies a threshold of three the current standard is [RFC5681], which specifies a threshold of three
duplicate acknowledgments. duplicate acknowledgments.
As a final note, we would observe that in the absence of the SACK As a final note, we would observe that in the absence of the SACK
option, the data sender is working from limited information. When option, the data sender is working from limited information. When
the issue of recovery from multiple dropped packets from a single the issue of recovery from multiple dropped packets from a single
window of data is of particular importance, the best alternative window of data is of particular importance, the best alternative
would be to use the SACK option. would be to use the SACK option.
4. Handling Duplicate Acknowledgments After A Timeout 4. Handling Duplicate Acknowledgments After A Timeout
skipping to change at page 10, line 27 skipping to change at page 8, line 47
prev_highest_ack is at most 4*SMSS bytes. If true, duplicate prev_highest_ack is at most 4*SMSS bytes. If true, duplicate
ACKs indicate a lost segment (proceed to Step 1A in Section ACKs indicate a lost segment (proceed to Step 1A in Section
3). Otherwise, duplicate ACKs likely result from unnecessary 3). Otherwise, duplicate ACKs likely result from unnecessary
retransmissions (proceed to Step 1B in Section 3). retransmissions (proceed to Step 1B in Section 3).
The congestion window check serves to protect against fast retransmit The congestion window check serves to protect against fast retransmit
immediately after a retransmit timeout. immediately after a retransmit timeout.
If several ACKs are lost, the sender can see a jump in the cumulative If several ACKs are lost, the sender can see a jump in the cumulative
ACK of more than three segments, and the heuristic can fail. ACK of more than three segments, and the heuristic can fail.
RFC 5681 recommends that a receiver should [RFC5681] recommends that a receiver should
send duplicate ACKs for every out-of-order data packet, such as a send duplicate ACKs for every out-of-order data packet, such as a
data packet received during Fast Recovery. The ACK heuristic is more data packet received during Fast Recovery. The ACK heuristic is more
likely to fail if the receiver does not follow this advice, because likely to fail if the receiver does not follow this advice, because
then a smaller number of ACK losses are needed to produce a then a smaller number of ACK losses are needed to produce a
sufficient jump in the cumulative ACK. sufficient jump in the cumulative ACK.
4.2. Timestamp Heuristic 4.2. Timestamp Heuristic
If this heuristic is used, the sender stores the timestamp of the If this heuristic is used, the sender stores the timestamp of the
last acknowledged segment. In addition, the second paragraph of step last acknowledged segment. In addition, the second paragraph of step
skipping to change at page 11, line 21 skipping to change at page 9, line 36
5. Implementation Issues for the Data Receiver 5. Implementation Issues for the Data Receiver
[RFC5681] specifies that "Out-of-order data segments SHOULD be [RFC5681] specifies that "Out-of-order data segments SHOULD be
acknowledged immediately, in order to accelerate loss recovery." acknowledged immediately, in order to accelerate loss recovery."
Neal Cardwell has noted that some data receivers do not send an Neal Cardwell has noted that some data receivers do not send an
immediate acknowledgment when they send a partial acknowledgment, immediate acknowledgment when they send a partial acknowledgment,
but instead wait first for their delayed acknowledgment timer to but instead wait first for their delayed acknowledgment timer to
expire [C98]. As [C98] notes, this severely limits the potential expire [C98]. As [C98] notes, this severely limits the potential
benefit of NewReno by delaying the receipt of the partial benefit of NewReno by delaying the receipt of the partial
acknowledgment at the data sender. Echoing RFC 5681, our acknowledgment at the data sender. Echoing [RFC5681], our
recommendation is that the data receiver send an immediate recommendation is that the data receiver send an immediate
acknowledgment for an out-of-order segment, even when that acknowledgment for an out-of-order segment, even when that
out-of-order segment fills a hole in the buffer. out-of-order segment fills a hole in the buffer.
6. Implementation Issues for the Data Sender 6. Implementation Issues for the Data Sender
In Section 3, Step 5 above, it is noted that implementations should In Section 3, Step 5 above, it is noted that implementations should
take measures to avoid a possible burst of data when leaving Fast take measures to avoid a possible burst of data when leaving Fast
Recovery, in case the amount of new data that the sender is eligible Recovery, in case the amount of new data that the sender is eligible
to send due to the new value of the congestion window is large. This to send due to the new value of the congestion window is large. This
skipping to change at page 12, line 39 skipping to change at page 11, line 7
or congestion avoidance window updating algorithm immediately after or congestion avoidance window updating algorithm immediately after
the cwnd is set by the equation found in (Section 3, step 5), even the cwnd is set by the equation found in (Section 3, step 5), even
without a new external event generating the cwnd change. Note that without a new external event generating the cwnd change. Note that
after cwnd is set based on the procedure for exiting Fast Recovery after cwnd is set based on the procedure for exiting Fast Recovery
(Section 3, step 5), cwnd SHOULD NOT be updated until a further (Section 3, step 5), cwnd SHOULD NOT be updated until a further
event occurs (e.g., arrival of an ack, or timeout) after this event occurs (e.g., arrival of an ack, or timeout) after this
adjustment. adjustment.
7. Security Considerations 7. Security Considerations
RFC 5681 discusses general security considerations concerning TCP [RFC5681] discusses general security considerations concerning TCP
congestion control. This document describes a specific algorithm congestion control. This document describes a specific algorithm
that conforms with the congestion control requirements of RFC 5681, that conforms with the congestion control requirements of [RFC5681],
and so those considerations apply to this algorithm, too. There are and so those considerations apply to this algorithm, too. There are
no known additional security concerns for this specific algorithm. no known additional security concerns for this specific algorithm.
8. IANA Considerations 8. IANA Considerations
This document has no actions for IANA. This document has no actions for IANA.
9. Conclusions 9. Conclusions
This document specifies the NewReno Fast Retransmit and Fast Recovery This document specifies the NewReno Fast Retransmit and Fast Recovery
algorithms for TCP. This NewReno modification to TCP can even be algorithms for TCP. This NewReno modification to TCP can even be
important for TCP implementations that support the SACK option, important for TCP implementations that support the SACK option,
because the SACK option can only be used for TCP connections when because the SACK option can only be used for TCP connections when
both TCP end-nodes support the SACK option. NewReno performs better both TCP end-nodes support the SACK option. NewReno performs better
than Reno (RFC 5681) in a number of scenarios discussed herein. than Reno (RFC5681) in a number of scenarios discussed in
previous versions of this RFC ([RFC2582], [RFC3782]).
A number of options to the basic algorithm presented in Section 3 are A number of options to the basic algorithm presented in Section 3 are
also described in appendices to this document. These include the also referenced in Appendix A to this document. These include the
handling of the retransmission timer (Appendix A), the response to handling of the retransmission timer, the response to partial
partial acknowledgments (Appendix B), and whether or not the sender acknowledgments, and whether or not the sender must maintain a state
maintains a state variable called "recover" (Appendix C). variable called Recover. Our belief is that the differences
Our belief is that the differences between these variants of NewReno between these variants of NewReno are small compared to the
are small compared to the differences between Reno and NewReno. differences between Reno and NewReno. That is, the important thing
That is, the important thing is to implement NewReno instead of Reno, is to implement NewReno instead of Reno, for a TCP connection
for a TCP connection without SACK; it is less important exactly without SACK; it is less important exactly which of the variants of
which of the variants of NewReno is implemented. NewReno is implemented.
10. Acknowledgments 10. Acknowledgments
Many thanks to Anil Agarwal, Mark Allman, Armando Caro, Jeffrey Hsu, Many thanks to Anil Agarwal, Mark Allman, Armando Caro, Jeffrey Hsu,
Vern Paxson, Kacheong Poon, Keyur Shah, and Bernie Volz for detailed Vern Paxson, Kacheong Poon, Keyur Shah, and Bernie Volz for detailed
feedback on this document or on its precursor, RFC 2582. Jeffrey feedback on this document or on its precursor, RFC 2582. Jeffrey
Hsu provided clarifications on the handling of the recover variable Hsu provided clarifications on the handling of the recover variable
that were applied to RFC 3782 as errata, and now are in Section 8 that were applied to RFC 3782 as errata, and now are in Section 8
of this document. Yoshifumi Nishida contributed a modification of this document. Yoshifumi Nishida contributed a modification
to the fast recovery algorithm to account for the case in which to the fast recovery algorithm to account for the case in which
skipping to change at page 15, line 24 skipping to change at page 13, line 42
[RFC3042] Allman, M., Balakrishnan, H. and S. Floyd, "Enhancing TCP's [RFC3042] Allman, M., Balakrishnan, H. and S. Floyd, "Enhancing TCP's
Loss Recovery Using Limited Transmit", RFC 3042, January 2001. Loss Recovery Using Limited Transmit", RFC 3042, January 2001.
[RFC3522] Ludwig, R. and M. Meyer, "The Eifel Detection Algorithm for [RFC3522] Ludwig, R. and M. Meyer, "The Eifel Detection Algorithm for
TCP", RFC 3522, April 2003. TCP", RFC 3522, April 2003.
[RFC3782] Floyd, S., T. Henderson, and A. Gurtov, "The NewReno [RFC3782] Floyd, S., T. Henderson, and A. Gurtov, "The NewReno
Modification to TCP's Fast Recovery Algorithm", RFC 3782, April 2004. Modification to TCP's Fast Recovery Algorithm", RFC 3782, April 2004.
Appendix A. Resetting the Retransmit Timer in Response to Partial Appendix A. Additional Information
Acknowledgments
One possible variant to the response to partial acknowledgments
specified in Section 3 concerns when to reset the retransmit timer
after a partial acknowledgment. The algorithm in Section 3, Step 5,
resets the retransmit timer only after the first partial ACK. In
this case, if a large number of packets were dropped from a window of
data, the TCP data sender's retransmit timer will ultimately expire,
and the TCP data sender will invoke Slow-Start. (This is illustrated
on page 12 of [F98].) We call this the Impatient variant of NewReno.
We note that the Impatient variant in Section 3 doesn't follow the
recommended algorithm in RFC 2988 of restarting the retransmit timer
after every packet transmission or retransmission (step 5.1 of
[RFC2988]).
In contrast, the NewReno simulations in [FF96] illustrate the
algorithm described above with the modification that the retransmit
timer is reset after each partial acknowledgment. We call this the
Slow-but-Steady variant of NewReno. In this case, for a window with
a large number of packet drops, the TCP data sender retransmits at
most one packet per roundtrip time. (This behavior is illustrated in
the New-Reno TCP simulation of Figure 5 in [FF96], and on page 11 of
[F98]).
When N packets have been dropped from a window of data for a large
value of N, the Slow-but-Steady variant can remain in Fast Recovery
for N round-trip times, retransmitting one more dropped packet each
round-trip time; for these scenarios, the Impatient variant gives a
faster recovery and better performance.
The Impatient variant can be particularly important for TCP
connections with large congestion windows.
One can also construct scenarios where the Slow-but-Steady variant
gives better performance than the Impatient variant. As an example,
this occurs when only a small number of packets are dropped, the RTO
is sufficiently small that the retransmit timer expires, and
performance would have been better without a retransmit timeout.
The Slow-but-Steady variant can also achieve higher goodput than the
Impatient variant, by avoiding unnecessary retransmissions. This
could be of special interest for cellular links, where every
transmission costs battery power and money. The
Slow-but-Steady variant can also be more robust to delay variation in
the network, where a delay spike might force the Impatient variant into
a timeout and go-back-N recovery.
Neither of the two variants discussed above are optimal. Our
recommendation is for the Impatient variant, as specified in Section
3 of this document, because of the poor performance of the
Slow-but-Steady variant for TCP connections with large congestion
windows.
One possibility for a more optimal algorithm would be one that
recovered from multiple packet drops as quickly as does slow-start,
while resetting the retransmit timers after each partial
acknowledgment, as described in the section below. We note,
however, that there is a limitation to the potential performance in
this case in the absence of the SACK option.
Appendix B. Retransmissions after a Partial Acknowledgment
One possible variant to the response to partial acknowledgments
specified in Section 3 would be to retransmit more than one packet
after each partial acknowledgment, and to reset the retransmit timer
after each retransmission. The algorithm specified in Section 3
retransmits a single packet after each partial acknowledgment. This
is the most conservative alternative, in that it is the least likely
to result in an unnecessarily-retransmitted packet. A variant that
would recover faster from a window with many packet drops would be to
effectively Slow-Start, retransmitting two packets after each partial
acknowledgment. Such an approach would take less than N roundtrip
times to recover from N losses [Hoe96]. However, in the absence of
SACK, recovering as quickly as slow-start introduces the likelihood
of unnecessarily retransmitting packets, and this could significantly
complicate the recovery mechanisms.
We note that the response to partial acknowledgments specified in
Section 3 of this document and in RFC 2582 differs from the response
in [FF96], even though both approaches only retransmit one packet in
response to a partial acknowledgment. Step 5 of Section 3 specifies
that the TCP sender responds to a partial ACK by deflating the
congestion window by the amount of new data acknowledged, adding
back SMSS bytes if the partial ACK acknowledges at least SMSS bytes
of new data, and sending a new segment if permitted by the new value
of cwnd. Thus, only one previously-sent packet is retransmitted in
response to each partial acknowledgment, but additional new packets
might be transmitted as well, depending on the amount of new data
acknowledged by the partial acknowledgment. In contrast, the
variant of NewReno illustrated in [FF96] simply set the congestion
window to ssthresh when a partial acknowledgment was received. The
approach in [FF96] is more conservative, and does not attempt to
accurately track the actual number of outstanding packets after a
partial acknowledgment is received. While either of these
approaches gives acceptable performance, the variant specified in
Section 3 recovers more smoothly when multiple packets are dropped
from a window of data.
Appendix C. Avoiding Multiple Fast Retransmits
This appendix describes the motivation for the sender's state
variable "recover".
In the absence of the SACK option or timestamps, a duplicate
acknowledgment carries no information to identify the data packet or
packets at the TCP data receiver that triggered that duplicate
acknowledgment. In this case, the TCP data sender is unable to
distinguish between a duplicate acknowledgment that results from a
lost or delayed data packet, and a duplicate acknowledgment that
results from the sender's unnecessary retransmission of a data packet
that had already been received at the TCP data receiver. Because of
this, with the Retransmit and Fast Recovery algorithms in Reno TCP,
multiple segment losses from a single window of data can sometimes
result in unnecessary multiple Fast Retransmits (and multiple
reductions of the congestion window) [F94].
With the Fast Retransmit and Fast Recovery algorithms in Reno TCP,
the performance problems caused by multiple Fast Retransmits are
relatively minor compared to the potential problems with Tahoe TCP,
which does not implement Fast Recovery. Nevertheless, unnecessary
Fast Retransmits can occur with Reno TCP unless some explicit
mechanism is added to avoid this, such as the use of the "recover"
variable. (This modification is called "bugfix" in [F98], and is
illustrated on pages 7 and 9 of that document. Unnecessary Fast
Retransmits for Reno without "bugfix" is illustrated on page 6 of
[F98].)
Section 3 of [RFC2582] defined a default variant of NewReno TCP that
did not use the variable "recover", and did not check if duplicate
ACKs cover the variable "recover" before invoking Fast Retransmit.
With this default variant from RFC 2582, the problem of multiple Fast
Retransmits from a single window of data can occur after a Retransmit
Timeout (as in page 8 of [F98]) or in scenarios with reordering.
RFC 2582 also defined Careful and Less Careful variants of the NewReno
algorithm, and recommended the Careful variant.
The algorithm specified in Section 3 of this document corresponds to
the Careful variant of NewReno TCP from RFC 2582, and eliminates the
problem of multiple Fast Retransmits. This algorithm uses the
variable "recover", whose initial value is the initial send sequence
number. After each retransmit timeout, the highest sequence number
transmitted so far is recorded in the variable "recover".
Appendix D. Simulations
This section provides pointers to simulation scripts available in
the NS simulator that reproduce behavior described above.
In Section 3, a simple mechanism is described to limit the number of
data packets that can be sent in response to a single acknowledgment.
This is known as "maxburst_" in the NS simulator.
Simulations with NewReno are illustrated with the validation test
"tcl/test/test-all-newreno" in the NS simulator. The command
"../../ns test-suite-newreno.tcl reno" shows a simulation with Reno
TCP, illustrating the data sender's lack of response to a partial
acknowledgment. In contrast, the command "../../ns
test-suite-newreno.tcl newreno_B" shows a simulation with the same
scenario using the NewReno algorithms described in this paper.
Regarding the handling of duplicate acknowledgments after a timeout,
the congestion window check serves to protect against fast retransmit
immediately after a retransmit timeout, similar to the
"exitFastRetrans_" variable in NS. Examples of applying the ACK
heuristic (Section 4) are in validation tests "./test-all-newreno
newreno_rto_loss_ack" and "./test-all-newreno newreno_rto_dup_ack" in
directory "tcl/test" of the NS simulator.
If several ACKs are lost, the sender can see a jump in the cumulative
ACK of more than three segments, and the heuristic can fail. A
validation test for this scenario is "./test-all-newreno
newreno_rto_loss_ackf".
Examples of applying the timestamp heuristic (Section 4) are in
validation tests "./test-all-newreno newreno_rto_loss_tsh" and
"./test-all-newreno newreno_rto_dup_tsh".
Section 6 described a problem involving possible spurious timeouts,
and mentions that this bug existed in the NS simulator.
This bug in the NS simulator was fixed in July 2003,
with the variable "exitFastRetrans_".
Regarding the Slow-but-Steady and Impatient variants described
in Appendix A, The tests "ns
test-suite-newreno.tcl impatient1" and "ns test-suite-newreno.tcl
slow1" in the NS simulator illustrate a scenario in which the
Impatient variant performs better than the Slow-but-Steady
variant. The Impatient variant can be particularly important for TCP
connections with large congestion windows, as illustrated by the tests
"ns test-suite-newreno.tcl impatient4" and "ns test-suite-newreno.tcl
slow4" in the NS simulator. The tests
"ns test-suite-newreno.tcl impatient2" and
"ns test-suite-newreno.tcl slow2" in the NS simulator illustrate
scenarios in which the Slow-but-Steady variant outperforms the Impatient
variant. The tests "ns test-suite-newreno.tcl impatient3" and
"ns test-suite-newreno.tcl slow3" in the NS simulator illustrate
scenarios in which the Slow-but-Steady variants avoid unnecessary
retransmissions.
Appendix B describes different policies for partial window deflation.
The [FF96] behavior can be seen in the NS
simulator by setting the variable "partial_window_deflation_" for
"Agent/TCP/Newreno" to 0; the behavior specified in Section 3 is
achieved by setting "partial_window_deflation_" to 1.
Section 3 of [RFC2582] defined a default variant of NewReno TCP that
did not use the variable "recover", and did not check if duplicate
ACKs cover the variable "recover" before invoking Fast Retransmit.
With this default variant from RFC 2582, the problem of multiple Fast
Retransmits from a single window of data can occur after a Retransmit
Timeout (as in page 8 of [F98]) or in scenarios with reordering (as
An NS validation test "./test-all-newreno newreno5_noBF" in
directory "tcl/test" of the NS simulator illustartes the default
variant of NewReno TCP that doesn't use the variable "recover";
this gives performance similar to that on page 8 of [F03].
Appendix E. Comparisons between Reno and NewReno TCP
As we stated in the introduction, we believe that the NewReno
modification described in this document improves the performance of
the Fast Retransmit and Fast Recovery algorithms of Reno TCP in a
wide variety of scenarios. This has been discussed in some depth in
[FF96], which illustrates Reno TCP's poor performance when multiple
packets are dropped from a window of data and also illustrates
NewReno TCP's good performance in that scenario.
We do, however, know of one scenario where Reno TCP gives better
performance than NewReno TCP, that we describe here for the sake of
completeness. Consider a scenario with no packet loss, but with
sufficient reordering so that the TCP sender receives three duplicate
acknowledgments. This will trigger the Fast Retransmit and Fast
Recovery algorithms. With Reno TCP or with Sack TCP, this will
result in the unnecessary retransmission of a single packet, combined
with a halving of the congestion window (shown on pages 4 and 6 of
[F03]). With NewReno TCP, however, this reordering will also result
in the unnecessary retransmission of an entire window of data (shown
on page 5 of [F03]).
While Reno TCP performs better than NewReno TCP in the presence of
reordering, NewReno's superior performance in the presence of
multiple packet drops generally outweighs its less optimal
performance in the presence of reordering. (Sack TCP is the
preferred solution, with good performance in both scenarios.) This
document recommends the Fast Retransmit and Fast Recovery algorithms
of NewReno TCP instead of those of Reno TCP for those TCP connections
that do not support SACK. We would also note that NewReno's Fast
Retransmit and Fast Recovery mechanisms are widely deployed in TCP
implementations in the Internet today, as documented in [PF01]. For
example, tests of TCP implementations in several thousand web servers
in 2001 showed that for those TCP connections where the web browser
was not SACK-capable, more web servers used the Fast Retransmit and
Fast Recovery algorithms of NewReno than those of Reno or Tahoe TCP
[PF01].
Appendix F. Changes Relative to RFC 2582 Previous versions of this RFC ([RFC2582], [RFC3782]) contained
additional informative material on the following subjects, and
may be consulted by readers who may want more information about
possible variants to the algorithm and who may want references
to specific [NS] simulations that provide NewReno test cases.
The purpose of this document is to advance the NewReno's Fast Section 4 of [RFC3782] discusses some alternative behaviors for
Retransmit and Fast Recovery algorithms in RFC 2582 to Standards Track. resetting the retransmit timer after a partial acknowledgment.
The main change in this document relative to RFC 2582 is to specify Section 5 of [RFC3782] discusses some alternative behaviors for
the Careful variant of NewReno's Fast Retransmit and Fast Recovery performing retransmission after a partial acknowledgment.
algorithms. The base algorithm described in RFC 2582 did not attempt
to avoid unnecessary multiple Fast Retransmits that can occur after a
timeout (described in more detail in the section above). However,
RFC 2582 also defined "Careful" and "Less Careful" variants that
avoid these unnecessary Fast Retransmits, and recommended the Careful
variant. This document specifies the previously-named "Careful"
variant as the basic version of NewReno. As described below, this
algorithm uses a variable "recover", whose initial value is the send
sequence number.
The algorithm specified in Section 3 checks whether the Section 6 of [RFC3782] describes more information about the
acknowledgment field of a partial acknowledgment covers *more* than motivation for the sender's state variable Recover.
"recover", as defined in Section 3. Another possible variant would be
to simply require that the acknowledgment field covers *more than or
equal to* "recover" before initiating another Fast Retransmit. We
called this the Less Careful variant in RFC 2582.
There are two separate scenarios in which the TCP sender could Section 9 of [RFC3782] introduces some NS simulation test
receive three duplicate acknowledgments acknowledging "recover" but suites for NewReno. In addition, references to simulation
no more than "recover". One scenario would be that the data sender results can be found throughout [RFC3782].
transmitted four packets with sequence numbers higher than "recover",
that the first packet was dropped in the network, and the following
three packets triggered three duplicate acknowledgments
acknowledging "recover". The second scenario would be that the
sender unnecessarily retransmitted three packets below "recover", and
that these three packets triggered three duplicate acknowledgments
acknowledging "recover". In the absence of SACK, the TCP sender is
unable to distinguish between these two scenarios.
For the Careful variant of Fast Retransmit, the data sender would Section 10 of [RFC3782] provides a comparison of Reno and
have to wait for a retransmit timeout in the first scenario, but NewReno TCP.
would not have an unnecessary Fast Retransmit in the second
scenario. For the Less Careful variant to Fast Retransmit, the data
sender would Fast Retransmit as desired in the first scenario, and would
unnecessarily Fast Retransmit in the second scenario. This document
only specifies the Careful variant in Section 3. Unnecessary Fast
Retransmits with the Less Careful variant in scenarios with
reordering are illustrated in page 8 of [F03].
The document also specifies two heuristics that the TCP sender MAY Section 11 of [RFC3782] listed changes relative to [RFC3782].
use to decide to invoke Fast Retransmit even when the three duplicate
acknowledgments do not cover more than "recover". These heuristics,
an ACK-based heuristic and a timestamp heuristic, are described in
Sections 6.1 and 6.2 respectively.
Appendix G. Changes Relative to RFC 3782 Appendix B. Changes Relative to RFC 3782
In [RFC3782], the cwnd after Full ACK reception will be set to In [RFC3782], the cwnd after Full ACK reception will be set to
(1) min (ssthresh, FlightSize + SMSS) or (2) ssthresh. However, (1) min (ssthresh, FlightSize + SMSS) or (2) ssthresh. However,
there is a risk in the first logic which results in performance there is a risk in the first logic which results in performance
degradation. With the first logic, if FlightSize is zero, the result degradation. With the first logic, if FlightSize is zero, the result
will be 1 SMSS. This means TCP can transmit only 1 segment at this will be 1 SMSS. This means TCP can transmit only 1 segment at this
moment, which can cause delay in ACK transmission at receiver due to moment, which can cause delay in ACK transmission at receiver due to
delayed ACK algorithm. delayed ACK algorithm.
The FlightSize on Full ACK reception can be zero in some situations. The FlightSize on Full ACK reception can be zero in some situations.
A typical example is where sending window size during fast recovery is A typical example is where sending window size during fast recovery is
small. In this case, the retransmitted packet and new data packets can small. In this case, the retransmitted packet and new data packets can
be transmitted within a short interval. If all these packets be transmitted within a short interval. If all these packets
successfully arrive, the receiver may generate a Full ACK that successfully arrive, the receiver may generate a Full ACK that
acknowledges all outstanding data. Even if window size is not small, acknowledges all outstanding data. Even if window size is not small,
loss of ACK packets or receive buffer shortage during fast recovery can loss of ACK packets or receive buffer shortage during fast recovery can
also increase the possibility to fall into this situation. also increase the possibility to fall into this situation.
The proposed fix in this document ensures that sender TCP transmits at The proposed fix in this document ensures that sender TCP transmits at
least two segments on Full ACK reception. least two segments on Full ACK reception.
In addition, errata for RFC3782 (editorial clarification to Section 8 In addition, errata for RFC3782 (editorial clarification to Section 8
of RFC2582, which is now Section 6 of this document) has been applied. of RFC2582, which is now Section 6 of this document) has been applied.
Sections 4, 5, and 9-11 of RFC2582 were relocated to appendices of The specification text (Section 3.2 herein) was rewritten to more
this document since they are non-normative and provide background closely track Section 3.2 of [RFC5681].
information and references to simulation results.
Appendix H. Document Revision History Sections 4, 5, 9-11 of [RFC3782] were removed, and instead Appendix
A of this document was added to back-reference this informative
material.
To be removed upon publication Appendix C. Document Revision History
To be removed upon publication
+----------+--------------------------------------------------+ +----------+--------------------------------------------------+
| Revision | Comments | | Revision | Comments |
+----------+--------------------------------------------------+ +----------+--------------------------------------------------+
| draft-00 | RFC3782 errata applied, and changes applied from | | draft-00 | RFC3782 errata applied, and changes applied from |
| | draft-nishida-newreno-modification-02 | | | draft-nishida-newreno-modification-02 |
+----------+--------------------------------------------------+ +----------+--------------------------------------------------+
| draft-01 | Non-normative sections moved to appendices, | | draft-01 | Non-normative sections moved to appendices, |
| | editorial clarifications applied as suggested | | | editorial clarifications applied as suggested |
| | by Alexander Zimmermann. | | | by Alexander Zimmermann. |
+----------+--------------------------------------------------+ +----------+--------------------------------------------------+
| draft-02 | Better align specification text with RFC5681. |
| | Replace informative appendices by a new appendix |
| | that just provides back-references to earlier |
| | NewReno RFCs. |
+----------+--------------------------------------------------+
Authors' Addresses Authors' Addresses
Tom Henderson Tom Henderson
The Boeing Company The Boeing Company
EMail: thomas.r.henderson@boeing.com EMail: thomas.r.henderson@boeing.com
Sally Floyd Sally Floyd
International Computer Science Institute International Computer Science Institute
 End of changes. 50 change blocks. 
445 lines changed or deleted 139 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/