From: Graham Leggett
GracefulShutdownTimeout
Listen
ListenBackLog
ListenCoresBucketsRatio
MaxConnectionsPerChild
MaxMemFree
MaxRequestWorkers
| Description: | Ratio between the number of CPU cores (online) and the number of +listeners' buckets |
|---|---|
| Syntax: | ListenCoresBucketsRatio ratio |
| Default: | ListenCoresBucketsRatio 0 (disabled) |
| Context: | server config |
| Status: | MPM |
| Module: | event, prefork, worker |
| Compatibility: | Available in Apache HTTP Server 2.4.13, with a kernel supporting
+the socket option SO_REUSEPORT and distributing new connections
+evenly accross listening processes' (or threads') sockets using it (eg. Linux
+3.9 and later, but not the current implementations of SO_REUSEPORT
+in *BSDs. |
A ratio between the number of (online) CPU cores and the
+ number of listeners' buckets can be used to make Apache HTTP Server create
+ num_cpu_cores / ratio listening buckets, each containing its
+ own Listen-ing socket(s) on the same port(s), and
+ then make each child handle a single bucket (with round-robin distribution
+ of the buckets at children creation time).
ListenCoresBucketsRatio can improve the
+ scalability when accepting new connections is/becomes the bottleneck.
+ On systems with a large number of CPU cores, enabling this feature has
+ been tested to show significant performances improvement and shorter
+ responses time.
There must be at least twice the number of CPU cores than the
+ configured ratio for this to be active. The recommended
+ ratio is 8, hence at least 16
+ cores should be available at runtime when this value is used.