Ads 468x60px

12 de septiembre de 2016

Nagle's Algorithm

Nagle's algorithm is another feature to improve the performance of TCP/IP networks. There are many protocols, standards and technologies we should know, as network engineers, to understand the behaviour of our networks and thus improving the efficiency of our services like retransmitting only lost segments with SACK, be careful with hot potato and cold potato routing, implements Long Fat Networks (LFNS) in slow links or taking advantage of Multipath TCP. This is only some of the protocols, standards and technologies we should take into account to not going crazy when the behaviour and performance of our networks is not like it have to be.

Nagle's algorithm (RFC 896) was published in 1984 by John Nagle and it remains a standard feature of TCP today. It was designed to improve the efficiency of networks, using more bandwidth as possible at the expense of adding delays. It wants to reduce network congestion caused by “small packet problems” with TCP applications because there are applications and services that they send small packets, for instance 1 byte of useful data, over the network which is inefficient due to the fact that for sending only one byte we need to send from 20 to 60 bytes of headers as well. Therefore, many small packets have to be sent if we want to send only one byte of useful data. How it works with the Nagle's algorithm? Data are buffered and when there are enough information to transmit, it is sent it.

Nagle and non-Nagle comparative

Pros and Cons of the Nagle's algorithm? We can take advantage of transmiting the same amount of information with less packets and less overhead, as a result, we increase bandwidth efficiency which is useful in slow links with high latency. However, Nagle's algorithm is not useful in realtime and high interactive applications like chats or videoconferences where we should disable Nagle's algorithm or use the UDP protocol.

67 bytes to send 1 byte of useful data
To sum up, this is another standard which is useful to improve network efficiency in high demanding and business networks but we should know when it is recommended to be enabled and disabled because it can improve our network but also deteriorate it if we don't analyse properly the services, data and behaviour of our network. Anyway, if we need this feature we should look for this RFC when we are going to implement a new service or install a new appliance. For instance, F5 load balancer supports the Nagle's Algorithm in their TCP profiles.

Nagles Algorithm in F5 Profile

Regards my friend and remember, drop a line with the first thing you're thinking.

0 comentarios :

Publicar un comentario

Related Posts Plugin for WordPress, Blogger...

Entradas populares