Stop your server from throttling throughput when the buffers run dry
Performance Tuning & Kernel Parameters (Sysctl)
Stop your server from throttling throughput when the buffers run dry
🧩 The Challenge
Dealing with high-throughput 10Gbps+ links where the throughput flatlines despite having plenty of CPU, even though you checked the NIC queues. It turns out the default TCP memory limits are just too conservative for modern high-speed backbones.
💡 The Fix
Bump up your TCP buffer limits so the kernel isn’t constantly hitting a wall and throttling your data flows. You’ll see a massive difference in stability for sustained large transfers.
sysctl -w net.core.rmem_max=16777216
sysctl -w net.core.wmem_max=16777216
sysctl -w net.ipv4.tcp_rmem='4096 87380 16777216'
sysctl -w net.ipv4.tcp_wmem='4096 65536 16777216'
⚙️ Why It Works
By increasing these values, you are telling the kernel it’s allowed to allocate more memory for window scaling and queueing packets, which prevents the stack from dropping segments when buffers overflow.
🚀 Pro-Tip: Don’t forget to make these changes permanent in /etc/sysctl.conf unless you want to redo this after every reboot.
Linux Tips & Tricks | © ngelinux.com | 11/15/2026
