Skip to content

Commit fa8cf49

Browse files
skjnldsvbackportbot[bot]
authored andcommitted
fix(admin): adjust php fpm command and workers memory leak comment
Co-authored-by: John Molakvoæ <skjnldsv@users.noreply.github.com> Signed-off-by: John Molakvoæ <skjnldsv@users.noreply.github.com>
1 parent fc7b688 commit fa8cf49

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

admin_manual/installation/server_tuning.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ Key parameters
180180

181181
Measure the average RSS of a running pool::
182182

183-
ps --no-headers -o rss -C php-fpm8.3 | awk '{sum+=$1} END {print sum/NR/1024 " MB"}'
183+
ps --no-headers -o rss -C php-fpm | awk '{sum+=$1; count++} END {if (count>0) print sum/count/1024 " MB"; else print "No php-fpm processes found"}'
184184

185185
A typical Nextcloud worker uses **50–100 MB** (more if Imagick or LDAP is loaded).
186186
Leave headroom for the OS, web server, database, and cache. Setting ``pm.max_children``
@@ -252,7 +252,7 @@ Troubleshooting
252252
directory trees. Use the slow log to identify the bottleneck.
253253

254254
**Memory grows over time**
255-
Workers are leaking memory (Imagick and XML parsers are common sources).
255+
Memory leaks can occur in worker processes. Common culprits include libraries that manage external resources (like Imagick for image processing). Use the slow log and RSS monitoring to identify which requests cause growth.
256256
Set ``pm.max_requests = 500`` to recycle them before they grow too large.
257257

258258
**Slow first request after idle**

0 commit comments

Comments
 (0)