System information
Tuning the Network 187
Tuning the Network
16
The network subsystem is rather complex and its tuning highly depends on the system
use scenario and also on external factors such as software clients or hardware compo-
nents (switches, routers, or gateways) in your network. The Linux kernel aims more at
reliability and low latency than low overhead and high throughput. Other settings can
mean less security, but better performance.
16.1 Configurable Kernel Socket
Buffers
Networking is largely based on the TCP/IP protocol and a socket interface for com-
munication; for more information about TCP/IP, see Chapter21, Basic Networking
(↑Administration Guide). The Linux kernel handles data it receives or sends via the
socket interface in socket buffers. These kernel socket buffers are tunable.
IMPORTANT: TCP Autotuning
Since kernel version 2.6.17 full autotuning with 4 MB maximum buffer size
exists. This means that manual tuning in most cases will not improve net-
working performance considerably. It is often the best not to touch the follow-
ing variables, or, at least, to check the outcome of tuning efforts carefully.
If you update from an older kernel, it is recommended to remove manual TCP
tunings in favor of the autotuning feature.