如何启用复合 TCP (CTCP)?

Hal*_*lta 5 networking 12.10

我想在 Ubuntu 中使用复合 TCP

维基百科页面说:

除了 Windows,CTCP 还被移植到 Linux [...] 自内核版本 2.6.17 以来,由于内核 API 更改,该模块不兼容并且无法编译。

是否有较新的实现可以正常工作?

ger*_*ijk 5

Microsoft 的复合 TCP 只是拥塞算法协议的一种实现。在 Linux 中,正如您已经发现的那样,这已被丢弃,并且似乎TCP Illinois是直接继承者,但不再使用了。

从 2.6.22 开始为实现 Illinois 做了一些工作:LWN 文章:TCP Illinois 初步版本。它似乎在当前版本中仍然可用:net/ipv4/tcp_illinois.c在 linux-stable tree 中

TCP New Reno,另一种基于RFC3782 的替代方案似乎是 Linux 中最常用的,并且完全集成在内核中。另请参阅联机帮助页tcp(7)

  tcp_available_congestion_control (String; read-only; since Linux 2.4.20)
          Show  a list of the congestion-control algorithms that are registered.  This
          list is a limiting set for the list in tcp_allowed_congestion_control.  More
          congestion-control algorithms may be available as modules, but not loaded.
Run Code Online (Sandbox Code Playgroud)

检查系统上可用的那些:

cat /proc/sys/net/ipv4/tcp_available_congestion_control
Run Code Online (Sandbox Code Playgroud)

并活跃:

cat /proc/sys/net/ipv4/tcp_congestion_control
Run Code Online (Sandbox Code Playgroud)

通过写入来更改活动的(示例reno):

echo reno | sudo tee /proc/sys/net/ipv4/tcp_congestion_control
Run Code Online (Sandbox Code Playgroud)

底线:您可能已经通过使用最新的 Linux 内核使用了非常现代且非常高效的 TCP 拥塞算法协议。