OpenBSD számára megvalósításra került egy beállítás, amely engedélyezi a TCP_NODELAY módot az egész rendszeren

Job Snijders, a prominent OpenBSD developer, head of one of the committees in IETF (Internet Engineering Task Force), author of 11 RFCs related to routing and RPKI, and creator of IRRd (Internet Routing Registry Daemon), has published a set of patches for OpenBSD that add a new sysctl parameter "net.inet.tcp.nodelay" to disable Nagle's algorithm system-wide. This parameter relieves application developers from having to set the TCP_NODELAY flag for individual sockets.

Nagle's algorithm is used to aggregate small messages to reduce traffic. The algorithm delays the sending of new TCP segments until acknowledgment of previously sent data is received or a timeout occurs. For example, without aggregation, sending 1 byte results in an additional 40 bytes being sent with TCP and IP packet headers, while with Nagle's algorithm, messages sent before receiving acknowledgment from the remote side are accumulated and sent in one packet. Due to the optimization of "delayed ACK", which delays the sending of ACK packets, the signal through acknowledgment packets does not work in practice, and sending accumulated messages occurs upon timeout.

Snijders believes that in modern times, the Nagle algorithm, designed during an era when multiple users competed for a bandwidth of 1200 baud, is outdated and in high-speed networks does more harm than good. Recently, a similar position was expressed by Marc Brooker from Amazon Web Services (AWS). Arguments for disabling the Nagle algorithm by default can be found in an article published a few days ago.

To disable Nagle's algorithm, the TCP_NODELAY option can be set for individual network sockets. The TCP_NODELAY mode has long been set in many OpenBSD applications, including openssh, httpd, iscsid, relayd, bgpd, and unwind, and, according to Snijders, the time has come to allow its activation for all TCP sockets at the system level. Snijders also suggests discussing the adoption of TCP_NODELAY by default and converting Nagle's algorithm into a separate optional feature.

Forrás: opennet.ru

Megbízható hosting vásárlása weboldalak számára, DDoS védelemmel, VPS VDS szerverek. 🔥 Megbízható webtárhely vásárlása DDoS védelemmel, VPS VDS szerverek | ProHoster