聊一聊 tcp擁塞控制 fack
FACK 重傳
FACK 是 SACK 的一個激進版本,它擁有標準 SACK 演算法的一切性質,除此之外,它假設網路不會使資料包亂序,因此收到最大的被 SACK 的資料包之前,FACK 均認為是丟失的。FACK 模式下,重傳時機為 被 SACKed 的包數 + 空洞數 > dupthresh同時dupack ==dupthresh(3) 預設。
如下圖所示,設 dupthresh = 3,FACKed_count = 12,從 unACKed 包開始的 FACKed_count
dupthresh 個數據包,即 9 個包會被標記為 LOST。
擁塞視窗狀態
記分板狀態如下,紅色表示該資料包丟失.
FACK Design Goals
The requisite network state information can be obtained with accurate knowledge about the forward most data held by the receiver. By forward-most, we mean the correctly-received data with the highest sequence number. This is the origin of the name "forward acknowledgement."The goal of the FACK algorithm is to perform precise congestion control during recovery by keeping an accurate estimate of the amount of data outstanding in the network.
FACKAlgorithm
When a SACK block is received which acknowledges data with a higher sequence number than the current value of snd.fack, snd.fack is updated to reflect the highest sequence number known to have been received plus one. The FACK algorithm uses the additional information provided by the SACK option to keep an explicit measure of the total number of bytes of data outstanding in the network. In contrast, Reno and Reno + SACK both attempt to estimate this by assuming that each duplicate ACK received represents
one segment which has left the network. The FACK algorithm is able to do this in a staightforward way by introducing two new state variables, snd.fack and retran_data.
TCP's estimate of the amount of data outstanding in the network during recovery is given by:
awind = snd.nxt - snd.fack + retran_data
Triggering Recovery
Reno invokes Fast Recovery by counting duplicate acknowledgements:
if ( dupacks == 3 ) { ... }
This algorithm causes an unnecessary delay if several segments are lost prior to receiving three duplicate acknowledgements. In the FACK version, the cwnd adjustment and retransmission arealso triggered when the receiver reports that the reassembley queue is longer than 3 segments:
if ( ( snd.fack - snd.una ) > (3*MSS) ) || (dupacks == 3) ) { ... }
參考:https://blog.csdn.net/zhangskd/article/details/7236727
http代理伺服器(3-4-7層代理)-網路事件庫公共元件、核心kernel驅動 攝像頭驅動 tcpip網路協議棧、netfilter、bridge 好像看過!!!! 但行好事 莫問前程 --身高體重180的胖子