--- 1/draft-ietf-tcpm-cubic-05.txt 2017-09-17 19:13:17.395636840 -0700 +++ 2/draft-ietf-tcpm-cubic-06.txt 2017-09-17 19:13:17.435637795 -0700 @@ -1,26 +1,26 @@ TCP Maintenance and Minor Extensions (TCPM) WG I. Rhee Internet-Draft NCSU Intended status: Informational L. Xu -Expires: January 18, 2018 UNL +Expires: March 21, 2018 UNL S. Ha Colorado A. Zimmermann L. Eggert NetApp R. Scheffenegger - July 17, 2017 + September 17, 2017 CUBIC for Fast Long-Distance Networks - draft-ietf-tcpm-cubic-05 + draft-ietf-tcpm-cubic-06 Abstract CUBIC is an extension to the current TCP standards. The protocol differs from the current TCP standards only in the congestion window adjustment function in the sender side. In particular, it uses a cubic function instead of a linear window increase function of the current TCP standards to improve scalability and stability under fast and long distance networks. CUBIC and its predecessor algorithm have been adopted as default by Linux and have been used for many years. @@ -29,37 +29,37 @@ experimentation on the performance of CUBIC. Status of This Memo This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet- - Drafts is at http://datatracker.ietf.org/drafts/current/. + Drafts is at https://datatracker.ietf.org/drafts/current/. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." - This Internet-Draft will expire on January 18, 2018. + This Internet-Draft will expire on March 21, 2018. Copyright Notice Copyright (c) 2017 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 + (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License. Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 @@ -69,32 +69,32 @@ 4.1. Window growth function . . . . . . . . . . . . . . . . . 6 4.2. TCP-friendly region . . . . . . . . . . . . . . . . . . . 7 4.3. Concave region . . . . . . . . . . . . . . . . . . . . . 7 4.4. Convex region . . . . . . . . . . . . . . . . . . . . . . 7 4.5. Multiplicative decrease . . . . . . . . . . . . . . . . . 8 4.6. Fast convergence . . . . . . . . . . . . . . . . . . . . 8 4.7. Timeout . . . . . . . . . . . . . . . . . . . . . . . . . 9 4.8. Slowstart . . . . . . . . . . . . . . . . . . . . . . . . 9 5. Discussion . . . . . . . . . . . . . . . . . . . . . . . . . 9 5.1. Fairness to standard TCP . . . . . . . . . . . . . . . . 10 - 5.2. Using Spare Capacity . . . . . . . . . . . . . . . . . . 11 + 5.2. Using Spare Capacity . . . . . . . . . . . . . . . . . . 12 5.3. Difficult Environments . . . . . . . . . . . . . . . . . 12 - 5.4. Investigating a Range of Environments . . . . . . . . . . 12 + 5.4. Investigating a Range of Environments . . . . . . . . . . 13 5.5. Protection against Congestion Collapse . . . . . . . . . 13 5.6. Fairness within the Alternative Congestion Control Algorithm. . . . . . . . . . . . . . . . . . . . . . . . 13 5.7. Performance with Misbehaving Nodes and Outside Attackers 13 5.8. Behavior for Application-Limited Flows . . . . . . . . . 13 - 5.9. Responses to Sudden or Transient Events . . . . . . . . . 13 - 5.10. Incremental Deployment . . . . . . . . . . . . . . . . . 13 - 6. Security Considerations . . . . . . . . . . . . . . . . . . . 13 - 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 13 + 5.9. Responses to Sudden or Transient Events . . . . . . . . . 14 + 5.10. Incremental Deployment . . . . . . . . . . . . . . . . . 14 + 6. Security Considerations . . . . . . . . . . . . . . . . . . . 14 + 7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 14 8. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . 14 9. References . . . . . . . . . . . . . . . . . . . . . . . . . 14 9.1. Normative References . . . . . . . . . . . . . . . . . . 14 9.2. Informative References . . . . . . . . . . . . . . . . . 15 Authors' Addresses . . . . . . . . . . . . . . . . . . . . . . . 16 1. Introduction The low utilization problem of TCP in fast long-distance networks is well documented in [K03][RFC3649]. This problem arises from a slow @@ -264,62 +264,65 @@ congestion detected by ECN-Echo ACKs occurs, CUBIC reduces its current window cwnd to W_cubic(0)=W_max*beta_cubic. We discuss how we set beta_cubic in Section 4.5 and how we set C in Section 5. Upon receiving an ACK during congestion avoidance, CUBIC computes the window growth rate during the next RTT period using Eq. 1. It sets W_cubic(t+RTT) as the candidate target value of congestion window, where RTT is the weithed average RTT calculated by the standard TCP. Depending on the value of the current window size cwnd, CUBIC runs in - three different modes. First, if cwnd is less than the window size - that Standard TCP would reach at time t after the last loss event, - then CUBIC is in the TCP friendly region (we describe below how to - determine this window size of Standard TCP in term of time t). - Otherwise, if cwnd is less than W_max, then CUBIC is the concave - region, and if cwnd is larger than W_max, CUBIC is in the convex - region. Below, we describe the exact actions taken by CUBIC in each - region. + three different modes. + + 1) The TCP-friendly region, which ensures that CUBIC achieves at + least the same throughput as the standard TCP. + + 2) The concave region, if CUBIC is not in the TCP-friendly region + and cwnd is less than W_max. + + 3) The convex region, if CUBIC is not in the TCP-friendly region + and cwnd is greater than W_max. + + Below, we describe the exact actions taken by CUBIC in each region. 4.2. TCP-friendly region Standard TCP performs well in certain types of networks, for example, under short RTT and small bandwidth (or small BDP) networks. In these networks, we use the TCP-friendly region to ensure that CUBIC achieves at least the same throughput as the standard TCP. - When receiving an ACK in congestion avoidance, we first check whether - the protocol is in the TCP region or not. This is done by estimating - the average rate of the Standard TCP using a simple analysis - described in [FHP00]. It considers the Standard TCP as a special - case of an Additive Increase and Multiplicative Decrease algorithm - (AIMD), which has an additive factor alpha_aimd and a multiplicative - factor beta_aimd with the following function: + The TCP-friendly region is designed according to the analysis + described in [FHP00]. The analysis studies the performance of an + Additive Increase and Multiplicative Decrease (AIMD) algorithm with + an additive factor of alpha_aimd (segment per RTT) and a + multiplicative factor of beta_aimd, denoted by AIMD(alpha_aimd, + beta_aimd). Specifically, the average window size of + AIMD(alpha_aimd, beta_aimd) can be calculated using Eq. 3. The + analysis shows that AIMD(alpha_aimd, beta_aimd) with + alpha_aimd=3*(1-beta_aimd)/(1+beta_aimd) achieves the same average + window size as the standard TCP that uses AIMD(1, 0.5). AVG_W_aimd = [ alpha_aimd * (1+beta_aimd) / (2*(1-beta_aimd)*p) ]^0.5 (Eq. 3) - By the same analysis, the average window size of Standard TCP is - (1.5/p)^0.5, as the Standard TCP is a special case of AIMD with - alpha_aimd=1 and beta_aimd=0.5. Thus, for Eq. 3 to be the same as - that of Standard TCP, alpha_aimd must be equal to - 3*(1-beta_aimd)/(1+beta_aimd). As AIMD increases its window by - alpha_aimd per RTT, we can get the window size of AIMD in terms of - the elapsed time t as follows: - - W_aimd(t) = W_max*beta_aimd + - [3*(1-beta_aimd)/(1+beta_aimd)] * (t/RTT) (Eq. 4) + Based on the above analysis, CUBIC uses Eq. 4 to estimate the window + size W_est of AIMD(alpha_aimd, beta_aimd) with + alpha_aimd=3*(1-beta_cubic)/(1+beta_cubic) and beta_aimd=beta_cubic, + which achieves the same average window size as the standard TCP. + When receiving an ACK in congestion avoidance (cwnd could be greater + than or less than W_max), CUBIC checks whether W_cubic(t) is less + than W_est(t). If so, CUBIC is in the TCP-friendly region and cwnd + SHOULD be set to W_est(t) at each reception of ACK. - If W_cubic(t) is less than W_aimd(t) (it does not matter whether cwnd - is greater than or less than W_max), then the protocol is in the TCP - friendly region and cwnd SHOULD be set to W_aimd(t) at each reception - of ACK. + W_est(t) = W_max*beta_cubic + + [3*(1-beta_cubic)/(1+beta_cubic)] * (t/RTT) (Eq. 4) 4.3. Concave region When receiving an ACK in congestion avoidance, if the protocol is not in the TCP-friendly region and cwnd is less than W_max, then the protocol is in the concave region. In this region, cwnd MUST be incremented by (W_cubic(t+RTT) - cwnd)/cwnd for each received ACK, where W_cubic(t+RTT) is calculated using Eq. 1. 4.4. Convex region @@ -399,20 +402,27 @@ but sets ssthresh using beta_cubic (same as in Section 4.5). 4.8. Slowstart CUBIC MUST employ a slow start algorithm, when the cwnd is no more than ssthresh. Among the slow start algorithms, CUBIC MAY choose the standard TCP slow start[RFC5681] in general networks, or the limited slow start [RFC3742] or hybrid slow start [HR08] for high-bandwidth and long-distance networks. + In the case when CUBIC runs the hybrid slow start [HR08], it may exit + the first slow start without incurring any packet loss and thus W_max + is undefined. In this special case, CUBIC switches to congestion + avoidance and increases its congestion window size using Eq. 1 where + K is set to 0 and W_max is set to the window size when CUBIC just + exits the slow start. + 5. Discussion In this section, we further discuss the safety features of CUBIC following the guidelines specified in [RFC5033]. With a deterministic loss model where the number of packets between two successive lost events is always 1/p, CUBIC always operates with the concave window profile which greatly simplifies the performance analysis of CUBIC. The average window size of CUBIC can be obtained by the following function: @@ -574,24 +584,24 @@ link. 5.7. Performance with Misbehaving Nodes and Outside Attackers This is not considered in the current CUBIC. 5.8. Behavior for Application-Limited Flows CUBIC does not raise its congestion window size if the flow is currently limited by the application instead of the congestion - window. In case of long periods when cwnd is not updated due to the - application rate limit, such as idle periods, t in Eq. 1 MUST NOT - include these periods; otherwise, W_cubic(t) might be very high after - restarting from these periods. + window. In case of long periods when cwnd has not been updated due + to the application rate limit, such as idle periods, t in Eq. 1 MUST + NOT include these periods; otherwise, W_cubic(t) might be very high + after restarting from these periods. 5.9. Responses to Sudden or Transient Events In case that there is a sudden congestion, a routing change, or a mobility event, CUBIC behaves the same as Standard TCP. 5.10. Incremental Deployment CUBIC requires only the change of TCP senders, and does not require any assistant of routers. @@ -613,63 +623,63 @@ responsible for any use that may be made of the information it contains. 9. References 9.1. Normative References [RFC2119] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, DOI 10.17487/RFC2119, March 1997, - . + . [RFC3649] Floyd, S., "HighSpeed TCP for Large Congestion Windows", RFC 3649, DOI 10.17487/RFC3649, December 2003, - . + . [RFC3742] Floyd, S., "Limited Slow-Start for TCP with Large Congestion Windows", RFC 3742, DOI 10.17487/RFC3742, March - 2004, . + 2004, . [RFC4960] Stewart, R., Ed., "Stream Control Transmission Protocol", RFC 4960, DOI 10.17487/RFC4960, September 2007, - . + . [RFC5033] Floyd, S. and M. Allman, "Specifying New Congestion Control Algorithms", BCP 133, RFC 5033, DOI 10.17487/RFC5033, August 2007, - . + . [RFC5348] Floyd, S., Handley, M., Padhye, J., and J. Widmer, "TCP Friendly Rate Control (TFRC): Protocol Specification", RFC 5348, DOI 10.17487/RFC5348, September 2008, - . + . [RFC5681] Allman, M., Paxson, V., and E. Blanton, "TCP Congestion Control", RFC 5681, DOI 10.17487/RFC5681, September 2009, - . + . [RFC6582] Henderson, T., Floyd, S., Gurtov, A., and Y. Nishida, "The NewReno Modification to TCP's Fast Recovery Algorithm", RFC 6582, DOI 10.17487/RFC6582, April 2012, - . + . [RFC6675] Blanton, E., Allman, M., Wang, L., Jarvinen, I., Kojo, M., and Y. Nishida, "A Conservative Loss Recovery Algorithm Based on Selective Acknowledgment (SACK) for TCP", RFC 6675, DOI 10.17487/RFC6675, August 2012, - . + . [RFC7567] Baker, F., Ed. and G. Fairhurst, Ed., "IETF Recommendations Regarding Active Queue Management", BCP 197, RFC 7567, DOI 10.17487/RFC7567, July 2015, - . + . 9.2. Informative References [CEHRX07] Cai, H., Eun, D., Ha, S., Rhee, I., and L. Xu, "Stochastic Ordering for Internet Congestion Control and its Applications", In Proceedings of IEEE INFOCOM , May 2007. [FHP00] Floyd, S., Handley, M., and J. Padhye, "A Comparison of Equation-Based and AIMD Congestion Control", May 2000.