Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does setting TCP_NODELAY affect the behaviour of both ends of the socket?

I've always assumed that Nagle's algorithm affected the socket in both directions, and that setting TCP_NODELAY somehow informed the remote end also to switch off Nagle.

Is that right, or does setting TCP_NODELAY only affect the behaviour of the end that calls it?

like image 511
Roddy Avatar asked Nov 22 '11 12:11

Roddy


1 Answers

TCP_NODELAY affect sending TCP segments only on the host that sets this option on its socket. That is, the peer's sending algorithm is not affected.

like image 101
Maxim Egorushkin Avatar answered Nov 13 '22 18:11

Maxim Egorushkin