Skip to content

Commit 4d2635d

Browse files
committed
Cap number of Pulp workers
Running Pulp with a number of workers based on CPUs can cause errors such as PostgreSQL connection limits on hosts with many cores: psycopg.OperationalError: connection failed: FATAL: remaining connection slots are reserved for non-replication superuser connections Cap workers to 32 until large scale testing can identify a more suitable limit.
1 parent 57b6710 commit 4d2635d

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

etc/kayobe/seed.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -112,8 +112,8 @@ seed_pulp_container:
112112
# s6-overlay-suexec starts as pid 1
113113
init: false
114114
env:
115-
PULP_CONTENT_WORKERS: "{{ ansible_facts.processor_vcpus * 2 + 1 }}"
116-
PULP_API_WORKERS: "{{ ansible_facts.processor_vcpus * 2 + 1 }}"
115+
PULP_CONTENT_WORKERS: "{{ [ansible_facts.processor_vcpus * 2 + 1, 32] | min }}"
116+
PULP_API_WORKERS: "{{ [ansible_facts.processor_vcpus * 2 + 1, 32] | min }}"
117117
PULP_HTTPS: "{{ 'true' if pulp_enable_tls | bool else 'false' }}"
118118
volumes:
119119
- /opt/kayobe/containers/pulp:/etc/pulp
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
fixes:
2+
- |
3+
Caps the number of Pulp API and content workers to 32 each to avoid errors
4+
on hosts with many CPUs.

0 commit comments

Comments
 (0)