Print this page
11554 Want TCP_CONGESTION socket option
Reviewed by: Yuri Pankov <yuri.pankov@nexenta.com>

Split Close
Expand all
Collapse all
          --- old/usr/src/man/man7p/tcp.7p
          +++ new/usr/src/man/man7p/tcp.7p
↓ open down ↓ 255 lines elided ↑ open up ↑
 256  256  The initial cwnd calculation can be overridden by the socket option
 257  257  .Dv TCP_INIT_CWND .
 258  258  An application can use this option to set the initial cwnd to a
 259  259  specified number of TCP segments.
 260  260  This applies to the cases when the connection
 261  261  first starts and restarts after an idle period.
 262  262  The process must have the
 263  263  .Dv PRIV_SYS_NET_CONFIG
 264  264  privilege if it wants to specify a number greater than that
 265  265  calculated by RFC 3390.
      266 +.Pp
      267 +The operating system also provides alternative algorithms that may be more
      268 +appropriate for your application, including the CUBIC congestion control
      269 +algorithm described in RFC 8312.
      270 +These can be configured system-wide using
      271 +.Xr ipadm 1M ,
      272 +or on a per-connection basis with the TCP-level socket option
      273 +.Dv TCP_CONGESTION ,
      274 +whose argument is the name of the algorithm to use
      275 +.Pq for example Dq cubic .
      276 +If the requested algorithm does not exist, then
      277 +.Fn setsockopt
      278 +will fail, and
      279 +.Va errno
      280 +will be set to
      281 +.Er ENOENT .
 266  282  .Ss "TCP Keep-Alive"
 267  283  Since TCP determines whether a remote peer is no longer reachable by timing out
 268  284  waiting for acknowledgements, a host that never sends any new data may never
 269  285  notice a peer that has gone away.
 270  286  While consumers can avoid this problem by sending their own periodic heartbeat
 271  287  messages (Transport Layer Security does this, for example),
 272  288  TCP describes an optional keep-alive mechanism in RFC 1122.
 273  289  Applications can enable it using the socket-level option
 274  290  .Dv SO_KEEPALIVE .
 275  291  When enabled, the first keep-alive probe is sent out after a TCP connection is
↓ open down ↓ 598 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX