Skip to content
Snippets Groups Projects
Commit c5e7bdfb authored by rswindell's avatar rswindell
Browse files

Important update to the default TCP socket values defined in this file:

- no longer override the default send and receive socket buffers (limiting
  to 8Kbytes) - apparently modern TCP/IP stacks can use much larger buffers
  for sending large data more effeciently (quickly) over fast networks.
  Eliminating these 2 lines sped up the web server (e.g. wiki.synchro.net)
  page loads by a factor of 20+.
- enable TCP_NODELAY (disabling the Nagle algorithm) for *all* TCP sockets
  by default (not just telnet and rlogin servers).
  This helps performance of large data transfers a little bit too.

Big thanks to Deuce (!) for helping to debug and identify the cause of the
poor performance of the web server. I'm not sure why I/we were overriding
the default send/receive buffers but the old sockopts.cfg file introduced
in 2003 had 4Kbyte buffer sizes specified, and then when we switched to
sockopts.ini in 2005, the buffer sizes were increased to 8Kbytes. This might
have been the defaults for say, the Windows TCP/IP stack at the time, I
forget where I got those numbers from. Anyway, we shouldn't override them
without a good reason. And today, we definitely don't have a good reason
that I'm aware of. The default buffer sizes perform *much* better!
parent 3fc3d522
No related branches found
No related tags found
No related merge requests found
......@@ -26,12 +26,11 @@
; On some Unix platforms, additional TCP_* options are supported
; Global socket options set here, in root section
SNDBUF = 8192
RCVBUF = 8192
IPV6_V6ONLY = 1
; TCP-specific options set here
[tcp]
TCP_NODELAY = TRUE
KEEPALIVE = TRUE
; UDP-specific options set here
......@@ -39,4 +38,7 @@ KEEPALIVE = TRUE
; Server/protocol specific options set here
[telnet|rlogin]
TCP_NODELAY = TRUE
[http]
[ftp]
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment