Linux Network Stack Tuning: From Kernel to Application

Why Tune the Linux Network Stack The Linux kernel’s default network parameters are designed for general-purpose scenarios — conservative and safe. However, under high-concurrency web services, large-scale load balancers, CDN nodes, and similar workloads, these defaults become bottlenecks. Typical symptoms include: dmesg showing nf_conntrack: table full, dropping packet ss -s showing a large number of TIME-WAIT connections During load testing, CPU is not saturated but throughput plateaus NIC PPS (packets per second) is far below hardware capability Most of these issues stem from untuned kernel network parameters....

May 7, 2024 · 12 mins · 2493 words · XuBaojin