mirror of
https://github.com/nextcloud/all-in-one.git
synced 2026-05-21 02:40:09 +00:00
refine: improve sed pattern specificity and remove hardcoded timeout from docs
- Use \s*= in pm.process_idle_timeout sed pattern to match only setting lines, not comment-only lines that mention the setting name - Remove hardcoded '5 minutes' from docs; reference pm.process_idle_timeout by name so it stays accurate if the value changes Agent-Logs-Url: https://github.com/nextcloud/all-in-one/sessions/2fd7a6d1-bfdb-4f26-a8d0-cd54a7307999 Co-authored-by: szaimen <42591237+szaimen@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
46eb2dfc7d
commit
2bc3c4e7ec
@@ -257,7 +257,7 @@ RUN set -ex; \
|
||||
# a loaded host that spawn latency can push Apache past its FastCGI timeout and
|
||||
# produce a 502. 300 s (5 min) keeps a warm pool through normal sync-client
|
||||
# polling cycles while still reclaiming memory during genuinely idle periods.
|
||||
sed -i 's/^;*pm.process_idle_timeout.*/pm.process_idle_timeout = 300s/' /usr/local/etc/php-fpm.d/www.conf; \
|
||||
sed -i 's/^;*pm.process_idle_timeout\s*=.*/pm.process_idle_timeout = 300s/' /usr/local/etc/php-fpm.d/www.conf; \
|
||||
sed -i 's|access.log = /proc/self/fd/2|access.log = /proc/self/fd/1|' /usr/local/etc/php-fpm.d/docker.conf; \
|
||||
\
|
||||
echo "[ -n \"\$TERM\" ] && [ -f /root.motd ] && cat /root.motd" >> /root/.bashrc; \
|
||||
|
||||
@@ -1246,7 +1246,7 @@ A **502 Bad Gateway** response from your reverse proxy means the proxy successfu
|
||||
|
||||
1. **Reverse proxy read timeout too short** — The nginx default `proxy_read_timeout` is only 60 seconds. Long-running operations (large file uploads, remote storage scans, etc.) can exceed this limit, causing nginx to close the connection and show 502 (or 504) to the client. Make sure your reverse proxy timeout is set higher than AIO's `NEXTCLOUD_MAX_TIME` (default 3600 s). The sample configs in this document already set `proxy_read_timeout 3610s` for nginx and equivalent values for other proxies.
|
||||
|
||||
2. **PHP-FPM worker pool exhausted** — Each PHP request is served by a PHP-FPM worker. Workers are spawned on demand and terminated after 5 minutes of idle time. If a burst of concurrent requests arrives and no workers are available (e.g. all current workers are busy with long operations), Apache returns 502 to Caddy, which returns it to your proxy. Check worker usage with:
|
||||
2. **PHP-FPM worker pool exhausted** — Each PHP request is served by a PHP-FPM worker. Workers are spawned on demand and terminated after a configurable idle timeout (`pm.process_idle_timeout`). If a burst of concurrent requests arrives and no workers are available (e.g. all current workers are busy with long operations), Apache returns 502 to Caddy, which returns it to your proxy. Check worker usage with:
|
||||
```
|
||||
sudo docker exec nextcloud-aio-nextcloud php-fpm -t && \
|
||||
sudo docker exec nextcloud-aio-nextcloud ps aux | grep php-fpm | wc -l
|
||||
|
||||
Reference in New Issue
Block a user