请输入您要查询的百科知识:

 

词条 纳格算法
释义

纳格算法是以减少封包传送量来增进TCP/IP网络的效能。 它是由约翰.纳格任职于Ford Aerospace时命名。

纳格的文件,Congestion Control in IP/TCP Internetworks (RFC896) 描述了他所谓的“小封包问题”-某个应用程式不断地送出小单位的资料,且某些常只占1字节大小。 因为TCP封包具有40字节的标头资讯(TCP与IPv4各占20字节),这导致了41字节大小的封包只有1字节的可用资讯,造成庞大的浪费。 这种状况常常发生于Telnet工作阶段-大部分的键盘操作会产生1字节的资料并马上送出。 更糟的是,在慢速的网络连线下,这类的封包会大量地在同一时点传输,造成壅塞碰撞(Congestion Collapse)。

纳格算法的工作方式是合并(coalescing)一定数量的输出资料后一次送出。特别的是,只要有已送出的封包尚未确认,传送者会持续缓冲封包,直到累积一定数量的资料才送出。

算法

if有新资料要传送

if讯窗大小>=MSSand可传送的资料>=MSS

立刻传送完整MSS大小的segment

else

if管线中有尚未确认的资料

在下一个确认(ACK)封包收到前,将资料排进缓冲区伫列

else

立即传送资料

MSS=最大segment大小

ThisalgorithminteractsbadlywithTCPdelayedacknowledgments,afeatureintroducedintoTCPatroughlythesametimeintheearly1980s,butbyadifferentgroup.Withbothalgorithmsenabled,applicationswhichdotwosuccessivewritestoaTCPconnection,followedbyaread,experienceaconstantdelayofupto500milliseconds,the"ACKdelay".Forthisreason,TCPimplementationsusuallyprovideapplicationswithaninterfacetodisabletheNaglealgorithm.ThisistypicallycalledtheTCP_NODELAYoption.ThefirstmajorapplicationtorunintothisproblemwastheXWindow系统.

Thetinygramproblemandsillywindowsyndromearesometimesconfused.Thetinygramproblemoccurswhenthewindowisalmostempty

随便看

 

百科全书收录4421916条中文百科知识,基本涵盖了大多数领域的百科知识,是一部内容开放、自由的电子版百科全书。

 

Copyright © 2004-2023 Cnenc.net All Rights Reserved
更新时间:2025/2/27 12:31:06