No image

Composer Memory Error

Should you get a composer memory error when using sudo composer upgrade on aMiSTACX, it is because of an incorrect setting w/ PHP 7.x. The memory value is set too low.

Although most of our stacks G5s ~ G3s have PHP preconfigured for the stack with multiple PHP versions, you may encounter a rare case where the PHP file for CLI is set for 512MB.

As a quick work-around, increase to 2G, reload PHP, and then contact support. We’ll provide the correct file, and review your settings.

A helpful command to determine what memory value PHP-CLI is set at, run the following:

sudo php -r "echo ini_get('memory_limit').PHP_EOL;"

To change the value edit the PHP CLI file:

sudo nano /etc/php/7.x/cli/php.ini

Where x = your current php version. # php -v

Ref: https://getcomposer.org/doc/articles/troubleshooting.md#memory-limit-errors

Lead~Robot

Comments are closed.