Repository navigation
Dify SSRF Proxy Causes High Memory Usage on ARM64 – Squid 6.13 Fails with RLIMIT_NOFILE: Operation not permitted #46142
Replies: 1 comment
|
This looks more like a file-descriptor limit or runtime restriction than an ARM64-specific failure. The same
Please share these read-only diagnostics, along with your Docker Engine version and host distribution/kernel: docker inspect docker-ssrf_proxy-1 --format \
'Image={{.Image}} Ulimits={{json .HostConfig.Ulimits}} Restarts={{.RestartCount}} State={{json .State}}'
docker stats --no-stream docker-ssrf_proxy-1
cat /proc/sys/fs/nr_open
cat /proc/sys/kernel/core_patternIf the container stays running long enough, also capture: docker exec docker-ssrf_proxy-1 sh -c \
'cat /proc/1/limits; grep -R max_filedescriptors /etc/squid; ls -lh /var/spool/squid'Those outputs would help a maintainer distinguish a limit mismatch from a host-policy denial, and determine whether the memory spike tracks crashes or a running Squid process. To reply, just mention @dosu. Docs are dead. Just use Dosu. |
Uh oh!
There was an error while loading. Please reload this page.
Self Checks
Content
Dify SSRF Proxy Container Consumes Excessive Memory and Squid Fails to Set RLIMIT_NOFILE on ARM64
1. Environment
2. Problem Description
After starting Dify using Docker Compose, the server's available memory drops dramatically.
Before starting Dify, the server had approximately 100 GiB of available memory. However, after startup, the available memory dropped to nearly 0 GiB.
After investigating the memory usage of individual Docker containers, I found that the
docker-ssrf_proxy-1container was consuming an unusually large amount of memory.I then checked the SSRF Proxy container logs and found repeated errors related to
setrlimitandRLIMIT_NOFILE.3. Relevant Logs
The following messages appear in the SSRF Proxy container logs:
The same error occurs repeatedly during subsequent startup attempts:
The logs also show repeated Squid initialization messages:
This suggests that Squid encounters startup failures and may be repeatedly restarted.
4. What I Have Observed
docker-ssrf_proxy-1container is responsible for the abnormal memory consumption.setrlimit: RLIMIT_NOFILE: Operation not permittedduring initialization.I have not yet confirmed whether the repeated Squid startup failures are the direct cause of the excessive memory consumption.
5. Questions for the Community
I would appreciate any suggestions on the following issues:
RLIMIT_NOFILEinside the SSRF Proxy container on an ARM64 Linux system?ulimits.nofilefor the SSRF Proxy service in Dify 1.10.1?6. Expected Behavior
The SSRF Proxy container should start and run normally without repeatedly reporting
RLIMIT_NOFILEerrors or consuming excessive amounts of memory.I would appreciate guidance on the root cause and a recommended fix that does not compromise the SSRF Proxy's security functionality.
Thank you for your help!
All reactions