Updating our TCP and socket sysctl values...

Navdeep Parhar nparhar at gmail.com
Sat Mar 19 23:45:35 UTC 2011


On Fri, Mar 18, 2011 at 11:37 PM, George Neville-Neil
<gnn at neville-neil.com> wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Howdy,
>
> I believe it's time for us to upgrade our sysctl values for TCP sockets so that
> they are more in line with the modern world.  At the moment we have these limits on
> our buffering:
>
> kern.ipc.maxsockbuf: 262144
> net.inet.tcp.recvbuf_max: 262144
> net.inet.tcp.sendbuf_max: 262144
>
> I believe it's time to up these values to something that's in line with higher speed
> local networks, such as 10G.  Perhaps it's time to move these to 2MB instead of 256K.
>
> Thoughts?

256KB seems adequate for 10G (as long as the consumer can keep
draining the socket rcv buffer fast enough).  If you consider 2 x
bandwidth delay product to be a reasonable socket buffer size then
256K allows for 10G networks with ~100ms delays.  Normally the delay
is _way_ less than this for 10G and even 256K may be an overkill (but
this is ok, the kernel has tcp_do_autorcvbuf on by default)

While we're here discussing defaults, what about nmbclusters and
nmbjumboXX?  Now those haven't kept up with modern machines (imho).

Regards,
Navdeep


More information about the freebsd-arch mailing list