Update to 2.16 failed - out of memory exception

Your software
My Mautic version is:2.15.3
My PHP version is:7.2

Your problem
My problem is:
Upgrading to 2.16 via SSH (console mautic:upgrade:apply) and getting memory exception error.
PHP info shows memory_limit 8192M

These errors are showing in the log:

[Symfony\Component\Debug\Exception\OutOfMemoryException]
Error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 50261216 bytes)

any hints?

Hi there, welcome back to the forums!

Sorry to hear you’re encountering problems.

Please can you also check the memory limit for CLI?

Use php -i to find out which php.ini file it is loading on the CLI and set your memory_limit there. It is likely to be a different location to what is used for regular php, but depends on how your server is set up.

1 Like

Hi,

your post enlightened me - do not know why I have not checked that :slight_smile:
You were right - I was setting bigger PHP limit for apache but have not realised its still too low for PHP run from command line :slight_smile:

So all solved now!

Great thanks!

Best regards,

Michal

1 Like

Fantastic, glad to hear it! This caught me out so many times so I always look for that as soon as I’m hitting those errors at command line!