-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
where to set pm.max_children #275
Comments
Just mount your own php config file into the container like described here: Does this help? |
Sure, thanks! But it would be nice to have it configured by env variables like some of the other preferences, no?
Best,
Francis
… On 31 Jan 2025, at 11:59, ne20002 ***@***.***> wrote:
Just mount your own php config file into the container like described here:
https://serverfault.com/questions/884256/how-and-where-to-configure-pm-max-children-for-php-fpm-with-docker
Does this help?
—
Reply to this email directly, view it on GitHub <#275 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABT2F44CGJSYS6FAPV47D3L2NNJS7AVCNFSM6AAAAABVDTS5E6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMRWHEZTCMBRGA>.
You are receiving this because you authored the thread.
|
It's always difficult to decide what configuration values shall be available as env variables for a docker image. There are many. |
Fair enough. But the issue here is that Friendica is almost unusable with the default configs. pm.macx_children leads quickly to errors with the default values.
… On 31 Jan 2025, at 12:13, ne20002 ***@***.***> wrote:
It's always difficult to decide what configuration values shall be available as env variables for a docker image. There are many.
As you're the first asking for this I'd rather go with mounting your own config file approach.
—
Reply to this email directly, view it on GitHub <#275 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABT2F45L3YUDLTSSGLK5B7T2NNLENAVCNFSM6AAAAABVDTS5E6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMRWHE2TKOBTHA>.
You are receiving this because you authored the thread.
|
As said, it's the first time I hear this but I'm willing to take a deeper look on the issue. Which version of friendica and which docker image are you using? How many users do ou have on the system? @nupplaphil, @annando, @MrPetovan maybe you can help? Is pm.max_children ever been an issue? |
The last version, 2024.12-fpm.
I have around a dozen users, I think. But I notic4ed this since the start.
… On 31 Jan 2025, at 13:39, ne20002 ***@***.***> wrote:
As said, it's the first time I hear this but I'm willing to take a deeper look on the issue. Which version of friendica and which docker image are you using? How many users do ou have on the system?
@nupplaphil <https://github.com/nupplaphil>, @annando <https://github.com/annando>, @MrPetovan <https://github.com/MrPetovan> maybe you can help? Is pm.max_children ever been an issue?
—
Reply to this email directly, view it on GitHub <#275 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABT2F46B4SAXB6MRRPLJGEL2NNVHRAVCNFSM6AAAAABVDTS5E6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMMRXGE4DONJWG4>.
You are receiving this because you authored the thread.
|
I'm still using the Apache2 PHP module over here, so I'd be hard-pressed to give advice on php-fpm. 😕 |
@oculos, as these kind of warnings often don't point the problem and as you are the first to ask I don't want to put too much effort into adding this as an env variable. I also don't have the setup to test it. But a dozen users shouldn't give friendica any problems, not even on a raspberry pi. I suggest you try to fix this by mounting your own config file into the container and check if you can resolve the issue by modifying values. If this is successful we will hopefully get more information to decide how to handle this. Is this ok? |
I saw today that I got these with the default docker:
|
There is the Site / administration / workers pannel in the admin console webui where you can set It may be
|
This details of process handling in php are beyond my knowledge (tended to write paygrade ;) But looking at @m33m33 's answer about syncing pm.max_children and Number of parallel workers I'm not sure we can modifiy a php config file from the Friendica web app. |
Parallel workers are spawned using PHP CLI, nothing to do with PHP-FPM, so there's no reason to link them together. Also Friendica indeed can't change fpm's configuration. |
Does this also apply to fpm images ? |
It seems that pm.max_children and related settings are usually calculated based on the available memory and the average/max memory used per process. |
I have a 512Mb max memory per script execution on my Apache install, not sure if it's relevant. |
This is one source I found (others are similar). I think when we collect the info from different systems we may get a pretty good number to use. |
My concern is scalability. It would be nice to increase/decrease these things as one sees fit in case there’s need for that.
… On 27 Feb 2025, at 21:12, ne20002 ***@***.***> wrote:
ne20002
left a comment
(friendica/docker#275)
This is one source I found (others are similar). I think when we collect the info from different systems we may get a pretty good number to use.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you were mentioned.
<https://chrismoore.ca/2018/10/finding-the-correct-pm-max-children-settings-for-php-fpm/> <#275 (comment)> <https://github.com/notifications/unsubscribe-auth/ABT2F42RGAEGVHB2MU4ASD32R5WUFAVCNFSM6AAAAABVDTS5E6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMOBZGAYTGMBTGQ>
ne20002
left a comment
(friendica/docker#275)
<#275 (comment)>
This <https://chrismoore.ca/2018/10/finding-the-correct-pm-max-children-settings-for-php-fpm/> is one source I found (others are similar). I think when we collect the info from different systems we may get a pretty good number to use.
—
Reply to this email directly, view it on GitHub <#275 (comment)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/ABT2F42RGAEGVHB2MU4ASD32R5WUFAVCNFSM6AAAAABVDTS5E6VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDMOBZGAYTGMBTGQ>.
You are receiving this because you were mentioned.
|
We must find a good starting point at first. One good for most and hobby users. Friendica is running on a small machine with only 1GB RAM, e.g. Raspi or VPS. Configuration is a good thing. The easiest way is always to mount your own config file into the container. As those configuration require knowledge (or try and error or both) I assume people needing tweaking these values know how to do this and how to work with dockerized applications. Maxing these configuration values need info about the machine and can not easily be collected (e.g. memory on a machine running multiple applications with docker 'sharing' its memory). Let's see where we land with a new default. |
When searching on my site, friendica gets unresponsive. I see in the logs that it asks to raise the value of
pm.max_children
.However, on the docker image I can't find those settings.
Could you help me?
The text was updated successfully, but these errors were encountered: