summaryrefslogtreecommitdiff
path: root/man
diff options
context:
space:
mode:
authorSusant Sahani <susant@redhat.com>2014-08-14 23:06:12 +0530
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2014-08-14 19:55:44 -0400
commitcc567c9beace114554f7e7f50c3a5181cc44a07d (patch)
tree749ee36446a80a0ad710c73f7677c3719fbbb277 /man
parent209e9dcd7b2f23b68ff93bf20fad025bc03219ac (diff)
socket: Add support for TCP defer accept
TCP_DEFER_ACCEPT Allow a listener to be awakened only when data arrives on the socket. If TCP_DEFER_ACCEPT set on a server-side listening socket, the TCP/IP stack will not to wait for the final ACK packet and not to initiate the process until the first packet of real data has arrived. After sending the SYN/ACK, the server will then wait for a data packet from a client. Now, only three packets will be sent over the network, and the connection establishment delay will be significantly reduced.
Diffstat (limited to 'man')
-rw-r--r--man/systemd.socket.xml41
1 files changed, 41 insertions, 0 deletions
diff --git a/man/systemd.socket.xml b/man/systemd.socket.xml
index 5efb398b09..4483905832 100644
--- a/man/systemd.socket.xml
+++ b/man/systemd.socket.xml
@@ -546,6 +546,47 @@
</varlistentry>
<varlistentry>
+ <term><varname>DeferAccept=</varname></term>
+
+ <listitem><para>Takes time (in
+ seconds) as argument. If set, the
+ listening process will be awakened
+ only when data arrives on the socket,
+ and not immediately when connection is
+ established. When this option is set,
+ the
+ <constant>TCP_DEFER_ACCEPT</constant>
+ socket option will be used (see
+ <citerefentry><refentrytitle>tcp</refentrytitle><manvolnum>7</manvolnum></citerefentry>),
+ and the kernel will ignore initial ACK
+ packets without any data. The argument
+ specifies the approximate amount of
+ time the kernel should wait for
+ incoming data before falling back to
+ the normal behaviour of honouring
+ empty ACK packets. This option is
+ beneficial for protocols where the
+ client sends the data first (e.g.
+ HTTP, in contrast to SMTP), because
+ the server process will not be woken
+ up unnecessarily before it can take
+ any action.
+ </para>
+
+ <para>If the client also uses the
+ <constant>TCP_DEFER_ACCEPT</constant>
+ option, the latency of the initial
+ connection may be reduced, because the
+ kernel will send data in the final
+ packet establishing the connection
+ (the third packet in the "three-way
+ handshake").</para>
+
+ <para>Disabled by default.</para>
+ </listitem>
+ </varlistentry>
+
+ <varlistentry>
<term><varname>ReceiveBuffer=</varname></term>
<term><varname>SendBuffer=</varname></term>
<listitem><para>Takes an integer