mirror of https://github.com/OISF/suricata
affinity: bind worker memory to local NUMA node
Suricata already pins worker threads to NUMA-local CPUs via the existing cpu-affinity logic, but every heap allocation those workers make still goes through plain malloc and lands on whatever NUMA node the kernel picked for the first touch. When workers and their flow records end up on different nodes the cross-NUMA traffic shows up as packet loss on multi-socket boxes. Add a new threading.set-memory-affinity option, opt-in, that calls numa_set_localalloc() on each worker right after CPU pinning so all subsequent allocations on that thread prefer the local node. Requires libnuma at build time and is a no-op on single-node systems. Bug: #8141.pull/15352/head
parent
8968b1c5a1
commit
3c639c38d4
Loading…
Reference in New Issue