Skip to content
Snippets Groups Projects
Commit 71edbc64 authored by Hans Persson's avatar Hans Persson
Browse files

Add networking::tcptuning:: classes.

Add classes for tcptuning. All the classes are taken from their
current versions on serenity (commit 11a627ce). All systems apart
from intserv use some subset of these classes, so include them in
this module to avoid unnecessary duplication.

Note: The tcptuning::bbr class currently is not used by any system
but the plan is for it to be soon (post-CentOS 7 upgrades) so include
that as well for future usage even though it looks like dead weight
right now.
parent e4e9505e
No related branches found
No related tags found
No related merge requests found
class networking::tcptuning::10g
{
sysctl {
# Increase TCP max buffer size settable using setsockopt().
# Bandwidth-in-bits-per-second * Round-trip-latency-in-seconds / 8 =
# TCP window size in bytes = 10000000000 * 60 / 8 = 75000000000
'net.core.rmem_max': value => '75000000';
'net.core.wmem_max': value => '75000000';
# Increase Linux autotuning TCP buffer limit.
'net.ipv4.tcp_rmem': value => '4096 87380 75000000';
'net.ipv4.tcp_wmem': value => '4096 87380 75000000';
# Increase the length of the processor input queue.
'net.core.netdev_max_backlog': value => '30000';
}
}
class networking::tcptuning::1g
{
sysctl {
# Increase TCP max buffer size settable using setsockopt().
# Bandwidth-in-bits-per-second * Round-trip-latency-in-seconds / 8 =
# TCP window size in bytes = 1000000000 * 60 / 8 = 7500000000
'net.core.rmem_max': value => '7500000';
'net.core.wmem_max': value => '7500000';
# Increase Linux autotuning TCP buffer limit.
'net.ipv4.tcp_rmem': value => '4096 87380 7500000';
'net.ipv4.tcp_wmem': value => '4096 87380 7500000';
# Increase the length of the processor input queue.
'net.core.netdev_max_backlog': value => '30000';
}
}
class networking::tcptuning::40g
{
sysctl {
# Increase TCP max buffer size settable using setsockopt().
# Bandwidth-in-bits-per-second * Round-trip-latency-in-seconds / 8 =
# TCP window size in bytes = 10000000000 * 60 / 8 = 75000000000
'net.core.rmem_max': value => '75000000';
'net.core.wmem_max': value => '75000000';
# Increase Linux autotuning TCP buffer limit.
'net.ipv4.tcp_rmem': value => '4096 87380 75000000';
'net.ipv4.tcp_wmem': value => '4096 87380 75000000';
# Increase the length of the processor input queue.
'net.core.netdev_max_backlog': value => '30000';
}
}
class networking::tcptuning::bbr
{
# Enable the Google "Bottleneck Bandwidth and RRT" TCP Congestion
# Control Algorithm (CCA).
sysctl {
# Default: fq_codel
'net.core.default_qdisc': value => 'fq';
# Default: reno cubic
'net.ipv4.tcp_congestion_control': value => 'bbr';
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment