|
2 | 2 | <html lang="en"> |
3 | 3 | <head> |
4 | 4 | <meta charset="utf-8" /> |
5 | | - <title>HAProxy version 3.2-dev7-23 - Configuration Manual</title> |
| 5 | + <title>HAProxy version 3.2-dev7-83 - Configuration Manual</title> |
6 | 6 | <link href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/3.3.7/css/bootstrap.min.css" rel="stylesheet" /> |
7 | 7 | <link href="https://raw.githubusercontent.com/thomaspark/bootswatch/v3.3.7/cerulean/bootstrap.min.css" rel="stylesheet" /> |
8 | 8 | <link href="../css/page.css?0.4.2-15" rel="stylesheet" /> |
|
1630 | 1630 |
|
1631 | 1631 | <a class="list-group-item" href="#cpu-map">cpu-map</a> |
1632 | 1632 |
|
| 1633 | + <a class="list-group-item" href="#cpu-policy">cpu-policy</a> |
| 1634 | + |
| 1635 | + <a class="list-group-item" href="#cpu-set">cpu-set</a> |
| 1636 | + |
1633 | 1637 | <a class="list-group-item" href="#cpu_calls">cpu_calls</a> |
1634 | 1638 |
|
1635 | 1639 | <a class="list-group-item" href="#cpu_ns_avg">cpu_ns_avg</a> |
|
4470 | 4474 | You can use <strong>left</strong> and <strong>right</strong> arrow keys to navigate between chapters.<br> |
4471 | 4475 | </p> |
4472 | 4476 | <p class="text-right"> |
4473 | | - <small>Converted with <a href="https://github.com/cbonte/haproxy-dconv">haproxy-dconv</a> v<b>0.4.2-15</b> on <b>2025/03/13</b></small> |
| 4477 | + <small>Converted with <a href="https://github.com/cbonte/haproxy-dconv">haproxy-dconv</a> v<b>0.4.2-15</b> on <b>2025/03/14</b></small> |
4474 | 4478 | </p> |
4475 | 4479 | </div> |
4476 | 4480 | <!-- /.sidebar --> |
|
4481 | 4485 | <div class="text-center"> |
4482 | 4486 | <h1><a href="http://www.haproxy.org/" title="HAProxy"><img src="../img/HAProxyCommunityEdition_60px.png?0.4.2-15" /></a></h1> |
4483 | 4487 | <h2>Configuration Manual</h2> |
4484 | | - <p><strong>version 3.2-dev7-23</strong></p> |
| 4488 | + <p><strong>version 3.2-dev7-83</strong></p> |
4485 | 4489 | <p> |
4486 | 4490 | 2025/03/07<br> |
4487 | 4491 |
|
@@ -7086,6 +7090,8 @@ <h2 id="chapter-2.9" data-target="2.9"><small><a class="small" href="#2.9">2.9.< |
7086 | 7090 | - <a href="#chroot">chroot</a> |
7087 | 7091 | - <a href="#cluster-secret">cluster-secret</a> |
7088 | 7092 | - <a href="#cpu-map">cpu-map</a> |
| 7093 | + - <a href="#cpu-policy">cpu-policy</a> |
| 7094 | + - <a href="#cpu-set">cpu-set</a> |
7089 | 7095 | - <a href="#crt-base">crt-base</a> |
7090 | 7096 | - <a href="#daemon">daemon</a> |
7091 | 7097 | - <a href="#default-path">default-path</a> |
@@ -7480,7 +7486,99 @@ <h2 id="chapter-3.1" data-target="3.1"><small><a class="small" href="#3.1">3.1.< |
7480 | 7486 | cpu-map 3/1-40 40-79,120-159 <span class="comment"># node1, siblings 0 & 1</span> |
7481 | 7487 | cpu-map 4/1-40 40-79,120-159 |
7482 | 7488 | </code></pre> |
7483 | | -</div><a class="anchor" name="crt-base"></a><a class="anchor" name="3-crt-base"></a><a class="anchor" name="3.1-crt-base"></a><a class="anchor" name="crt-base (Global parameters)"></a><a class="anchor" name="crt-base (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="crt-base"></a><a href="#3.1-crt-base">crt-base</a></b> <span style="color: #080"><dir></span></div><pre class="text">Assigns a default directory to fetch SSL certificates from when a relative |
| 7489 | +</div><a class="anchor" name="cpu-policy"></a><a class="anchor" name="3-cpu-policy"></a><a class="anchor" name="3.1-cpu-policy"></a><a class="anchor" name="cpu-policy (Global parameters)"></a><a class="anchor" name="cpu-policy (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="cpu-policy"></a><a href="#3.1-cpu-policy">cpu-policy</a></b> <span style="color: #080"><policy></span></div><pre class="text">Selects the CPU allocation policy to be used. |
| 7490 | + |
| 7491 | +On multi-CPU systems, there can be plenty of reasons for not using all |
| 7492 | +available CPU cores, and/or for grouping them into different thread groups, |
| 7493 | +for performance, latency, cost, or system-wide resource management. The |
| 7494 | +"<a href="#cpu-set">cpu-set</a>" directive already allows to evict a number of them, but once done, |
| 7495 | +it is necessary to decide how to assign the remaining ones to threads and |
| 7496 | +thread groups. |
| 7497 | + |
| 7498 | +This mapping is normally performed using the "<a href="#cpu-map">cpu-map</a>" directive, though it |
| 7499 | +can be particularly difficult to maintain on heterogenous systems. |
| 7500 | + |
| 7501 | +The "<a href="#cpu-policy">cpu-policy</a>" directive chooses between a small number of allocation |
| 7502 | +policies which one to use instead, when "<a href="#cpu-map">cpu-map</a>" is not used. The following |
| 7503 | +policies are currently supported: |
| 7504 | + |
| 7505 | + - none no particular post-selection is performed. All enabled |
| 7506 | + CPUs will be usable, and if the number of threads is |
| 7507 | + not set, it will be set to the number of available CPUs |
| 7508 | + but no more than 32 for 32-bit systems or 64 for 64-bit |
| 7509 | + systems, per thread-group. The number of thread-groups, |
| 7510 | + if not set, will be set to 1. |
| 7511 | + |
| 7512 | + - efficiency exactly like group-by-cluster below, except that CPU |
| 7513 | + clusters whose performance is more than twice that of |
| 7514 | + the next less performant one are evicted. These are |
| 7515 | + typically "big" or "performance" cores. This means that |
| 7516 | + if more than one type of CPU cores are detected, only |
| 7517 | + the efficient one will be used. This can make sense for |
| 7518 | + use with moderate loads when the most powerful cores |
| 7519 | + need to be available to the application or a security |
| 7520 | + component. Some modern CPUs have a large number of such |
| 7521 | + efficient CPU cores which can collectively deliver a |
| 7522 | + decent level of performance while using less power. |
| 7523 | + |
| 7524 | + - first-usable-node if the CPUs were not previously restricted at boot (for |
| 7525 | + example using the "taskset" utility), and if the |
| 7526 | + "<a href="#nbthread">nbthread</a>" directive was not set, then the first NUMA |
| 7527 | + node with enabled CPUs will be used, and this number of |
| 7528 | + CPUs will be used as the number of threads. A single |
| 7529 | + thread group will be enabled with all of them, within |
| 7530 | + the limit of 32 or 64 depending on the system. This is |
| 7531 | + the default policy. |
| 7532 | + |
| 7533 | + - group-by-cluster if neither "<a href="#nbthread">nbthread</a>" not "nbtgroups" were set, then |
| 7534 | + one thread group is created for each CPU cluster with |
| 7535 | + available CPUs, each with as many threads as CPUs. All |
| 7536 | + threads of a group are bound to all CPUs of the cluster |
| 7537 | + so that intra-group communications remain local to the |
| 7538 | + cluster without enforcing too strong a binding. The |
| 7539 | + per-group thread limits and thread-group limits are |
| 7540 | + respected. This is recommended on multi-socket and NUMA |
| 7541 | + systems, as well as CPUs with bad inter-CCX latencies. |
| 7542 | + |
| 7543 | + - performance exactly like group-by-cluster above, except that CPU |
| 7544 | + clusters whose performance is less than half of the |
| 7545 | + next more performant one are evicted. These are |
| 7546 | + typically "little" or "efficient" cores, whose addition |
| 7547 | + generally doesn't bring significant gains and can |
| 7548 | + easily be counter-productive (e.g. TLS handshakes). |
| 7549 | + Often, keeping such cores for other tasks such as |
| 7550 | + network handling is much more effective. On development |
| 7551 | + systems, these can also be used to run auxiliary tools |
| 7552 | + such as load generators and monitoring tools. |
| 7553 | + |
| 7554 | + - resource this is like group-by-cluster above, except that only |
| 7555 | + the smallest and most efficient CPU cluster will be |
| 7556 | + used, while all other ones will be ignored. This can be |
| 7557 | + used to limit the resource usage to the strict minimum |
| 7558 | + that still delivers decent performance, for example to |
| 7559 | + try to further reduce power consumption or minimize the |
| 7560 | + number of cores needed on some rented systems for a |
| 7561 | + sidecar setup, in order to scale the system down more |
| 7562 | + easily. Note that if a single cluster is present, it |
| 7563 | + will still be fully used. |
| 7564 | +</pre><div class="page-header"><b>See also:</b> "<a href="#cpu-map">cpu-map</a>", "<a href="#cpu-set">cpu-set</a>", "<a href="#nbthread">nbthread</a>"</div> |
| 7565 | +<a class="anchor" name="cpu-set"></a><a class="anchor" name="3-cpu-set"></a><a class="anchor" name="3.1-cpu-set"></a><a class="anchor" name="cpu-set (Global parameters)"></a><a class="anchor" name="cpu-set (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="cpu-set"></a><a href="#3.1-cpu-set">cpu-set</a></b> <span style="color: #080"><directive></span>...</div><pre class="text">Allows to symbolically describe what sets of CPUs to run on. The directive |
| 7566 | +supports the following keyword: |
| 7567 | + - reset this undoes any previous limitation that could have |
| 7568 | + been inherited by a service manager or a "taskset" |
| 7569 | + command for example. |
| 7570 | + - drop-cpu <set> do not bind to CPUs in this set |
| 7571 | + - only-cpu <set> do not bind to CPUs not in this set |
| 7572 | + - drop-node <set> do not bind to CPUs belonging to this NUMA node |
| 7573 | + - only-node <set> do not bind to CPUs not belonging to this NUMA node |
| 7574 | + - drop-cluster <set> do not bind to CPUs on this hardware cluster number |
| 7575 | + - only-cluster <set> do not bind to CPUs on other hardware cluster number |
| 7576 | + - drop-core <set> do not bind to CPUs on this hardware core number |
| 7577 | + - only-core <set> do not bind to CPUs on other hardware core number |
| 7578 | + - drop-thread <set> do not bind to CPUs on this hardware thread number |
| 7579 | + - only-thread <set> do not bind to CPUs on other hardware thread number |
| 7580 | +</pre><div class="page-header"><b>See also:</b> "<a href="#cpu-policy">cpu-policy</a>"</div> |
| 7581 | +<a class="anchor" name="crt-base"></a><a class="anchor" name="3-crt-base"></a><a class="anchor" name="3.1-crt-base"></a><a class="anchor" name="crt-base (Global parameters)"></a><a class="anchor" name="crt-base (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="crt-base"></a><a href="#3.1-crt-base">crt-base</a></b> <span style="color: #080"><dir></span></div><pre class="text">Assigns a default directory to fetch SSL certificates from when a relative |
7484 | 7582 | path is used with "crtfile" or "<span class="dropdown"><a class="dropdown-toggle" data-toggle="dropdown" href="#">crt<span class="caret"></span></a><ul class="dropdown-menu"><li class="dropdown-header">This keyword is available in sections :</li><li><a href="#crt%20%28Load%20options%29">Load options</a></li><li><a href="#crt%20%28Alphabetically%20sorted%20keywords%20reference%29">Alphabetically sorted keywords reference</a></li><li><a href="#crt%20%28Bind%20options%29">Bind options</a></li><li><a href="#crt%20%28Server%20and%20default-server%20options%29">Server and default-server options</a></li></ul></span>" directives. Absolute locations specified |
7485 | 7583 | prevail and ignore "<span class="dropdown"><a class="dropdown-toggle" data-toggle="dropdown" href="#">crt-base<span class="caret"></span></a><ul class="dropdown-menu"><li class="dropdown-header">This keyword is available in sections :</li><li><a href="#crt-base%20%28Process%20management%20and%20security%29">Process management and security</a></li><li><a href="#crt-base%20%28Certificate%20Storage%29">Certificate Storage</a></li></ul></span>". |
7486 | 7584 | </pre><a class="anchor" name="daemon"></a><a class="anchor" name="3-daemon"></a><a class="anchor" name="3.1-daemon"></a><a class="anchor" name="daemon (Global parameters)"></a><a class="anchor" name="daemon (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="daemon"></a><a href="#3.1-daemon">daemon</a></b></div><pre class="text">Makes the process fork into background. This is the recommended mode of |
@@ -7950,16 +8048,18 @@ <h2 id="chapter-3.1" data-target="3.1"><small><a class="small" href="#3.1">3.1.< |
7950 | 8048 | </pre><a class="anchor" name="no-quic"></a><a class="anchor" name="3-no-quic"></a><a class="anchor" name="3.1-no-quic"></a><a class="anchor" name="no-quic (Global parameters)"></a><a class="anchor" name="no-quic (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="no-quic"></a><a href="#3.1-no-quic">no-quic</a></b></div><pre class="text">Disable QUIC transport protocol. All the QUIC listeners will still be created. |
7951 | 8049 | But they will not bind their addresses. Hence, no QUIC traffic will be |
7952 | 8050 | processed by haproxy. See also "<a href="#quic_enabled">quic_enabled</a>" sample fetch. |
7953 | | -</pre><a class="anchor" name="numa-cpu-mapping"></a><a class="anchor" name="3-numa-cpu-mapping"></a><a class="anchor" name="3.1-numa-cpu-mapping"></a><a class="anchor" name="numa-cpu-mapping (Global parameters)"></a><a class="anchor" name="numa-cpu-mapping (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="numa-cpu-mapping"></a><a href="#3.1-numa-cpu-mapping">numa-cpu-mapping</a></b></div><pre class="text">If running on a NUMA-aware platform, HAProxy inspects on startup the CPU |
| 8051 | +</pre><a class="anchor" name="numa-cpu-mapping"></a><a class="anchor" name="3-numa-cpu-mapping"></a><a class="anchor" name="3.1-numa-cpu-mapping"></a><a class="anchor" name="numa-cpu-mapping (Global parameters)"></a><a class="anchor" name="numa-cpu-mapping (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="numa-cpu-mapping"></a><a href="#3.1-numa-cpu-mapping">numa-cpu-mapping</a></b></div><pre class="text">When running on a NUMA-aware platform with the cpu-policy is set to |
| 8052 | +"first-usable-node" (the default one), HAProxy inspects on startup the CPU |
7954 | 8053 | topology of the machine. If a multi-socket machine is detected, the affinity |
7955 | 8054 | is automatically calculated to run on the CPUs of a single node. This is done |
7956 | 8055 | in order to not suffer from the performance penalties caused by the |
7957 | 8056 | inter-socket bus latency. However, if the applied binding is non optimal on a |
7958 | 8057 | particular architecture, it can be disabled with the statement 'no |
7959 | 8058 | numa-cpu-mapping'. This automatic binding is also not applied if a nbthread |
7960 | | -statement is present in the configuration, or the affinity of the process is |
| 8059 | +statement is present in the configuration, if the affinity of the process is |
7961 | 8060 | already specified, for example via the 'cpu-map' directive or the taskset |
7962 | | -utility. |
| 8061 | +utility, or if the cpu-policy is set to any other value. See also "<a href="#cpu-map">cpu-map</a>", |
| 8062 | +"<a href="#cpu-policy">cpu-policy</a>", "<a href="#cpu-set">cpu-set</a>". |
7963 | 8063 | </pre><a class="anchor" name="ocsp-update.disable"></a><a class="anchor" name="3-ocsp-update.disable"></a><a class="anchor" name="3.1-ocsp-update.disable"></a><a class="anchor" name="ocsp-update.disable (Global parameters)"></a><a class="anchor" name="ocsp-update.disable (Process management and security)"></a><div class="keyword"><b><a class="anchor" name="ocsp-update.disable"></a><a href="#3.1-ocsp-update.disable">ocsp-update.disable</a></b> <span style="color: #008">[ on | off ]</span></div><pre class="text">Disable completely the ocsp-update in HAProxy. Any ocsp-update configuration |
7964 | 8064 | will be ignored. Default is "off". |
7965 | 8065 | See option "<a href="#ocsp-update">ocsp-update</a>" for more information about the auto update |
@@ -31993,7 +32093,7 @@ <h2 id="chapter-11.3" data-target="11.3"><small><a class="small" href="#11.3">11 |
31993 | 32093 | <br> |
31994 | 32094 | <hr> |
31995 | 32095 | <div class="text-right"> |
31996 | | - HAProxy 3.2-dev7-23 – Configuration Manual<br> |
| 32096 | + HAProxy 3.2-dev7-83 – Configuration Manual<br> |
31997 | 32097 | <small>, 2025/03/07</small> |
31998 | 32098 | </div> |
31999 | 32099 | </div> |
|
0 commit comments