Random connection failures and 5xx across many services on one node; `dmesg` shows "nf_conntrack: table full, dropping packet".
AdvancedTroubleshooting5xx errors
Answer
Likely causes → The node's connection tracking table is full. Every new connection (including DNS over UDP) is dropped. Triggers: lots of short-lived connections, a connection-leaking client, or a DDoS.
Diagnose →
cat /proc/sys/net/netfilter/nf_conntrack_count /proc/sys/net/netfilter/nf_conntrack_max
conntrack -L 2>/dev/null | awk '{print $1,$4}' | sort | uniq -c | sort -nr | head
Fix → Raise net.netfilter.nf_conntrack_max (kube-proxy's conntrack.maxPerCore on Kubernetes), and find the client creating connections without reuse.
Prevent → Alert on conntrack usage above 75%, use connection pooling, and consider NodeLocal DNSCache to cut UDP conntrack entries.
More on 5xx errors
Right after a release, 500s spike to 8% and logs show `java.lang.NullPointerException` in a new code path.BeginnerLong-running report exports fail with "504 Gateway Time-out" from the ALB at exactly 60 seconds.Beginnernginx logs "upstream prematurely closed connection while reading response header from upstream" and users get 502.IntermediateEvery deploy causes 10–20 seconds of 502s from the ALB, even with a rolling update.IntermediateA Node.js service behind an ALB returns a steady trickle of 502s under normal load, with no app errors at all.AdvancedThrough Istio, clients get "503 upstream connect error or disconnect/reset before headers. reset reason: connection failure".Intermediate