diff --git a/ansible/roles/loadbalancer/defaults/main.yml b/ansible/roles/loadbalancer/defaults/main.yml index 7db023e017..bb38946a74 100644 --- a/ansible/roles/loadbalancer/defaults/main.yml +++ b/ansible/roles/loadbalancer/defaults/main.yml @@ -52,9 +52,7 @@ keepalived_traffic_mode: "multicast" # Extended global configuration, optimization options. haproxy_max_connections: 40000 haproxy_threads: 1 -# More than 1 process is deprecated by HAProxy, prefer haproxy_threads -haproxy_processes: 1 -haproxy_process_cpu_map: "no" +haproxy_thread_cpu_map: "no" # Matches the mariadb 10000 max connections limit haproxy_defaults_max_connections: 10000 diff --git a/ansible/roles/loadbalancer/templates/haproxy/haproxy_main.cfg.j2 b/ansible/roles/loadbalancer/templates/haproxy/haproxy_main.cfg.j2 index 40d571bf93..0e572333b9 100644 --- a/ansible/roles/loadbalancer/templates/haproxy/haproxy_main.cfg.j2 +++ b/ansible/roles/loadbalancer/templates/haproxy/haproxy_main.cfg.j2 @@ -6,14 +6,8 @@ global daemon log {{ syslog_server }}:{{ syslog_udp_port }} {{ syslog_haproxy_facility }} maxconn {{ haproxy_max_connections }} - nbproc {{ haproxy_processes }} nbthread {{ haproxy_threads }} - {% if (haproxy_processes | int > 1) and (haproxy_process_cpu_map | bool) %} - {% for cpu_idx in range(0, haproxy_processes) %} - cpu-map {{ cpu_idx + 1 }} {{ cpu_idx }} - {% endfor %} - {% endif %} - {% if (haproxy_threads | int > 1) and (haproxy_process_cpu_map | bool) %} + {% if (haproxy_threads | int > 1) and (haproxy_thread_cpu_map | bool) %} cpu-map auto:1/all 0-63 {% endif %} stats socket /var/lib/kolla/haproxy/haproxy.sock group kolla mode 660{% if haproxy_socket_level_admin | bool %} level admin{% endif %} diff --git a/releasenotes/notes/haproxy-drop-processes-f6951f7b995e0694.yaml b/releasenotes/notes/haproxy-drop-processes-f6951f7b995e0694.yaml new file mode 100644 index 0000000000..9b5269dde6 --- /dev/null +++ b/releasenotes/notes/haproxy-drop-processes-f6951f7b995e0694.yaml @@ -0,0 +1,7 @@ +--- +upgrade: + - | + Configuring HAProxy nbproc setting via ``haproxy_processes`` and + ``haproxy_process_cpu_map`` variables has been dropped since + threads are the recommended way to scale CPU performance since 1.8. + Please use ``haproxy_threads`` and ``haproxy_thread_cpu_map`` instead.