From e3c010f383e08203f5e38d81c1b2471bbad1814e Mon Sep 17 00:00:00 2001 From: openhands Date: Thu, 1 Oct 2026 17:11:04 +0200 Subject: [PATCH] fix(proxy): raise nginx worker rlimit above worker_connections nginx inherited systemd's soft LimitNOFILE of 1024, so every start logged "2048 worker_connections exceed open file resource limit: 1024" and the worker_connections value could not actually be reached. Set worker_rlimit_nofile to 65536. Bounded from above by a systemd drop-in at /etc/systemd/system/nginx.service.d/override.conf (LimitNOFILE=65536), since the master's hard limit caps what workers may request. --- deployment/proxy/nginx.conf | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/deployment/proxy/nginx.conf b/deployment/proxy/nginx.conf index 9a4094d2..980ccae0 100644 --- a/deployment/proxy/nginx.conf +++ b/deployment/proxy/nginx.conf @@ -12,6 +12,11 @@ user www-data; worker_processes auto; +# Raise the file-descriptor rlimit for the workers. Must stay <= the master's +# RLIMIT_NOFILE *hard* limit, otherwise nginx refuses to start with +# "setrlimit(RLIMIT_NOFILE) failed". Bounded from above by the systemd drop-in +# /etc/systemd/system/nginx.service.d/override.conf (LimitNOFILE=65536). +worker_rlimit_nofile 65536; pid /run/nginx.pid; error_log /var/log/nginx/error.log warn;