New in CWP Edge-LatestFree with every CWPpro licenceWebsites up to 300x faster

CWP now includes LSPHP, LSCache and CWP CageFS at no extra cost with all CWPpro licences. The LSCache plugin is integrated into our WordPress and other script installers, and CWP CageFS gives every user complete isolation. Available now in the CWP Edge-Latest version.

Get CWPpro ›

DKIM Module Out of Memory

Started by vk, April 05, 2020, 02:16:02 PM

Previous topic - Next topic

vk

Hi, I'm trying to update my DKIM signatures, but when I open the DKIM Manager Module it loads halfway through and throws me an allowed memory size error.

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 152768544 bytes) in /usr/local/cwpsrv/htdocs/resources/admin/modules/dkim.php on line 0

I updated /usr/local/cwp/php71/php.ini, restarted cwpsrv and cwp-phpfpm services but I still get the same error and the limits do not seem to have changed.

Any help would be great, thanks guys.

ejsolutions

#1
Try
/usr/local/php/php.ini
Remember to
systemctl restart cwpsrv

Admin, PHP Settings, PHP Info <-- check system version and (on mine) show configuration path.
I'm running PHP 7.3.16 - Loaded Configuration File => /usr/local/php/php.ini

vk

Quote from: ejsolutions on April 05, 2020, 02:29:13 PM
Try
/usr/local/php/php.ini
Remember to
systemctl restart cwpsrv

That was already set higher than the default. Thanks for the effort though.

ejsolutions

#3
See update, above.  :)

Also, in Admin: Simple PHP.ini editor

vk

Quote from: ejsolutions on April 05, 2020, 02:33:44 PM
See update, above.  :)

Also, in Admin: Simple PHP.ini editor

I'm using PHP-FPM so none of these are probably going to change anything. Changed them just in case, but no change in the error. I have already set my desired values on the active FPM versions for the clients, which is higher than the error suggests, so that shouldn't be the issue either. Also, if I'm not mistaken, doesn't cwpsrv use it's own PHP so it can be decoupled from the production webserver?

ejsolutions

Yes, CWP service PHP is independent of web servers, AFAIK.
Try
/usr/local/cwp/php71/etc/php-fpm.d/cwpsvc.conf

php_admin_value[memory_limit] = 256M

vk

That didn't do it either, I'm afraid.

I came up with a plan, I replaced dkim.php content with phpinfo() to find which configuration file is used. This one is the correct .ini file:

/usr/local/cwp/php71/php.ini

And I have already set it at 256M as I need it to be. So I assume, there is some service I missed and didn't restart. So far, I have restarted cwpsrv and cwp-phpfpm but to no avail.
Unfortunately, this being a production server with multiple clients on it, I cannot reboot the whole system and be done with it.

P.S.: Why such an old PHP version for CWP? Apparently it runs on 7.0.32

Edit: Also phpinfo report 128M as well, so it certainly hasn't updated the values.

vk

#7
Alright I fixed it! Apparently there is another service called cwpsrv-phpfpm but no one mentioned it anywhere. But when I double tabbed on "service cwp[tab][tab]" it popped up. DKIM module works just fine as well now.

Thanks a lot for you time, I appreciate it very much. 

Edit: I'm new here, what do I do with a solved topic? Lock it? Leave it as is?

vk

Yes, I expected the cwpsrv to do the thing when I saw it was a pool.

Thanks so much again, you really got the ball rolling, I would have never solved it without your input.

Send me a PM if there's anything I can do for you. Full stack developer and sys admin. I'm not great in either, but good enough for the girls I go out with.

ejsolutions

You're very welcome: sometimes it just takes bouncing ideas around.
Makes a change from 'cowboy' startups ;).