Sep 17, 2009

Advanced TCP Implementation(HS-TCP vs S-TCP vs BIC-TCP)

自從接觸了廣域網路加速器這個領域,愈來愈覺得自己對TCP的了解實在是只懂得皮毛而已。原來在TCP上的實現有這麼多種改進方式,使得TCP的傳輸表現更加優越。

以下的內容是節錄自Cisco Press Application Acceleration and WAN Optimization Fundamentals中的章節,由於這幾個協定可以說是各家廣域網路加速器都會參考的標準,用以改善原有TCP設計運作上的缺陷,所以我把它們整理出來加以分較,希望對各位有所幫助!

  • HS-TCP(High Speed TCP)
High-Speed TCP is a advanced TCP implementation that was developed primarily to address bandwidth scalability. HS-TCP uses an adaptive cwnd increase that is is based on the current cwnd value of the connection. When the cwnd value is large, HS-TCP uses a larger cwnd increase when a segment is successfully acknowledged. In effect, this helps HS-TCP to more quickly find the available bandwidth, which leads to higher levels of throughput on large networks much more quickly.

HS-TCP also uses an adaptive cwnd decrease based on the current cwnd value. When the cwnd value for a connection is large, HS-TCP uses a very small decrease to the connection's cwnd value when loss of a segment is detected. In this way, HS-TCP allows a connection to remain at very high levels of throughput even in the presence of packet loss but can also lead to longer stabilization of TCP throughput when other, non-HS-TCP connections are contending for available network capacity. The aggressive cwnd handling of HS-TCP can lead to a lack of fairness when non-HS-TCP flows are competing for available network bandwidth. Over time, non-HS-TCP flows can stabilize with HS-TCP flows, but this period of time may be extended due to the aggressive behavior of HS-TCP.

  • S-TCP(Scalable TCP)
Scalable TCP(S-TCP) is similar to HS-TCP in that it uses an adaptive increase to cwnd. S-TCP will increase cwnd by a value of (cwnd x .01) when increasing the congestion windows, which means the increment is large when cwnd is large and the increment is small when cwnd is small.

Rather than use an adaptive decrease in cwnd, S-TCP will decrease cwnd by 12.5%(1/8) upon encountering a loss of a segment. In this way, S-TCP is more TCP friendly than HS-TCP in high-bandwidth environments. Like HS-TCP, S-TCP is not fair among flows where an RTT disparity exists due to the overly aggressive cwnd handling.

  • BIC-TCP(Binary Increase Congestion TCP)
Bindary Increase Congestion TCP(BIC-TCP) is an advanced TCP stack that uses a more adaptive increase than that used by HS-TCP and S-TCP. HS-TCP and S-TCP use a variable increment to cwnd directly based on the value of cwnd. BIC-TCP uses connection loss history to adjust the behavior of congestion avoidance to provide fairness.

BIC-TCP's congestion avoidance algorithm uses two search modes - linear search and binary search - as compared to the single search mode (linear or linear relative to cwnd) provided by standard TCP, HS-TCP, and S-TCP. These two search modes allow BIC-TCP to adequately maintain bandwidth scalability and fairness while also avoiding additional levels of packet lost caused by excessive cwnd aggressiveness.
  1. Linear search: Uses a calculation of the difference between the current cwnd and the previous cwnd prior to the loss event the determine the rate of linear search.
  2. Bindary search: Used as congestion avoidance approaches the previous cwnd value prior to the loss event. This allows BIC-TCP to mitigate additional loss events caused by the connection exceeding available network capacity after a packet loss event.
The linear search provides aggressive handling to ensure a rapid return to previous levels of throughput, while the binary search not only helps to minimize an additional loss even, but also helps to improve fairness of environments with RTT disparity(that is, two nodes exchanging data are closer than two other nodes that are exchanging data) in that it allows convergence of TCP throughput across connections much more fairly and quickly.


Post a Comment