PHP Memory Limit Not Changing

Operating system Debian Linux 10
Webmin version 1.973
Usermin version 1.823
Virtualmin version 6.16
Authentic theme version 19.73
PHP version 7.4.21

Hello,

We are running a Nexcloud installation ( version 21.0.2) and it is indicating: “The PHP memory limit is below the recommended value of 512MB”.

However if I go to Virtualmin → Services → PHP-FPM Configuration as per this post:

I can see that in fact memory_limit = 512M (/etc/php/7.4/cgi/php.ini).

Why is the set memory_limit not being seen by Nextcloud?

Thanks

FPM can have per-domain memory limits which may override the system default. Check in /etc/php-fpm/domain-id.conf (I think Virtualmin has a UI for this, so you don’t have to know the domain ID, but I dunno where it is). If you see php_admin_value[memory_limit] that may be where it’s coming from.

I’m not sure if there are other places where it can be limited. I’m not very bright about a lot of PHP details, but I think we’re mostly doing things in the usual way you’d do them with FPM (I hope).

I know this isn’t the solution you’re looking for but I got so frustrated once that I did it. I just used the file explorer in Virtualmin and did a search for php.ini and changed the limits on all of them. (I had 4 at the time I did it.)

I know that’s not how it’s supposed to work, but it’s a sure fire solution.

@Joe - I found this via Virtualmin → Services → PHP-FPM Configuration:

/etc/php/7.4/fpm/pool.d/{some_number}.conf

In this file was this:

; php_admin_value[memory_limit] = 512M

Apparently the colon is a comment so I removed it and that did the trick.

I wonder why this was there? Other config files do not have this.

Thank you both for your fast replies. Now I have one more Nextcloud warning about HSTS but I will start a another thread for that.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.