Linux 2.4 Implementation of Westwood+ TCP with Rate Halving : A Performance Evaluation over the Internet Angelo Dell'Aera Luigi Alfredo Grieco Saverio Mascolo Dipartimento di Elettrotecnica ed Elettronica Politecnico di Bari Via Orabona 4 70125 Bari, Italy ICC2004 Paris Jun 22, 2004 1
Outline Background of TCP Westwood and TCP Westwood+ End to End Bandwidth Estimation by filtering the ACK stream Linux implementation of TCP Westwood+ Internet measurements 2
TCP Westwood Congestion Control Key idea: use end to end bandwidth estimation to adaptively set cwnd and ssthresh after congestion instead of standard blind multiplicative window decrease 3
Standard TCP (Van Jacobson) cwnd ssthresh Linear increasing Fast recovery Timeout Exponential increasing time Slow Start (SS) Congestion Avoidance (CA) Typical cwnd dynamics following the AIMD paradigm 4
TCP Westwood cwnd ssthresh Congestion Avoidance Adaptive Decrease cwnd = ssthresh = BWE * RTTmin Timeout BWE*RTTmin Slow start time TCP Westwood Adaptive Decrease vs TCP (New) Reno blind by ½ window shrinking 5
Known drawbacks of TCP Reno Low throughput over wireless links because losses due to unreliable links are misinterpreted as congestion Reno throughput is proportional to 1/RTT,, i.e. it is not fair 6
End to End Bandwidth Estimation TCP Westwood+ algorithm is based on end to end estimation of the bandwidth available along the TCP connection path The estimate is obtained by filtering the stream of returning ACK packets and it is used to adaptively set the control windows when network congestion is experienced 7
End to End Bandwidth Estimation packets packets SENDER RECEIVER Bandwidth estimate Filter ACKs Network ACKs 8
TCP Westwood+ Pseudo Code When 3 DUPACKs are received by the sender ssthresh=max(2, (BWE * RTTmin) / MSS); cwnd = ssthresh; When coarse timeout expires ssthresh=max(2, (BWE * RTTmin) / MSS); cwnd = 1; When ACKs are successfully received cwnd increases as stated in RFC2581 the end to end bandwidth estimate BWE is computed 9
TCP Westwood+ TCP Westwood+ follows an Additive Increase Adaptive Decrease paradigm TCP Westwood+ improves the stability of the standard TCP multiplicative decrease algorithm The congestion window is decreased enough in presence of heavy congestion and not too much in presence of light congestion or losses not due to congestion 10
TCP Westwood+ The adaptive setting of the control windows increases the fair allocation of the available bandwidth to different TCP flows Setting cwnd to BWE * RTTmin sustains a transmission rate ((BWE * RTTmin) / RTT) smaller than the bandwidth estimated at the time of congestion thus leaving room in the buffers for coexisting flows This improves statistical multiplexing and fairness 11
Warning ACKs reach the TCP sender compressed Bandwidth samples b j = d j t j t j 1 contain high frequency components that cannot be filtered out by a discrete time filter due to aliasing t j t j 1 = ACK interarrival time 12
ACK compression effects ACK pairs give information about the bandwidth of the last link traversed on the backward path To smooth ACK compression we accumulate ACKs over an RTT and then compute a bandwidth sample 13
An anti aliasing filter in packet networks b j = d j j A n tialiased sam ples j = Last RTT d j = all data acknowledged in the last RTT 14
End to End Bandwidth Estimate TCP Westwood+ Internet BWE Segments sent Low pass filter Anti ACK compression Returning ACKs 15
End to End Bandwidth Estimate The following time invariant low pass filter is used b k = d k RTT k bˆ k = α bˆ + (1 ) k 1 α b k 16
ACK compression effects We have found that ACK compression has very important effects on TCP ACK compression must be considered when doing simulation 17
Topology with ACK compression effects (10 Mbps) 20 TCP Forward traffic: 20 TCP Westwood connections Sink R R 10 TCP Sinks Reverse traffic: 10 TCP long lived NewReno connections 10 TCP Connections 18
The 20 Westwood+ connections estimate a best effort available bandwidth that reasonably approaches the fair share of 0.5 Mbps 1.0E+09 Bandwidth estimate (bps) 1.0E+08 1.0E+07 1.0E+06 1.0E+05 1.0E+04 1.0E+03 1.0E+02 1.0E+01 Fair share 0 20 40 60 80 100 s 19
Westwood overestimates up to 100 times the fair share due to ACK compression 1.0E+09 Bandwidth estimate (bps) 1.0E+08 1.0E+07 1.0E+06 1.0E+05 1.0E+04 1.0E+03 1.0E+02 1.0E+01 0 20 40 60 80 100 s Fair share 20
Summary on bandwidth estimate TCP Westwood : one bandwidth sample computed for each ACK (leads to bandwidth overestimate in presence of ACK compression) TCP Westwood+ : one bandwidth sample computed for each RTT 21
Linux Implementation of TCP Westwood+ Linux 2.4 TCP implementation supports the Rate Halving congestion control algorithm The Rate Halving congestion control algorithm adjusts the window by sending one segment per two acknowledgments for exactly one round trip 22
Linux Implementation of TCP Westwood+ Rate Halving sets the window to exactly one half of the data which was actually held in the network during the congested round trip Rate Halving has been slightly modified by setting the lower bound for cwnd decrease to BWE * RTTmin 23
Linux Implementation of TCP Westwood+ The patch has been developed to be as less intrusive as possible. In fact, it's possible to enable/disable TCP Westwood+ through the sysctl net.ipv4.tcp_westwood The sysctl allows to switch between TCP New Reno and TCP Westwood+ 24
Linux Implementation of TCP Westwood+ TCP Westwood+ support was integrated in the Linux kernel release 2.4.26 pre1 (kernel 2.4) and kernel release 2.6.3 rc1 (kernel 2.6) http://www.kernel.org http://buffer.antifork.org/westwood/westwood.html 25
Internet measurements More than 4000 FTP from Bari, South Italy to: panther.cs.ucla.edu (UCLA) signserv.signal.uu.se (Uppsala) main.penguin.it (Parma) 26
Uploads to panther.cs.ucla.edu (1) File size=3.2mb, From: rigel.poliba.it, To: panther.cs.ucla.edu, Total number of uploads = 197, Average New Reno Goodput = 16.86Kbyte/s, Average Westwood+ Goodput = 25.21Kbyte/s Goodput (KB/s) 60 50 40 30 20 10 Westwood+ New Reno 0 Wed Feb 26 13:35:16 Wed Feb 26 19:38:03 Wed Feb 26 22:53:27 Thu Feb 27Thu Feb 27Thu Feb 27Thu Feb 27 01:41:26 04:10:01 06:11:28 08:23:06 Date 27
Uploads to panther.cs.ucla.edu (2) File size=32mb 80 70 Westwood+ New Reno 60 Goodput (KB/s) 50 40 30 20 10 0 Fri Feb 21 18:15:56 Sat Feb 22 06:04:31 Sat Feb 22 20:26:44 Sun Feb 23 07:24:58 Date Sun Feb 23 19:06:51 Mon Feb 24 03:52:51 28
Uploads to panther.cs.ucla.edu (3) 60 50 File size=32mb Westwood+ New Reno Goodput (KB/s) 40 30 20 10 0 Fri Mar 14 18:59:15 Sat Mar 15 06:09:27 Sat Mar 15 13:29:48 Sat Mar 15 22:20:43 Date Sun Mar 16 09:57:01 Mon Mar 17 02:47:05 29
Uploads to panther.cs.ucla.edu (4) 70 60 Westwood+ New Reno File size=32mb Goodput (KB/s 50 40 30 20 10 0 Wed Mar 19 14:15:25 Wed Mar 19 22:55:38 Thu Mar 20 02:47:10 Thu Mar 20 06:08:36 Thu Mar 20 10:45:34 Date Thu Mar 20 19:52:36 Fri Mar 21 01:07:10 Fri Mar 21 05:29:19 30
Main References L. A. Grieco, S. Mascolo Performance Comparison of Reno, Vegas, and Westwood+TCP Congestion Control ACM CCR Vol. 34 No. 2, April 2004 S. Mascolo, C. Casetti, M. Gerla, S. Lee, M. Sanadidi TCP Westwood: bandwidth estimation for enhanced transport over wireless links ACM Mobicom 2001 and Winet Journal 2002 L. A. Grieco and S. Mascolo, End to End Bandwidth Estimation for Congestion Control in Packet Networks Second International Workshop QoS IP 31
Thanks for the attention Questions? 32