lighttpd/weighttp — pull request #5 by edsiper (2013-02-22 23:04:50+00:00)
Title: Add Linux TCP_FASTOPEN support through -f flag

Linux Kernels 3.6 and 3.7, introduces client and server support
for a new TCP featured called TCP_FASTOPEN. This feature reduces
the TCP handshake roundtrip improving performance for new
connections.

This patch implements this optional feature in weighttp through
the argument '-f'. If for some reason the system do not allow
a connection in this new mode, it will fail with the following
error message:

--
Error: the server do not support TCP_FASTOPEN or the feature
is disabled in the Kernel:

- Verify that your server is running at least Linux Kernel 3.7
- Verify that this machine is running at least Linux Kernel 3.6
- Check on both machines that TCP_FASTOPEN is enabled:

# cat /proc/sys/net/ipv4/tcp_fastopen

if the value is zero then enable it with:

# echo 1 > /proc/sys/net/ipv4/tcp_fastopen
--

Signed-off-by: Eduardo Silva